projects
/
oweals
/
odhcp6c.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c52296c
)
softwires: avoid unnecessary allocations
author
Steven Barth
<steven@midlink.org>
Sat, 25 Oct 2014 10:37:01 +0000
(12:37 +0200)
committer
Steven Barth
<steven@midlink.org>
Sat, 25 Oct 2014 10:37:01 +0000
(12:37 +0200)
src/script.c
patch
|
blob
|
history
diff --git
a/src/script.c
b/src/script.c
index 98fc6e9989bcf3fa3a206cffc998c0ec4d486c46..f350ea79e2850d50d51e25e261ca7a5f2b78459e 100644
(file)
--- a/
src/script.c
+++ b/
src/script.c
@@
-228,6
+228,9
@@
static void s46_to_env(enum odhcp6c_state state, const uint8_t *data, size_t len
const char *name = (state == STATE_S46_MAPE) ? "MAPE" :
(state == STATE_S46_MAPT) ? "MAPT" : "LW4O6";
+ if (len == 0)
+ return;
+
char *str;
size_t strsize;