bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug #16068] negative integers in property lists (thus, user default


From: Wolfgang Sourdeau
Subject: Re: [bug #16068] negative integers in property lists (thus, user defaults) are set to 0
Date: Mon, 13 Mar 2006 00:16:34 -0500
User-agent: Mutt/1.3.28i

La plume légère, vers Sun, Mar 12, 2006 at 10:59:15AM +0000, heure 
d'inspiration,
Richard Frith-Macdonald écrivait en ces mots:
> 
> Follow-up Comment #1, bug #16068 (project gnustep):
> 
> Should be fixed in SVN.
> Thanksver much.


Hi Richard,


Looking at your patch, you are indeed taking quotes into account, but
not double-quotes, which is what I meant in my bug report...

So, what is now...

--- Source/NSPropertyList.m     (r.vision 22640)
+++ Source/NSPropertyList.m     (copie de travail)
@@ -711,6 +711,16 @@
                unsigned char   type = *ptr++;
 
                len--;
+               // Allow for quoted values.
+               if (ptr[0] == '\'' && len > 1)
+                 {
+                   len--;
+                   ptr++;
+                   if (ptr[len - 1] == '\'')
+                     {
+                       len--;
+                     }
+                 }
                if (type == 'I')
                  {
                    char        buf[len+1];


... really should be...

--- Source/NSPropertyList.m     (r.vision 22640)
+++ Source/NSPropertyList.m     (copie de travail)
@@ -711,6 +711,16 @@
                unsigned char   type = *ptr++;
 
                len--;
+               // Allow for quoted values.
+               if ((ptr[0] == '\'' || ptr[0] == '"') && len > 1)
+                 {
+                   len--;
+                   ptr++;
+                   if (ptr[len - 1] == '\'' || ptr[len - 1] == '"')
+                     {
+                       len--;
+                     }
+                 }
                if (type == 'I')
                  {
                    char        buf[len+1];




Wolfgang





reply via email to

[Prev in Thread] Current Thread [Next in Thread]