Shell: cd command fixed

git-svn-id: svn://kolibrios.org@2323 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Albom 2011-12-15 18:06:01 +00:00
parent 57c28de885
commit 94572b7fe1
4 changed files with 6 additions and 3 deletions

View File

@ -37,10 +37,13 @@ if ( '/' == dir[0])
else else
{ {
strcpy(temp, cur_dir); strcpy(temp, cur_dir);
if (cur_dir[strlen(cur_dir)-1] != '/')
strcat(temp, "/");
strcat(temp, dir); strcat(temp, dir);
if ( dir_check(temp) ) if ( dir_check(temp) )
{ {
strcpy(cur_dir, temp); strcpy(cur_dir, temp);
return TRUE; return TRUE;
} }

View File

@ -1,5 +1,5 @@
@echo off @echo off
erase shell.kex lang.h erase lang.h
echo #define LANG_ENG 1 > lang.h echo #define LANG_ENG 1 > lang.h
fasm start.asm start.o fasm start.asm start.o
gcc -c shell.c gcc -c shell.c

View File

@ -1,5 +1,5 @@
@echo off @echo off
erase shell.kex lang.h erase lang.h
echo #define LANG_RUS 1 > lang.h echo #define LANG_RUS 1 > lang.h
fasm start.asm start.o fasm start.asm start.o
gcc -c shell.c gcc -c shell.c

View File

@ -1,5 +1,5 @@
#define SHELL_VERSION "0.4.9" #define SHELL_VERSION "0.4.91"
extern char PATH[256]; extern char PATH[256];
extern char PARAM[256]; extern char PARAM[256];