projects
/
rrdtool.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Avoid unnecessary string handling for UPDATE commands in rrd_deaemon for 20x
[rrdtool.git]
/
src
/
rrd_daemon.c
diff --git
a/src/rrd_daemon.c
b/src/rrd_daemon.c
index
0ca1818
..
1946003
100644
(file)
--- a/
src/rrd_daemon.c
+++ b/
src/rrd_daemon.c
@@
-1312,7
+1312,8
@@
static int handle_request_update (HANDLER_PROTO) /* {{{ */
cache_item_t *ci;
/* save it for the journal later */
- strncpy(orig_buf, buffer, sizeof(orig_buf)-1);
+ if (sock != NULL)
+ strncpy(orig_buf, buffer, buffer_size);
status = buffer_get_field (&buffer, &buffer_size, &file);
if (status != 0)