attempted fix for bug #31266

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@31505 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 2010-10-12 19:19:02 +00:00
parent 9c8d4406d5
commit 51287760d4
2 changed files with 19 additions and 2 deletions

View file

@ -1,3 +1,9 @@
2010-10-12 Richard Frith-Macdonald <rfm@gnu.org>
* Source/Additions/GSXML.m: If we receive an attribute name with no
corresponding value, assume it's a minimised attribute in html ...
and we should set the value to be the same as the name.
2010-10-12 Richard Frith-Macdonald <rfm@gnu.org>
* Source/Additions/GSObjCRuntime.m: Add support for arbitrary struct

View file

@ -2809,9 +2809,20 @@ startElementFunction(void *ctx, const unsigned char *name,
while (atts[i] != NULL)
{
NSString *key = UTF8Str(atts[i++]);
NSString *obj = UTF8Str(atts[i++]);
NSString *key = UTF8Str(atts[i++]);
NSString *obj;
const unsigned char *val = atts[i++];
if (0 == val)
{
/* No value ... assume tis is a minimised attribute in html.
*/
obj = key;
}
else
{
obj = UTF8Str(val);
}
[dict setObject: obj forKey: key];
}
}