From 6b5ac8d538ffc395e7efb51cc9b27eb531c19566 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sat, 28 Mar 2020 14:59:24 +0100 Subject: [PATCH] dosname: Change IS_RELATIVE_FILE_NAME. * lib/dosname.h (IS_RELATIVE_FILE_NAME): On native Windows, OS/2, DOS, change the definition so that IS_RELATIVE_FILE_NAME("c:") is false. * NEWS: Mention the change. --- ChangeLog | 7 +++++++ NEWS | 3 +++ lib/dosname.h | 3 ++- 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index a238b1fc70..af102e1dbb 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2020-03-28 Bruno Haible + + dosname: Change IS_RELATIVE_FILE_NAME. + * lib/dosname.h (IS_RELATIVE_FILE_NAME): On native Windows, OS/2, DOS, + change the definition so that IS_RELATIVE_FILE_NAME("c:") is false. + * NEWS: Mention the change. + 2020-03-28 Bruno Haible filename: Copy some definitions from module 'dosname'. diff --git a/NEWS b/NEWS index 3ec49f34e2..c9548d5b28 100644 --- a/NEWS +++ b/NEWS @@ -58,6 +58,9 @@ User visible incompatible changes Date Modules Changes +2020-03-28 dosname On native Windows, OS/2, DOS, + IS_RELATIVE_FILE_NAME("c:") now returns false. + 2020-03-28 filename The macro IS_ABSOLUTE_PATH is deprecated. Use IS_ABSOLUTE_FILE_NAME instead. The macro IS_PATH_WITH_DIR is deprecated. Use diff --git a/lib/dosname.h b/lib/dosname.h index 5782960094..926a6955bf 100644 --- a/lib/dosname.h +++ b/lib/dosname.h @@ -47,6 +47,7 @@ # define IS_ABSOLUTE_FILE_NAME(F) \ (ISSLASH ((F)[0]) || FILE_SYSTEM_PREFIX_LEN (F) != 0) #endif -#define IS_RELATIVE_FILE_NAME(F) (! IS_ABSOLUTE_FILE_NAME (F)) +#define IS_RELATIVE_FILE_NAME(F) \ + (! (ISSLASH ((F)[0]) || FILE_SYSTEM_PREFIX_LEN (F) != 0)) #endif /* DOSNAME_H_ */ -- 2.39.5