Ok, now I think I understand what you mean.
Corrected patch is below.
regards
Mikolaj Sitarz
diff -ru global-5.7.5/libutil/find.c global-5.7.5b/libutil/find.c
--- global-5.7.5/libutil/find.c 2009-03-14 01:30:37.000000000 +0100
+++ global-5.7.5b/libutil/find.c 2009-08-02 17:16:31.000000000 +0200
@@ -475,7 +475,11 @@
/*
* rootdir always ends with '/'.
*/
+#if defined(_WIN32) || defined(__DJGPP__)
+ if (!strcmp(root+2, "/"))
+#else
if (!strcmp(root, "/"))
+#endif
strlimcpy(rootdir, root, sizeof(rootdir));
else
snprintf(rootdir, sizeof(rootdir), "%s/", root);
@@ -305,7 +305,11 @@
break;
} while (0);
}
+#if defined(_WIN32) || defined(__DJGPP__)
+ if (!strcmp(root+2, "/"))
+#else
if (!strcmp(root, "/"))
+#endif
strlimcpy(root_with_slash, root, sizeof(root_with_slash));
else
snprintf(root_with_slash, sizeof(root_with_slash), "%s/", root);
@@ -283,7 +283,12 @@
* was not found. If you would like to use such command, set the
* flag to 1.
*/
+#ifdef IGNORE_ERROR
+ xp->ignore_error = 1;
+#else
xp->ignore_error = 0;
+#endif
+
/*
* By default, we doesn't put the path to GPATH.
* This option is prepared for createtags() and updatetags().
On 8/2/09, Mikolaj Sitarz <[email protected]> wrote:
> On Sun, Aug 2, 2009 at 3:24 PM, Jason Hood<[email protected]> wrote:
>> It should always be "c:/", it's only the test that's failing.
>> The same test is also made in setupdbpath. I would suggest
>> conditionalising the strcmp itself, comparing with root+2.
>
> OK. Do you suggest some checking of the root length? Or rather we can
> be 100% sure and use strcmp(root+2,'/') ? Do you suggest any other
> place that it should be conditionalised?
>
> Mikolaj Sitarz
>
_______________________________________________
Bug-global mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-global