Skip to content

Commit 5096d54

Browse files
Reject empty operand in cd built-in
Co-authored-by: WATANABE Yuki <[email protected]>
1 parent fc9a5d8 commit 5096d54

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

path.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1232,7 +1232,7 @@ int change_directory(
12321232

12331233
assert(!logical || !ensure_pwd);
12341234

1235-
if ( newpwd[0] == L'\0' ) {
1235+
if (newpwd[0] == L'\0') {
12361236
xerror(0, Ngt("empty directory"));
12371237
return 5;
12381238
}

0 commit comments

Comments
 (0)