udisksctl: Don't ask for passphrase when locking
authorDavid Zeuthen <davidz@redhat.com>
Wed, 20 Jul 2011 14:16:17 +0000 (10:16 -0400)
committerDavid Zeuthen <davidz@redhat.com>
Wed, 20 Jul 2011 14:16:17 +0000 (10:16 -0400)
Signed-off-by: David Zeuthen <davidz@redhat.com>
tools/udisksctl.c

index ffc916a..be5885d 100644 (file)
@@ -1241,7 +1241,8 @@ handle_command_unlock_lock (gint        *argc,
   options = g_variant_builder_end (&builder);
   g_variant_ref_sink (options);
 
-  passphrase = read_passphrase ();
+  if (is_unlock)
+    passphrase = read_passphrase ();
 
  try_again:
   if (is_unlock)