diff options
author | 2019-05-22 21:41:19 +0300 | |
---|---|---|
committer | 2019-05-22 21:41:19 +0300 | |
commit | 5e22764d79e42345d512216f07880fdd8db2edf2 (patch) | |
tree | b02d82781e398bf36ba4b3dca78cd2fbf0135bca | |
parent | 446157d793c30386f994743f5a8e6ab64e66507f (diff) | |
download | usurpation-5e22764d79e42345d512216f07880fdd8db2edf2.tar.gz usurpation-5e22764d79e42345d512216f07880fdd8db2edf2.tar.bz2 usurpation-5e22764d79e42345d512216f07880fdd8db2edf2.zip |
Protocol: fixed a off-by-one error when copying a string.
Signed-off-by: Ramūnas Mažeikis <ramunasnezinomas@gmail.com>
-rw-r--r-- | src/common/protocol.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/protocol.c b/src/common/protocol.c index d3317e3..8680be7 100644 --- a/src/common/protocol.c +++ b/src/common/protocol.c @@ -41,7 +41,7 @@ int push_tlv(struct tlv_packet *packet, enum tlv_type type, char *data) switch (type) { case TEXT: - size = strlen(data); + size = strlen(data) + 1; break; case FPI1: size = sizeof(fpi1_t); |