Fossil SCM

Fixed error with absolute pathnames when opening a repo on Win32

mjanssen 2007-09-24 19:42 trunk
Commit c841af0d501417c67cc1e8758ebbb85381c5e5d7
2 files changed +1 -1 +1 -1
+1 -1
--- Makefile.w32
+++ Makefile.w32
@@ -25,11 +25,11 @@
2525
# for building intermediate code-generator tools.
2626
#
2727
#TCC = gcc -O6
2828
#TCC = gcc -g -O0 -Wall -fprofile-arcs -ftest-coverage
2929
#TCC = gcc -g -Os -Wall
30
-TCC = gcc -g -Os -Wall -DFOSSIL_I18N=0
30
+TCC = gcc -g -Os -Wall -DFOSSIL_I18N=0 -L/usr/local/lib -I/usr/local/include
3131
3232
#### Extra arguments for linking the finished binary. Fossil needs
3333
# to link against the Z-Lib compression library. There are no
3434
# other dependencies. We sometimes add the -static option here
3535
# so that we can build a static executable that will run in a
3636
--- Makefile.w32
+++ Makefile.w32
@@ -25,11 +25,11 @@
25 # for building intermediate code-generator tools.
26 #
27 #TCC = gcc -O6
28 #TCC = gcc -g -O0 -Wall -fprofile-arcs -ftest-coverage
29 #TCC = gcc -g -Os -Wall
30 TCC = gcc -g -Os -Wall -DFOSSIL_I18N=0
31
32 #### Extra arguments for linking the finished binary. Fossil needs
33 # to link against the Z-Lib compression library. There are no
34 # other dependencies. We sometimes add the -static option here
35 # so that we can build a static executable that will run in a
36
--- Makefile.w32
+++ Makefile.w32
@@ -25,11 +25,11 @@
25 # for building intermediate code-generator tools.
26 #
27 #TCC = gcc -O6
28 #TCC = gcc -g -O0 -Wall -fprofile-arcs -ftest-coverage
29 #TCC = gcc -g -Os -Wall
30 TCC = gcc -g -Os -Wall -DFOSSIL_I18N=0 -L/usr/local/lib -I/usr/local/include
31
32 #### Extra arguments for linking the finished binary. Fossil needs
33 # to link against the Z-Lib compression library. There are no
34 # other dependencies. We sometimes add the -static option here
35 # so that we can build a static executable that will run in a
36
+1 -1
--- src/file.c
+++ src/file.c
@@ -182,11 +182,11 @@
182182
** Remove redundant / characters
183183
** Remove all /./ path elements.
184184
** Convert /A/../ to just /
185185
*/
186186
void file_canonical_name(const char *zOrigName, Blob *pOut){
187
- if( zOrigName[0]=='/' ){
187
+ if( zOrigName[0]=='/' || (zOrigName[1]==':' && zOrigName[2]=='\\') ){
188188
blob_set(pOut, zOrigName);
189189
blob_materialize(pOut);
190190
}else{
191191
char zPwd[2000];
192192
if( getcwd(zPwd, sizeof(zPwd)-20)==0 ){
193193
--- src/file.c
+++ src/file.c
@@ -182,11 +182,11 @@
182 ** Remove redundant / characters
183 ** Remove all /./ path elements.
184 ** Convert /A/../ to just /
185 */
186 void file_canonical_name(const char *zOrigName, Blob *pOut){
187 if( zOrigName[0]=='/' ){
188 blob_set(pOut, zOrigName);
189 blob_materialize(pOut);
190 }else{
191 char zPwd[2000];
192 if( getcwd(zPwd, sizeof(zPwd)-20)==0 ){
193
--- src/file.c
+++ src/file.c
@@ -182,11 +182,11 @@
182 ** Remove redundant / characters
183 ** Remove all /./ path elements.
184 ** Convert /A/../ to just /
185 */
186 void file_canonical_name(const char *zOrigName, Blob *pOut){
187 if( zOrigName[0]=='/' || (zOrigName[1]==':' && zOrigName[2]=='\\') ){
188 blob_set(pOut, zOrigName);
189 blob_materialize(pOut);
190 }else{
191 char zPwd[2000];
192 if( getcwd(zPwd, sizeof(zPwd)-20)==0 ){
193

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button