summaryrefslogtreecommitdiff
path: root/udev_utils.h
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@suse.de>2005-08-11 17:32:59 +0200
committerKay Sievers <kay.sievers@suse.de>2005-08-11 17:32:59 +0200
commit27f877e60f1c1793d6fafdd888e7e367c44b2eb9 (patch)
tree9c44dd776b7799bae3bfcf6ea445bb59c1a4605f /udev_utils.h
parent7fd0de4984deac2e51f9b85c156f200beadbc7ef (diff)
allow logging of all output from executed tools
If USE_DEBUG=true and udev_log="debug", all output of the forked programs to stdout and stderr is send to syslog. Signed-off-by: Kay Sievers <kay.sievers@suse.de>
Diffstat (limited to 'udev_utils.h')
-rw-r--r--udev_utils.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/udev_utils.h b/udev_utils.h
index 5b223855b6..a3fc283203 100644
--- a/udev_utils.h
+++ b/udev_utils.h
@@ -24,6 +24,8 @@
#include "udev.h"
#include "list.h"
+#define UDEV_MAX(a,b) ((a) > (b) ? (a) : (b))
+
struct name_entry {
struct list_head node;
char name[PATH_SIZE];
@@ -45,7 +47,7 @@ extern int name_list_add(struct list_head *name_list, const char *name, int sort
extern int name_list_key_add(struct list_head *name_list, const char *key, const char *value);
extern int add_matching_files(struct list_head *name_list, const char *dirname, const char *suffix);
extern int pass_env_to_socket(const char *name, const char *devpath, const char *action);
-extern int execute_program(const char *command, const char *subsystem,
- char *result, size_t ressize, size_t *reslen);
+extern int run_program(const char *command, const char *subsystem,
+ char *result, size_t ressize, size_t *reslen, int log);
#endif