#include "libbb.h"
-void bb_perror_msg(const char *s, ...)
+void FAST_FUNC bb_perror_msg(const char *s, ...)
{
va_list p;
va_start(p, s);
/* Guard against "<error message>: Success" */
- if (!errno)
- bb_verror_msg(s, p, NULL);
- else
- bb_vperror_msg(s, p);
+ bb_verror_msg(s, p, errno ? strerror(errno) : NULL);
va_end(p);
}
+
+void FAST_FUNC bb_simple_perror_msg(const char *s)
+{
+ bb_perror_msg("%s", s);
+}