Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 259972
b: refs/heads/master
c: c93be5b
h: refs/heads/master
v: v3
  • Loading branch information
matt mooney authored and Greg Kroah-Hartman committed Jul 6, 2011
1 parent 5b4656e commit 542921b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f2fb62b371703e70593780ad40333c2e21030df8
refs/heads/master: c93be5b178ca7f3f4599da7a26a5828ab36aafb4
13 changes: 10 additions & 3 deletions trunk/drivers/staging/usbip/userspace/src/usbip.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
#include <stdlib.h>

#include <getopt.h>
#include <syslog.h>

#include "usbip_common.h"
#include "usbip.h"
Expand All @@ -33,7 +34,7 @@ static int usbip_version(int argc, char *argv[]);
static const char usbip_version_string[] = PACKAGE_STRING;

static const char usbip_usage_string[] =
"usbip [--debug] [version]\n"
"usbip [--debug] [--log] [version]\n"
" [help] <command> <args>\n";

static void usbip_usage(void)
Expand Down Expand Up @@ -138,12 +139,15 @@ int main(int argc, char *argv[])
{
static const struct option opts[] = {
{ "debug", no_argument, NULL, 'd' },
{ NULL, 0, NULL, 0 }
{ "log", no_argument, NULL, 'l' },
{ NULL, 0, NULL, 0 }
};

char *cmd;
int opt;
int i, rc = -1;

usbip_use_stderr = 1;
opterr = 0;
for (;;) {
opt = getopt_long(argc, argv, "+d", opts, NULL);
Expand All @@ -154,7 +158,10 @@ int main(int argc, char *argv[])
switch (opt) {
case 'd':
usbip_use_debug = 1;
usbip_use_stderr = 1;
break;
case 'l':
usbip_use_syslog = 1;
openlog("", LOG_PID, LOG_USER);
break;
default:
goto err_out;
Expand Down

0 comments on commit 542921b

Please sign in to comment.