unixware vi returns 256 instead of 0
This commit is contained in:
5
visudo.c
5
visudo.c
@@ -236,8 +236,9 @@ int main(argc, argv)
|
|||||||
else
|
else
|
||||||
(void) sprintf(buf, "%s %s", Editor, stmp);
|
(void) sprintf(buf, "%s %s", Editor, stmp);
|
||||||
|
|
||||||
/* do the edit */
|
/* do the edit -- some SYSV editors return 256 instead of 0 */
|
||||||
if (system(buf) == 0) {
|
n = system(buf);
|
||||||
|
if (n == 0 || n == 256) {
|
||||||
struct stat statbuf; /* for sanity checking */
|
struct stat statbuf; /* for sanity checking */
|
||||||
|
|
||||||
/* make sure stmp exists */
|
/* make sure stmp exists */
|
||||||
|
Reference in New Issue
Block a user