pike.git
/
src
/
combine_path.h
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/combine_path.h:1:
/*
-
* $Id: combine_path.h,v 1.
3
2001/06/10
14
:
53
:
29
grubba Exp $
+
* $Id: combine_path.h,v 1.
4
2001/06/10
16
:
02
:
40
grubba Exp $
* * Combine path template. * */ #undef IS_SEP #undef IS_ABS #undef IS_ROOT #undef F_COMBINE_PATH #undef APPEND_PATH
pike.git/src/combine_path.h:138:
if (tmp) { while(--tmp>=0) if(IS_SEP(index_shared_string(s->s, tmp))) break; tmp++; } else if (IS_SEP(index_shared_string(s->s, 0))) { tmp++; }
-
if(index_shared_string(s->s,tmp)=='.' &&
-
index_shared_string(s->s,tmp+1)=='.' &&
+
if
(
(tmp+2 < s->s->len) &&
+
(
index_shared_string(s->s,tmp)=='.'
)
&&
+
(
index_shared_string(s->s,tmp+1)=='.'
)
&&
( IS_SEP(index_shared_string(s->s,tmp+2)) || !index_shared_string(s->s,tmp+2))) break; from+=2; s->s->len=tmp; s->known_shift=0; #if COMBINE_PATH_DEBUG > 0