Index: generic/nsf.c =================================================================== diff -u -r0e8f3a70673d4c0b005344a8520f05913939de9b -r8a1a43a35c119f8a1c596e445b7a868cc1066b99 --- generic/nsf.c (.../nsf.c) (revision 0e8f3a70673d4c0b005344a8520f05913939de9b) +++ generic/nsf.c (.../nsf.c) (revision 8a1a43a35c119f8a1c596e445b7a868cc1066b99) @@ -16966,10 +16966,10 @@ /*fprintf(stderr, "ParamOptionParse name %s, option '%s' (%ld) disallowed %.6x\n", paramPtr->name, option, start, disallowedOptions);*/ - if (firstChar == 'r' && strncmp(option, "required", MAX(3, optionLength)) == 0) { + if (firstChar == 'r' && strncmp(option, "required", NsfMax(3, optionLength)) == 0) { paramPtr->flags |= NSF_ARG_REQUIRED; - } else if (firstChar == 'o' && strncmp(option, "optional", MAX(3, optionLength)) == 0) { + } else if (firstChar == 'o' && strncmp(option, "optional", NsfMax(3, optionLength)) == 0) { paramPtr->flags &= ~NSF_ARG_REQUIRED; } else if (firstChar == 's' @@ -17124,7 +17124,7 @@ paramPtr->defaultValue = Tcl_NewBooleanObj(0); INCR_REF_COUNT(paramPtr->defaultValue); - } else if (firstChar == 'i' && strncmp(option, "integer", MAX(3, optionLength)) == 0) { + } else if (firstChar == 'i' && strncmp(option, "integer", NsfMax(3, optionLength)) == 0) { result = ParamOptionSetConverter(interp, paramPtr, "integer", Nsf_ConvertToInteger); } else if (firstChar == 'i' && strncmp(option, "int32", 5) == 0) { Index: generic/nsfInt.h =================================================================== diff -u -r1919d17fefad9446170fa6d532b439f494189b32 -r8a1a43a35c119f8a1c596e445b7a868cc1066b99 --- generic/nsfInt.h (.../nsfInt.h) (revision 1919d17fefad9446170fa6d532b439f494189b32) +++ generic/nsfInt.h (.../nsfInt.h) (revision 8a1a43a35c119f8a1c596e445b7a868cc1066b99) @@ -1363,5 +1363,7 @@ #define NsfHasTclSpace(str) \ (strpbrk((str), " \t\n\r\v\f") != NULL) +#define NsfMax(a,b) ((a) > (b) ? a : b) +#define NsfMin(a,b) ((a) < (b) ? a : b) #endif /* _nsf_int_h_ */