env-util: remove unneeded DISABLE_WARNING_FORMAT_NONLITERAL

_printf_ is used, so this shouldn't emit a warning
in the first place.
This commit is contained in:
Mike Yuan
2024-03-12 15:41:51 +08:00
parent 5d789ba5a6
commit 8b8edb512a
-2
View File
@@ -1140,9 +1140,7 @@ int setenvf(const char *name, bool overwrite, const char *valuef, ...) {
return RET_NERRNO(unsetenv(name));
va_start(ap, valuef);
DISABLE_WARNING_FORMAT_NONLITERAL;
r = vasprintf(&value, valuef, ap);
REENABLE_WARNING;
va_end(ap);
if (r < 0)