mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-22 22:03:43 +03:00
Merge pull request #13761 from dtardon/program-name
udev: do not hardcode program name
This commit is contained in:
commit
c94f7809e3
@ -425,9 +425,10 @@ int main(int argc, char *argv[]) {
|
||||
export = 1;
|
||||
break;
|
||||
case 'h':
|
||||
printf("Usage: ata_id [--export] [--help] <device>\n"
|
||||
printf("Usage: %s [--export] [--help] <device>\n"
|
||||
" -x,--export print values as environment keys\n"
|
||||
" -h,--help print this help text\n\n");
|
||||
" -h,--help print this help text\n\n",
|
||||
program_invocation_short_name);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
@ -849,12 +849,13 @@ int main(int argc, char *argv[]) {
|
||||
log_open();
|
||||
break;
|
||||
case 'h':
|
||||
printf("Usage: cdrom_id [options] <device>\n"
|
||||
printf("Usage: %s [options] <device>\n"
|
||||
" -l,--lock-media lock the media (to enable eject request events)\n"
|
||||
" -u,--unlock-media unlock the media\n"
|
||||
" -e,--eject-media eject the media\n"
|
||||
" -d,--debug debug to stderr\n"
|
||||
" -h,--help print this help text\n\n");
|
||||
" -h,--help print this help text\n\n",
|
||||
program_invocation_short_name);
|
||||
goto exit;
|
||||
default:
|
||||
rc = 1;
|
||||
|
@ -44,7 +44,7 @@ static int run(int argc, char **argv) {
|
||||
log_open();
|
||||
|
||||
if (argc > 2)
|
||||
return log_error_errno(SYNTHETIC_ERRNO(EINVAL), "Usage: hidraw_id [SYSFS_PATH]");
|
||||
return log_error_errno(SYNTHETIC_ERRNO(EINVAL), "Usage: %s [SYSFS_PATH]", program_invocation_short_name);
|
||||
|
||||
if (argc == 1) {
|
||||
r = device_new_from_strv(&device, environ);
|
||||
|
Loading…
x
Reference in New Issue
Block a user