Module Name: src Committed By: kre Date: Sat Aug 3 03:05:58 UTC 2024
Modified Files: src/bin/sh: eval.c eval.h input.c input.h Log Message: Change the "string" argument to evalstring() and setinputstring() from being "char *" to being "const char *". This is needed for a forthcoming change which needs to pass a const char * to evalstring (and through it to setinputstring) and be assured that nothing will alter the characters in the string supplied. This is (aside from the additional compile time protection provided) a no-op change, all evalstring() does with its string is pass it to setinputstring() and all that does with it is determine its length (strlen() which expects a const char *) and assign the string pointer to parsenextc which is already a const char * - there never has been any reason for these two functions to not include the "const" in the arg declaration -- except that when originally written (early 1990's) I suspect "const" either didn't exist at all, or wasn't supported by relevant compilers. NFCI. Most probably (though I didn't check) no binary change at all. To generate a diff of this commit: cvs rdiff -u -r1.192 -r1.193 src/bin/sh/eval.c cvs rdiff -u -r1.23 -r1.24 src/bin/sh/eval.h cvs rdiff -u -r1.73 -r1.74 src/bin/sh/input.c cvs rdiff -u -r1.21 -r1.22 src/bin/sh/input.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.