diff --git a/plugins/popen.c b/plugins/popen.c
index d527c222906d63c23a912c9fee34b14d17b2e37d..04eb3881b328fa0e0938a5b93295f661231119db 100644 (file)
--- a/plugins/popen.c
+++ b/plugins/popen.c
/* there cannot be more args than characters */
argc = strlen (cmdstring) + 1; /* add 1 for NULL termination */
argv = malloc (sizeof(char*)*argc);
/* there cannot be more args than characters */
argc = strlen (cmdstring) + 1; /* add 1 for NULL termination */
argv = malloc (sizeof(char*)*argc);
+
if (argv == NULL) {
if (argv == NULL) {
- printf ("Could not malloc argv array in popen()\n");
+ printf (_("Could not malloc argv array in popen()\n"));
return NULL;
}
return NULL;
}
str += strspn (str, " \t\r\n"); /* trim any leading whitespace */
if (i >= argc - 2) {
str += strspn (str, " \t\r\n"); /* trim any leading whitespace */
if (i >= argc - 2) {
- printf ("You've got a big problem buddy! You need more args!!!\n");
+ printf (_("CRITICAL - You need more args!!!\n"));
return (NULL);
}
return (NULL);
}
#define OPEN_MAX_GUESS 256 /* if OPEN_MAX is indeterminate */
/* no guarantee this is adequate */
#define OPEN_MAX_GUESS 256 /* if OPEN_MAX is indeterminate */
/* no guarantee this is adequate */
+
void
popen_timeout_alarm_handler (int signo)
{
if (signo == SIGALRM) {
kill (childpid[fileno (child_process)], SIGKILL);
void
popen_timeout_alarm_handler (int signo)
{
if (signo == SIGALRM) {
kill (childpid[fileno (child_process)], SIGKILL);
- printf ("CRITICAL - Plugin timed out after %d seconds\n",
+ printf (_("CRITICAL - Plugin timed out after %d seconds\n"),
timeout_interval);
exit (STATE_CRITICAL);
}
}
timeout_interval);
exit (STATE_CRITICAL);
}
}
+
int
open_max (void)
{
int
open_max (void)
{
if (errno == 0)
openmax = OPEN_MAX_GUESS; /* it's indeterminate */
else
if (errno == 0)
openmax = OPEN_MAX_GUESS; /* it's indeterminate */
else
- err_sys ("sysconf error for _SC_OPEN_MAX");
+ err_sys (_("sysconf error for _SC_OPEN_MAX"));
}
}
return (openmax);
}
}
}
return (openmax);
}
-
/* Fatal error related to a system call.
* Print a message and die. */
/* Fatal error related to a system call.
* Print a message and die. */
}
return str;
}
}
return str;
}
-