[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
gEDA-cvs: CVS update: gsymcheck.c
User: ahvezda
Date: 05/03/06 21:11:38
Modified: . gsymcheck.c
Log:
Fixed bug that didn't allow absolute path specification on all libgeda
applications. Moved old schematic into test directory. Updated some golden
netlist files.
Revision Changes Path
1.37 +14 -4 eda/geda/devel/gsymcheck/src/gsymcheck.c
(In the diff below, changes in quantity of whitespace are not shown.)
Index: gsymcheck.c
===================================================================
RCS file: /home/cvspsrv/cvsroot/eda/geda/devel/gsymcheck/src/gsymcheck.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -b -r1.36 -r1.37
--- gsymcheck.c 26 Feb 2005 01:14:10 -0000 1.36
+++ gsymcheck.c 7 Mar 2005 02:11:37 -0000 1.37
@@ -102,10 +102,20 @@
i = argv_index;
while (argv[i] != NULL) {
- gchar *filename = g_build_path (G_DIR_SEPARATOR_S,
- cwd,
- argv[i],
- NULL);
+
+ gchar *filename;
+#ifdef __MINGW32__
+ if (argv[i][1] == ':' && (argv[i][2] == G_DIR_SEPARATOR ||
+ argv[i][2] == OTHER_PATH_SEPARATER_CHAR))
+#else
+ if (argv[i][0] == G_DIR_SEPARATOR)
+#endif
+ {
+ /* Path is already absolute so no need to do any concat of cwd */
+ filename = g_strdup (argv[i]);
+ } else {
+ filename = g_build_path (G_DIR_SEPARATOR_S, cwd, argv[i], NULL);
+ }
if (stat(filename, &buf) != 0) {
s_log_message("Could not open [%s]\n", filename);