Skip to content

Commit fe2cd01

Browse files
Matthias Loycdunn2001
authored andcommitted
free does nothing if parameter equals NULL
1 parent b02ff20 commit fe2cd01

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/lib_json/json_value.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,7 @@ static inline char *duplicateStringValue(const char *value,
105105
/** Free the string duplicated by duplicateStringValue().
106106
*/
107107
static inline void releaseStringValue(char *value) {
108-
if (value)
109-
free(value);
108+
free(value);
110109
}
111110

112111
} // namespace Json

0 commit comments

Comments
 (0)