Skip to contentSkip to conversation

lib/parse_opts: Multiple fixes

PATCH In review Markos Chandras 4 participants 5 messages Jan 3, 2012 – Jan 4, 2012 Library code

lore
Share & tools
lore
#0 lore raw

PATCH 10/21 lib/parse_opts: Multiple fixes

Hi, please review the attached patch

Signature · 1 line
markos

From a1e992a25a19b7465c7a16dc317e10a104495b41 Mon Sep 17 00:00:00 2001
From: Markos Chandras <[email protected]>
Date: Mon, 21 Nov 2011 16:24:00 +0000
Subject: [PATCH 10/21] lib/parse_opts: Multiple fixes

- Fix TEST_RETURN definition
- drop undefined TIMING option
- Add missing argument for parse_opts when UNIT_TEST marco is used

---
 lib/parse_opts.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)
lib/parse_opts.c +2 -3
index 8a235b1..aa2433f 100644
@@ -834,14 +834,13 @@ char *ptr;
 
 struct usc_errno_t TEST_VALID_ENO[USC_MAX_ERRNO];
 
-int TEST_RETURN;
+long TEST_RETURN;
 int TEST_ERRNO;
 
 /* for test specific parse_opts options */
 option_t Options[] = {
         { "help",  &Help2, NULL },      /* -help option */
         { "h",  &Help, NULL },          /* -h option */
- 	{ TIMING, NULL, NULL},		/* disable -timing option */
 
 #if INVALID_TEST_CASES
  	{ "missingflag", NULL, &ptr },  /* error */
@@ -858,7 +857,7 @@ int main(int argc, char **argv)
     struct timeval t;
     int cnt;
 
-    if ((msg = parse_opts(argc, argv, Options)) != NULL) {
+    if ((msg = parse_opts(argc, argv, Options, NULL)) != NULL) {
 	printf("ERROR: %s\n", msg);
 	exit(1);
     }
Signature · 1 line
1.7.1

------------------------------------------------------------------------------
Write once. Port to many.
Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join
http://p.sf.net/sfu/intel-appdev

_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reviewed-by on v1 10/21
#1 lore raw
Quoted 1 line · Markos Chandras

Hi, please review the attached patch

------------------------------------------------------------------------------
Write once. Port to many.
Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join
http://p.sf.net/sfu/intel-appdev
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

#2 lore raw
In reply to Markos Chandras
Quoted 1 line · On Tuesday 03 January 2012 06:10:37 Markos Chandras wrote:

Hi, please review the attached patch

looks good, but please write better changelogs

"- Fix TEST_RETURN definition" doesn't really tell much much. it should say something like "Fix TEST_RETURN definition to match that of the exported API in usctest.h".
-mike

------------------------------------------------------------------------------
Write once. Port to many.
Get the SDK and tools to simplify cross-platform app development. Create new or port existing apps to sell to consumers worldwide. Explore the Intel AppUpSM program developer opportunity. appdeveloper.intel.com/join
http://p.sf.net/sfu/intel-appdev

_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

#3 lore raw

Hi!

Quoted 4 lines

"- Fix TEST_RETURN definition" doesn't really tell much much. it should say something like "Fix TEST_RETURN definition to match that of the exported API in usctest.h".

+1.

Signature · 13 lines
Cyril Hrubis
[email protected]

------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list
#4 lore raw
In reply to Markos Chandras

Hi!

Quoted 3 lines

- Fix TEST_RETURN definition
- drop undefined TIMING option
- Add missing argument for parse_opts when UNIT_TEST marco is used

Commited, thanks.

Signature · 13 lines
Cyril Hrubis
[email protected]

------------------------------------------------------------------------------
Ridiculously easy VDI. With Citrix VDI-in-a-Box, you don't need a complex
infrastructure or vast IT resources to deliver seamless, secure access to
virtual desktops. With this all-in-one solution, easily deploy virtual 
desktops for less than the cost of PCs and save 60% on VDI infrastructure 
costs. Try it free! http://p.sf.net/sfu/Citrix-VDIinabox
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list