X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=udevinfo.c;h=44eb1427092abfda36f78407ffe84aa410609308;hb=bb7386472466e55f75df024d18e8da37a222bb41;hp=aa9d20a7736a7cb19b67133a551658a204bbe236;hpb=ac4dc8746501ae3b9c859e5714f508d90cbe41a7;p=elogind.git diff --git a/udevinfo.c b/udevinfo.c index aa9d20a77..44eb14270 100644 --- a/udevinfo.c +++ b/udevinfo.c @@ -39,6 +39,18 @@ char **main_argv; int main_argc; +#ifdef LOG +unsigned char logname[42]; +void log_message (int level, const char *format, ...) +{ + va_list args; + + va_start(args, format); + vsyslog(level, format, args); + va_end(args); +} +#endif + static int print_all_attributes(const char *path) { struct dlist *attributes; @@ -397,7 +409,7 @@ help: " -n NAME node name used for query\n" "\n" " -r print udev root\n" - " -a print all attributes along the chain of the device\n" + " -a print all SYSFS_attributes along the device chain\n" " -d dump whole database\n" " -V print udev version\n" " -h print this help text\n" @@ -412,6 +424,8 @@ int main(int argc, char *argv[], char *envp[]) main_argv = argv; main_argc = argc; + init_logging("udevinfo"); + /* initialize our configuration */ udev_init_config();