summaryrefslogtreecommitdiff
path: root/legacy/eet/src
diff options
context:
space:
mode:
authorVincent Torri <vincent.torri@gmail.com>2012-02-17 21:08:15 +0000
committerVincent Torri <vincent.torri@gmail.com>2012-02-17 21:08:15 +0000
commit026f3439ed9dcaa6993985b3e9d9425ccd6c3fbf (patch)
tree67ee5c9bc6f05a68ea398ea581565c590b458e48 /legacy/eet/src
parent2e088e3f1dd1f871f40a4459d732ee2f34e8e3f8 (diff)
Eet: remove ugly FMT_* compatibility strings as Evil has now POSIX printf family functions
SVN revision: 68091
Diffstat (limited to 'legacy/eet/src')
-rw-r--r--legacy/eet/src/lib/eet_data.c21
1 files changed, 4 insertions, 17 deletions
diff --git a/legacy/eet/src/lib/eet_data.c b/legacy/eet/src/lib/eet_data.c
index 56b9ee0885..d502f44311 100644
--- a/legacy/eet/src/lib/eet_data.c
+++ b/legacy/eet/src/lib/eet_data.c
@@ -21,18 +21,6 @@
21#include "Eet.h" 21#include "Eet.h"
22#include "Eet_private.h" 22#include "Eet_private.h"
23 23
24#ifdef _WIN32
25# define FMT_CHAR "%c"
26# define FMT_UCHAR "%c"
27# define FMT_LONG_LONG "%I64i"
28# define FMT_ULONG_LONG "%I64u"
29#else
30# define FMT_CHAR "%hhi"
31# define FMT_UCHAR "%hhu"
32# define FMT_LONG_LONG "%lli"
33# define FMT_ULONG_LONG "%llu"
34#endif
35
36/* 24/*
37 * routines for doing data -> struct and struct -> data conversion 25 * routines for doing data -> struct and struct -> data conversion
38 * 26 *
@@ -3108,7 +3096,7 @@ _eet_data_dump_parse(Eet_Dictionary *ed,
3108 if (!strcmp(tok3, "char:")) 3096 if (!strcmp(tok3, "char:"))
3109 { 3097 {
3110 n->type = EET_T_CHAR; 3098 n->type = EET_T_CHAR;
3111 sscanf(tok4, FMT_CHAR, 3099 sscanf(tok4, "%hhi",
3112 &(n->data.value.c)); 3100 &(n->data.value.c));
3113 } 3101 }
3114 else if (!strcmp(tok3, "short:")) 3102 else if (!strcmp(tok3, "short:"))
@@ -3126,7 +3114,7 @@ _eet_data_dump_parse(Eet_Dictionary *ed,
3126 else if (!strcmp(tok3, "long_long:")) 3114 else if (!strcmp(tok3, "long_long:"))
3127 { 3115 {
3128 n->type = EET_T_LONG_LONG; 3116 n->type = EET_T_LONG_LONG;
3129 sscanf(tok4, FMT_LONG_LONG, 3117 sscanf(tok4, "%lli",
3130 &(n->data.value.l)); 3118 &(n->data.value.l));
3131 } 3119 }
3132 else if (!strcmp(tok3, "float:")) 3120 else if (!strcmp(tok3, "float:"))
@@ -3144,7 +3132,7 @@ _eet_data_dump_parse(Eet_Dictionary *ed,
3144 else if (!strcmp(tok3, "uchar:")) 3132 else if (!strcmp(tok3, "uchar:"))
3145 { 3133 {
3146 n->type = EET_T_UCHAR; 3134 n->type = EET_T_UCHAR;
3147 sscanf(tok4, FMT_UCHAR, 3135 sscanf(tok4, "%hhu",
3148 &(n->data.value.uc)); 3136 &(n->data.value.uc));
3149 } 3137 }
3150 else if (!strcmp(tok3, "ushort:")) 3138 else if (!strcmp(tok3, "ushort:"))
@@ -3162,7 +3150,7 @@ _eet_data_dump_parse(Eet_Dictionary *ed,
3162 else if (!strcmp(tok3, "ulong_long:")) 3150 else if (!strcmp(tok3, "ulong_long:"))
3163 { 3151 {
3164 n->type = EET_T_ULONG_LONG; 3152 n->type = EET_T_ULONG_LONG;
3165 sscanf(tok4, FMT_ULONG_LONG, 3153 sscanf(tok4, "%llu",
3166 &(n->data.value.ul)); 3154 &(n->data.value.ul));
3167 } 3155 }
3168 else if (!strcmp(tok3, "string:")) 3156 else if (!strcmp(tok3, "string:"))
@@ -4996,4 +4984,3 @@ eet_data_xattr_cipher_set(const char *filename,
4996 4984
4997 return ret; 4985 return ret;
4998} 4986}
4999