Fix typo that caused a too small buffer to be allocated for device names.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25465 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz
2008-05-12 11:22:53 +00:00
parent f97c4f2fdc
commit e5812e917b
@@ -329,7 +329,7 @@ publish_devices()
acquire_sem(gDriverLock);
for(int32 i = 0; i < DEVICES_COUNT; i++) {
if (gSerialDevices[i]) {
gDeviceNames[j] = (char *)malloc(strlen(sDeviceBaseName + 4));
gDeviceNames[j] = (char *)malloc(strlen(sDeviceBaseName) + 4);
if (gDeviceNames[j]) {
sprintf(gDeviceNames[j], "%s%ld", sDeviceBaseName, i);
j++;