diff options
| author | Reiner Herrmann <reiner@reiner-h.de> | 2011-01-16 02:46:02 +0100 |
|---|---|---|
| committer | Reiner Herrmann <reiner@reiner-h.de> | 2011-01-16 02:46:02 +0100 |
| commit | 459a1f83b51a506f538bf495f9a85cf399070a85 (patch) | |
| tree | db83a3db0e32bbc2667a02bca99f639e862631bf /src | |
| parent | e291d69fa4d865da8c1d6ece46cb149d1cddb9d8 (diff) | |
need space for nullbyte
Diffstat (limited to 'src')
| -rw-r--r-- | src/main.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -35,7 +35,7 @@ int main(int argc, char **argv) csocks = server_get_players(ssock, opponents); players.count = opponents + 1; - players.names[0] = malloc(strlen(nickname)); + players.names[0] = malloc(strlen(nickname)+1); strcpy(players.names[0], nickname); for(int i=0; i<opponents; i++) |
