summaryrefslogtreecommitdiff
path: root/ubi-utils/src/nand2bin.c
diff options
context:
space:
mode:
authorJosh Boyer <jwboyer@linux.ibm.com>2006-12-12 09:22:48 +0100
committerFrank Haverkamp <haver@vnet.ibm.com>2006-12-12 09:22:48 +0100
commitd45b87985d5371b2e47458ee0666f7979d5a8c21 (patch)
treea394d48bdc882367e1bf408f8e51ec9936b6819c /ubi-utils/src/nand2bin.c
parentda59698ccf81a1df3a250edb81a91f1b8a3decf0 (diff)
[PATCH] Minor ubi utils cleanups
Remove getopt extern declarations Minor whitespace cleanups Remove incorrect program names that snuck in during getopt rewrite Change comments to match reality Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com> Acked-by: Frank Haverkamp <haver@vnet.ibm.com>
Diffstat (limited to 'ubi-utils/src/nand2bin.c')
-rw-r--r--ubi-utils/src/nand2bin.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/ubi-utils/src/nand2bin.c b/ubi-utils/src/nand2bin.c
index 34cce40..636ee6f 100644
--- a/ubi-utils/src/nand2bin.c
+++ b/ubi-utils/src/nand2bin.c
@@ -20,6 +20,7 @@
* An utility to decompose NAND images and strip OOB off. Not yet finished ...
*
* 1.2 Removed argp because we want to use uClibc.
+ * 1.3 Minor cleanup
*/
#include <config.h>
@@ -39,14 +40,11 @@
#include "config.h"
#include "nandecc.h"
-#define PROGRAM_VERSION "1.2"
+#define PROGRAM_VERSION "1.3"
#define MAXPATH 1024
#define MIN(x,y) ((x)<(y)?(x):(y))
-extern char *optarg;
-extern int optind;
-
struct args {
const char *oob_file;
const char *output_file;
@@ -116,14 +114,12 @@ uint32_t str_to_num(char *str)
/*
* @brief Parse the arguments passed into the test case.
*
- * @param key The parameter.
- * @param arg Argument passed to parameter.
- * @param state Location to put information on parameters.
+ * @param argc The number of arguments
+ * @param argv The argument list
+ * @param args Pointer to program args structure
*
* @return error
*
- * Get the `input' argument from `argp_parse', which we know is a
- * pointer to our arguments structure.
*/
static int
parse_opt(int argc, char **argv, struct args *args)