Skip to content
Snippets Groups Projects
Commit 049c5ef9 authored by burneykb's avatar burneykb
Browse files

solved names with spaces in them

parent c4717f11
No related branches found
No related tags found
No related merge requests found
......@@ -51,7 +51,11 @@ ssize_t EncodeAddNode(
int16_t type;
char name[512];
sscanf(msg, "addnode %" SCNd16 "%s\n", &type, name);
memset(name, 0, 512);
sscanf(msg, "addnode %" SCNd16 " %512c", &type, name);
printf("found name '%s'\n", name);
data[AN_TYPE_ID_L] = LSByte16(type);
data[AN_TYPE_ID_H] = MSByte16(type);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment