[hipl-dev] [Branch ~toxedvirus/hipl/hipfw-modules] Rev 5009: Add documentation for hip_cmd_options_parase, add documentation for missing paramter, fix typo in...

  • From: noreply@xxxxxxxxxxxxx
  • To: HIPL core team <hipl-dev@xxxxxxxxxxxxx>
  • Date: Wed, 03 Nov 2010 17:11:29 -0000

------------------------------------------------------------
revno: 5009
committer: Andrius Bentkus <andrius.bentkus@xxxxxxxxxxxxxx>
branch nick: hipfw-modules
timestamp: Wed 2010-11-03 18:09:38 +0100
message:
  Add documentation for hip_cmd_options_parase, add documentation for missing 
paramter, fix typo in documentation.
modified:
  lib/core/options.c


--
lp:~toxedvirus/hipl/hipfw-modules
https://code.launchpad.net/~toxedvirus/hipl/hipfw-modules

Your team HIPL core team is subscribed to branch 
lp:~toxedvirus/hipl/hipfw-modules.
To unsubscribe from this branch go to 
https://code.launchpad.net/~toxedvirus/hipl/hipfw-modules/+edit-subscription
=== modified file 'lib/core/options.c'
--- lib/core/options.c  2010-11-03 16:46:44 +0000
+++ lib/core/options.c  2010-11-03 17:09:38 +0000
@@ -104,7 +104,7 @@
  *
  * @param list       Pointer to a list where to search for the option.
  * @param short_name Option name (one character) for which to search
- * @return Success = pointer to the specific option struct
+ * @return Success = pointer to the specific option struct,
  *         Error   = NULL (not found)
  */
 static struct hip_cmd_option *hip_cmd_options_get(const struct 
hip_cmd_option_list *list, char short_name)
@@ -200,7 +200,7 @@
  * Calculate the size of the option string needed by optarg.
  *
  * @param  list Pointer to the list from which to generate the option string.
- * @return size of the generated string that is needed by hold the information
+ * @return size of the generated string that is needed to hold the information
  *         of getopt including the space for the string delimter.
  * @note   the function includes the trailing white space size requiremet
  */
@@ -224,6 +224,7 @@
  *
  * @param list    Pointer to list, head must be initialized with NULL.
  * @param options Pointer to options to be added.
+ * @param size    Count of elemnts in the options struct
  * @return        Size (element count) of the options array to be added.
  */
 void hip_cmd_options_add(struct hip_cmd_option_list *list,
@@ -302,6 +303,10 @@
  * @param argc Argument count.
  * @param argv Array of argument strings.
  * @param list List of options to check against.
+ * @return     1 if the missing_option   handle is not existent but needed,
+ *             2 if the missing_argument handle is not existent but needed,
+ *             Passes the error code of the option handler if it faces some 
error,
+ *             0 on success
  */
 int hip_cmd_options_parse(const int argc,
                           char **argv,

Other related posts: