Changeset 24825 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- Nov 20, 2009 2:41:05 PM (15 years ago)
- svn:sync-xref-src-repo-rev:
- 55049
- Location:
- trunk/src/VBox/Runtime
- Files:
-
- 1 added
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/Makefile.kmk
r24662 r24825 239 239 common/misc/handletablectx.cpp \ 240 240 common/misc/handletablesimple.cpp \ 241 common/misc/message.cpp \ 241 242 common/misc/once.cpp \ 242 243 common/misc/req.cpp \ -
trunk/src/VBox/Runtime/common/misc/getopt.cpp
r24140 r24825 36 36 #include "internal/iprt.h" 37 37 38 #include <iprt/err.h>39 #include <iprt/string.h>40 38 #include <iprt/assert.h> 41 39 #include <iprt/ctype.h> 40 #include <iprt/err.h> 41 #include <iprt/message.h> 42 #include <iprt/string.h> 42 43 #include <iprt/uuid.h> 43 44 … … 640 641 } 641 642 RT_EXPORT_SYMBOL(RTGetOptFetchValue); 643 644 645 RTDECL(int) RTGetOptPrintError(int ch, PCRTGETOPTUNION pValueUnion) 646 { 647 if (ch == VINF_GETOPT_NOT_OPTION) 648 RTMsgError("Invalid parameter: %s", pValueUnion->psz); 649 else if (ch > 0) 650 { 651 if (RT_C_IS_GRAPH(ch)) 652 RTMsgError("Unhandled option: -%c", ch); 653 else 654 RTMsgError("Unhandled option: %i (%#x)", ch, ch); 655 } 656 else if (ch == VERR_GETOPT_UNKNOWN_OPTION) 657 RTMsgError("Unknown option: '%s'", pValueUnion->psz); 658 else if (pValueUnion->pDef) 659 RTMsgError("%s: %Rrs\n", pValueUnion->pDef->pszLong, ch); 660 else 661 RTMsgError("%Rrs\n", ch); 662 663 return 2; /** @todo add defines for EXIT_SUCCESS, EXIT_FAILURE, EXIT_INVAL, etc... */ 664 } 665 RT_EXPORT_SYMBOL(RTGetOptPrintError); 666
Note:
See TracChangeset
for help on using the changeset viewer.