Mailinglist Archive: opensuse-bugs (4724 mails)

< Previous Next >
[Bug 586112] Sax2 fails with buffer overflow message / Build fails with undefined symbol: xf86CheckBoolOption
  • From: bugzilla_noreply@xxxxxxxxxx
  • Date: Tue, 6 Apr 2010 10:50:06 +0000
  • Message-id: <20100406105006.DF1EF245520@xxxxxxxxxxxxxxxxxxxxxx>
http://bugzilla.novell.com/show_bug.cgi?id=586112

http://bugzilla.novell.com/show_bug.cgi?id=586112#c11


--- Comment #11 from Stefan Dirsch <sndirsch@xxxxxxxxxx> 2010-04-06 10:50:05
UTC ---
Rudi, snprintf writes the string *including* the trailing trailing null byte
('\0'). What about ?

- sprintf(display->ddc,"%c",'\0');
- snprintf(display->ddc, strlen(display->ddc) - 1, "%s%04x",
- vend_id2str(hd->vendor.id),ID_VALUE(hd->device.id)
- );
+ snprintf(display->ddc, sizeof(display->ddc), "%s%04x",
+ vend_id2str(hd->vendor.id),ID_VALUE(hd->device.id)
+ );

--
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

< Previous Next >