add scary warnings
This commit is contained in:
parent
a4ea977c68
commit
f44a1c3ffe
2
bspc.c
2
bspc.c
|
@ -307,10 +307,12 @@ int main(void) {
|
|||
|
||||
for(int i = 0; i < 64; i++) {
|
||||
if(final[i] == '\0') {
|
||||
/* XXX: susceptible to buffer underflow */
|
||||
if (i) final[i - 1] = '\0';
|
||||
break;
|
||||
}
|
||||
if(isdigit(final[i]) && *current == final[i])
|
||||
/* XXX: susceptible to buffer overflow */
|
||||
final[i + 1] = '<';
|
||||
if(final[i] == '\n')
|
||||
final[i] = ' ';
|
||||
|
|
Loading…
Reference in New Issue