summaryrefslogtreecommitdiffstats
path: root/include/helper.h
diff options
context:
space:
mode:
authorQC <qball@gmpclient.org>2015-01-31 18:23:17 +0100
committerQC <qball@gmpclient.org>2015-01-31 18:23:17 +0100
commitb74e6b791a09880a3699ce8199a47786a70ca575 (patch)
tree06d4670fb5b9c72d38e38444c416f1e480c74bf0 /include/helper.h
parent983fff61b456b202c90552beeea85ab75499ee3a (diff)
Fix not grabbing keyboard, and add pid file to ensure one instance.
Diffstat (limited to 'include/helper.h')
-rw-r--r--include/helper.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/helper.h b/include/helper.h
index 9e75c336..98f18627 100644
--- a/include/helper.h
+++ b/include/helper.h
@@ -89,6 +89,18 @@ int find_arg_int ( const int argc, char * const argv[], const char * const key,
* @returns TRUE if key was found and val was set.
*/
int find_arg_str ( const int argc, char * const argv[], const char * const key, char** val );
+/**
+ * @param argc Number of arguments.
+ * @param argv 2 dimensional array of arguments.
+ * @param key The key to search for
+ * @param val Pointer to the string to set to the key value (if found)
+ *
+ * Parse command line argument 'key' to string.
+ * Creates an allocated copy of the string.
+ *
+ * @returns TRUE if key was found and val was set.
+ */
+int find_arg_str_alloc ( const int argc, char * const argv[], const char * const key, char** val );
/**
* @param argc Number of arguments.