[tracker] tracker-status: Error if miner is supplied without pause/resume
- From: Martyn James Russell <mr src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [tracker] tracker-status: Error if miner is supplied without pause/resume
- Date: Mon, 1 Feb 2010 20:54:07 +0000 (UTC)
commit 49057c265b51ca2b3fcf1cb928d97550e8585480
Author: Martyn Russell <martyn lanedo com>
Date: Mon Feb 1 18:59:51 2010 +0000
tracker-status: Error if miner is supplied without pause/resume
src/tracker-utils/tracker-status.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/src/tracker-utils/tracker-status.c b/src/tracker-utils/tracker-status.c
index 61196ee..f61002f 100644
--- a/src/tracker-utils/tracker-status.c
+++ b/src/tracker-utils/tracker-status.c
@@ -384,6 +384,20 @@ main (gint argc, gchar *argv[])
return EXIT_FAILURE;
}
+ if ((!pause_reason || resume_cookie == -1) && miner_name) {
+ gchar *help;
+
+ g_printerr ("%s\n\n",
+ _("You must provide a pause or resume command for the miner"));
+
+ help = g_option_context_get_help (context, TRUE, NULL);
+ g_option_context_free (context);
+ g_printerr ("%s", help);
+ g_free (help);
+
+ return EXIT_FAILURE;
+ }
+
g_option_context_free (context);
g_type_init ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]