sh: Remove stray variable
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
00832163d4
commit
b7a0ad8ffb
@ -69,8 +69,6 @@ Result<int> luna_main(int argc, char** argv)
|
||||
|
||||
if (!strncmp(cmd.chars(), "cd", 2))
|
||||
{
|
||||
char* copy = nullptr;
|
||||
|
||||
auto args = TRY(split_command_into_args(cmd.view()));
|
||||
check(args[0].view() == "cd");
|
||||
|
||||
@ -78,12 +76,10 @@ Result<int> luna_main(int argc, char** argv)
|
||||
{
|
||||
auto home = TRY(os::FileSystem::home_directory());
|
||||
if (chdir(home.chars()) < 0) perror("cd");
|
||||
free(copy);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (chdir(args[1].chars()) < 0) perror("cd");
|
||||
free(copy);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user