Chameleon

Chameleon Commit Details

Date:2010-10-19 07:32:54 (10 years 1 month ago)
Author:Evan Lojewski
Commit:599
Parents: 598
Message:xml bugfixes + hacks
Changes:
M/branches/meklort/i386/libsaio/xml.c

File differences

branches/meklort/i386/libsaio/xml.c
717717
718718
719719
720
721
722
723
724720
725721
726722
......
733729
734730
735731
736
732
737733
738
739
740
734
735
736
737
738
739
740
741
741742
742
743
744743
745744
746745
747746
748
749747
750748
751749
......
754752
755753
756754
757
755
758756
759757
760758
......
11091107
11101108
11111109
1112
1113
1110
1111
1112
1113
1114
1115
11141116
11151117
}
}
if (negative)
integer = -integer;
}
else if ( size )// Decimal value
{
for (integer = 0; size > 0; size--)
{
if (*val < '0' || *val > '9')
if(*val) // UGLY HACK, fix me.
{
printf("ParseTagInteger decimal error (0x%x) in buffer %s\n", *val, buffer);
getc();
return -1;
if (*val < '0' || *val > '9')
{
printf("ParseTagInteger decimal error (0x%x) in buffer %s\n", *val, buffer);
getc();
return -1;
}
integer = (integer * 10) + (*val++ - '0');
}
integer = (integer * 10) + (*val++ - '0');
}
if (negative)
integer = -integer;
}
tmpTag->type = kTagTypeInteger;
tmpTag->tagNext = 0;
*tag = tmpTag;
return length;
}
int XMLCastInteger(TagPtr dict)
{
if(!dict) return 0;
if(dict->type == kTagTypeInteger) return (int)dict->string;
if(!dict)
{
printf("XMLCastInteger: null dict\n");
return 0;
}
if(dict->type == kTagTypeInteger) return (int)(dict->string);
return 0;
}

Archive Download the corresponding diff file

Revision: 599