Skip to content

Commit 719d5e6

Browse files
committed
bugfix: DEBUG_CMP: fixed warning: format string is not a string literal (potentially insecure)
1 parent 74e07f8 commit 719d5e6

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/inet/common/DebugDefs.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ static inline bool _dbg_function_enabled(const char *function)
155155
_dbg_global_enabled = true; _o1 = (o1); _o2 = (o2); \
156156
std::ostringstream oss; oss << "ASSERT: Condition '" << #o1 << " " << #cmp << " " << #o2 << "' as '" << _o1 << " " << #cmp << " " << _o2 << "' does not hold"; \
157157
omnetpp::cRuntimeError error("in function '%s()' at %s:%d", __FUNCTION__, __FILE__, __LINE__); \
158-
error.prependMessage(oss.str().c_str()); \
158+
error.prependMessage("%s", oss.str().c_str()); \
159159
throw error; \
160160
} \
161161
}

0 commit comments

Comments
 (0)