diff options
author | Sander Vrijders <sander.vrijders@intec.ugent.be> | 2016-10-15 13:18:43 +0000 |
---|---|---|
committer | Sander Vrijders <sander.vrijders@intec.ugent.be> | 2016-10-15 13:18:43 +0000 |
commit | 059dc0f942330b1e8a989f37a7caf3766f8e6c50 (patch) | |
tree | 4f8fff344e512a89d36c876249c8d19b62fc8d34 /src/lib | |
parent | 34f61c73f290b9f375bebb14bc48a4b15dfcc4cc (diff) | |
parent | b936e8c62a25c8fae62244ce29d6403ee4aac6ab (diff) | |
download | ouroboros-059dc0f942330b1e8a989f37a7caf3766f8e6c50.tar.gz ouroboros-059dc0f942330b1e8a989f37a7caf3766f8e6c50.zip |
Merged in dstaesse/ouroboros/be-fix-select (pull request #264)
lib: Fix initialisation of flow_set
Diffstat (limited to 'src/lib')
-rw-r--r-- | src/lib/dev.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/dev.c b/src/lib/dev.c index 348b864c..577fa7a7 100644 --- a/src/lib/dev.c +++ b/src/lib/dev.c @@ -747,7 +747,8 @@ struct flow_set * flow_set_create() return NULL; } - memset(&set->b, 0, sizeof(set->b)); + memset(set->b, 0, IRMD_MAX_FLOWS); + memset(set->s, 0, IRMD_MAX_FLOWS); set->dirty = true; @@ -757,7 +758,7 @@ struct flow_set * flow_set_create() void flow_set_zero(struct flow_set * set) { pthread_rwlock_wrlock(&set->lock); - memset(&set->b, 0, sizeof(set->b)); + memset(set->b, 0, IRMD_MAX_FLOWS); set->dirty = true; pthread_rwlock_unlock(&set->lock); } |