Fix:Core:Better decoding of flags
authormartin-s <martin-s@ffa7fe5e-494d-0410-b361-a75ebd5db220>
Wed, 26 Jan 2011 14:50:58 +0000 (14:50 +0000)
committermartin-s <martin-s@ffa7fe5e-494d-0410-b361-a75ebd5db220>
Wed, 26 Jan 2011 14:50:58 +0000 (14:50 +0000)
git-svn-id: https://navit.svn.sourceforge.net/svnroot/navit/trunk@4042 ffa7fe5e-494d-0410-b361-a75ebd5db220

navit/navit/attr.c

index 21c8766..37de183 100644 (file)
@@ -218,7 +218,7 @@ attr_new_from_text(const char *name, const char *value)
 static char *
 flags_to_text(int flags)
 {
-       char *ret=NULL;
+       char *ret=g_strdup_printf("0x%x:",flags);
        if (flags & AF_ONEWAY) ret=g_strconcat_printf(ret,"%sAF_ONEWAY",ret?"|":"");
        if (flags & AF_ONEWAYREV) ret=g_strconcat_printf(ret,"%sAF_ONEWAYREV",ret?"|":"");
        if (flags & AF_SEGMENTED) ret=g_strconcat_printf(ret,"%sAF_SEGMENTED",ret?"|":"");