URL:
  <http://savannah.gnu.org/bugs/?24683>

                 Summary: -[NSString intValue] fails if string contains >31
leading whitespace characters
                 Project: GNUstep
            Submitted by: lcampbel
            Submitted on: Tue 28 Oct 2008 06:07:36 PM GMT
                Category: Base/Foundation
                Severity: 3 - Normal
              Item Group: Bug
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any

    _______________________________________________________

Details:

Due to this lossage in GSString.m (intValue_c, and similarly for
intValue_u):

      unsigned  len = self->_count < 32 ? self->_count : 31;
      char      buf[len+1];

      memcpy(buf, self->_contents.c, len);
      buf[len] = '\0';
      return atol((const char*)buf);

If the string contains more than 31 leading whitespace characters, zero is
returned instead of the correct value.






    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?24683>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/



_______________________________________________
Bug-gnustep mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-gnustep

Reply via email to