Michael Schröder
b264fccf9e
-> OBS-URL: https://build.opensuse.org/request/show/434537 OBS-URL: https://build.opensuse.org/package/show/shells/ksh?expand=0&rev=215
20 lines
514 B
Plaintext
20 lines
514 B
Plaintext
--- ./src/cmd/ksh93/bltins/cd_pwd.c.orig 2014-11-13 16:07:38.336318883 +0000
|
|
+++ ./src/cmd/ksh93/bltins/cd_pwd.c 2014-11-13 16:24:53.323415375 +0000
|
|
@@ -116,9 +116,14 @@ int b_cd(int argc, char *argv[],Shbltin_
|
|
char *sp;
|
|
for(dp=dir; *dp=='.'; dp++)
|
|
{
|
|
- if(*++dp=='.' && (*++dp=='/' || *dp==0))
|
|
+ if (dp[1]=='.' && (dp[2]=='/' || dp[2]==0))
|
|
+ {
|
|
n++;
|
|
- else if(*dp && *dp!='/')
|
|
+ dp += 2;
|
|
+ }
|
|
+ else if (dp[1]=='/' || dp[1]==0)
|
|
+ dp++;
|
|
+ else
|
|
break;
|
|
if(*dp==0)
|
|
break;
|