fix custom file info to be less delicate - not perfectly correct but it wont

lose all your data if e segv's or is kill -9'd anymore. eet handles multiple
writes to the same key now by overwriting the previous data


SVN revision: 30057
This commit is contained in:
Carsten Haitzler 2007-05-23 12:07:14 +00:00
parent 5db0ab1039
commit 2818ca982a
2 changed files with 13 additions and 13 deletions

View File

@ -1101,8 +1101,6 @@ eet_write(Eet_File *ef, const char *name, const void *data, int size, int compre
memcpy(data2, data, size);
/* Does this node already exist? */
if (ef->mode == EET_FILE_MODE_READ_WRITE)
{
for (efn = ef->header->directory->nodes[hash]; efn; efn = efn->next)
{
/* if it matches */
@ -1117,7 +1115,6 @@ eet_write(Eet_File *ef, const char *name, const void *data, int size, int compre
break;
}
}
}
if (!exists_already)
{
efn = malloc(sizeof(Eet_File_Node));

View File

@ -582,6 +582,7 @@ typedef union {
#define CPUID_SSE (1 << 25) /* flags: xmm */
#define CPUID_SSE2 (1 << 26) /* flags: ? */
/*
#ifdef __amd64
#define have_cpuid(cpuid_ret) \
__asm__ __volatile__ ( \
@ -661,6 +662,8 @@ typedef union {
: "=m" (cpuid_ret) \
);
#endif
*/
#define prefetch(var) \
__asm__ __volatile__ ( \
"prefetchnta (%0) \n" \