HCoop
/
clinton
/
Smoothieware.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2de291e
)
free up old config value when a duplicate is found.
author
Jim Morris
<morris@wolfman.com>
Wed, 1 Mar 2017 05:49:01 +0000
(21:49 -0800)
committer
Jim Morris
<morris@wolfman.com>
Wed, 1 Mar 2017 05:49:01 +0000
(21:49 -0800)
src/libs/ConfigCache.cpp
patch
|
blob
|
blame
|
history
diff --git
a/src/libs/ConfigCache.cpp
b/src/libs/ConfigCache.cpp
index
760c8cd
..
20f6b47
100644
(file)
--- a/
src/libs/ConfigCache.cpp
+++ b/
src/libs/ConfigCache.cpp
@@
-34,6
+34,7
@@
void ConfigCache::replace_or_push_back(ConfigValue *new_value)
// If this configvalue matches the checksum
if(memcmp(new_value->check_sums, cv->check_sums, sizeof(cv->check_sums)) == 0) {
// Replace with the provided value
+ delete cv; // free up old one
cv = new_value;
printf("WARNING: duplicate config line replaced\n");
return;