Bug #683 » 0001-Fix-stringop-truncation-error-thanks-DJ-Delorie.patch
src/irc.c | ||
---|---|---|
if (c - cur < 1)
|
||
return NULL;
|
||
ret = bip_malloc(c - cur + 1);
|
||
strncpy(ret, cur, c - cur);
|
||
memcpy(ret, cur, c - cur);
|
||
ret[c - cur] = 0;
|
||
return ret;
|
||
}
|
||
if (index == num) {
|
||
... | ... | |
if (c - cur < 1)
|
||
return NULL;
|
||
ret = bip_malloc(c - cur + 1);
|
||
strncpy(ret, cur, c - cur);
|
||
memcpy(ret, cur, c - cur);
|
||
ret[c - cur] = 0;
|
||
return ret;
|
||
}
|
||
return NULL;
|
- « Previous
- 1
- 2
- Next »