git.samba.org
/
metze
/
samba
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f11c588
)
dbwrap: Use sizeof, not an integer constant
author
Volker Lendecke
<vl@samba.org>
Fri, 24 May 2019 12:37:20 +0000
(14:37 +0200)
committer
Jeremy Allison
<jra@samba.org>
Tue, 28 May 2019 20:27:15 +0000
(20:27 +0000)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/lib/dbwrap/dbwrap_watch.c
patch
|
blob
|
history
diff --git
a/source3/lib/dbwrap/dbwrap_watch.c
b/source3/lib/dbwrap/dbwrap_watch.c
index 45e17958b9263325a745fce56e6014dcf073b45b..c367efdd130a67e1721dd131c976835ca4c39a14 100644
(file)
--- a/
source3/lib/dbwrap/dbwrap_watch.c
+++ b/
source3/lib/dbwrap/dbwrap_watch.c
@@
-361,7
+361,8
@@
static void dbwrap_watched_wakeup(struct db_record *rec,
SIVAL(len_buf, 0, db_id_len);
- iov[0] = (struct iovec) { .iov_base = len_buf, .iov_len = 4 };
+ iov[0] = (struct iovec) { .iov_base = len_buf,
+ .iov_len = sizeof(len_buf) };
iov[1] = (struct iovec) { .iov_base = db_id, .iov_len = db_id_len };
iov[2] = (struct iovec) { .iov_base = rec->key.dptr,
.iov_len = rec->key.dsize };