ovs.daemon: Fix semantics of --pidfile option.
[openvswitch] / python / ovs / daemon.py
index 85db050ca3849dbf3db4e20a4d43740ef7c960cd..a919c53ecb4ab178f60e259086c827aa4b1af40b 100644 (file)
@@ -503,7 +503,7 @@ def add_args(parser):
             help="Do not chdir to '/'.")
     group.add_argument("--monitor", action="store_true",
             help="Monitor %s process." % ovs.util.PROGRAM_NAME)
-    group.add_argument("--pidfile", nargs="?", default=pidfile,
+    group.add_argument("--pidfile", nargs="?", const=pidfile,
             help="Create pidfile (default %s)." % pidfile)
     group.add_argument("--overwrite-pidfile", action="store_true",
             help="With --pidfile, start even if already running.")