summaryrefslogtreecommitdiffstats
path: root/extensions/libip6t_owner.c
diff options
context:
space:
mode:
authorgandalf <gandalf>2004-01-31 15:33:55 +0000
committergandalf <gandalf>2004-01-31 15:33:55 +0000
commitb452a970ea8771586a95f6a8253536e48a73d3bc (patch)
treeb29bb39cfef731e863db577f1ff161e4bf5d3f5f /extensions/libip6t_owner.c
parent32be9ea0651809e288d7f44550b2eed7ba582575 (diff)
Fix even more possibly not zero-terminated strings after copy (Karsten Desler)
Diffstat (limited to 'extensions/libip6t_owner.c')
-rw-r--r--extensions/libip6t_owner.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/extensions/libip6t_owner.c b/extensions/libip6t_owner.c
index ed78530..6d7258d 100644
--- a/extensions/libip6t_owner.c
+++ b/extensions/libip6t_owner.c
@@ -129,6 +129,7 @@ parse(int c, char **argv, int invert, unsigned int *flags,
exit_error(PARAMETER_PROBLEM, "OWNER CMD `%s' too long, max %d characters", optarg, sizeof(ownerinfo->comm));
strncpy(ownerinfo->comm, optarg, sizeof(ownerinfo->comm));
+ ownerinfo->comm[sizeof(ownerinfo->comm)-1] = '\0';
if (invert)
ownerinfo->invert |= IP6T_OWNER_COMM;