Vérification de toute la commande pour cd
This commit is contained in:
parent
05f62dfc6e
commit
831f45b662
1 changed files with 2 additions and 1 deletions
|
@ -61,8 +61,9 @@ void error(int code, int type, char *message)
|
||||||
int native_command(char *command[])
|
int native_command(char *command[])
|
||||||
{
|
{
|
||||||
int ret = 1; /* 0 si commande non native */
|
int ret = 1; /* 0 si commande non native */
|
||||||
if (!strncmp(command[0], "cd", 2))
|
if (!strcmp(command[0], "cd"))
|
||||||
change_dir(command[1]);
|
change_dir(command[1]);
|
||||||
|
|
||||||
else
|
else
|
||||||
ret = 0;
|
ret = 0;
|
||||||
return ret;
|
return ret;
|
||||||
|
|
Loading…
Reference in a new issue