summaryrefslogtreecommitdiff
path: root/gcc/xcoffout.h
diff options
context:
space:
mode:
authoreggert <eggert@138bc75d-0d04-0410-961f-82ee72b054a4>1993-09-28 00:23:58 +0000
committereggert <eggert@138bc75d-0d04-0410-961f-82ee72b054a4>1993-09-28 00:23:58 +0000
commite1ad0d2b757b7b33ce11c479fbf655773967af65 (patch)
treec210dbf4f4dc91205e4aca11a7f28ce7357c4ddf /gcc/xcoffout.h
parenta5f6f9df096e71473441ca16478ff4c9f877d4fa (diff)
downloadgcc-e1ad0d2b757b7b33ce11c479fbf655773967af65.tar.gz
(DBX_OUTPUT_MAIN_SOURCE_DIRECTORY, DBX_OUTPUT_MAIN_SOURCE_FILENAME):
Quote special characters in file names. (DBX_OUTPUT_MAIN_SOURCE_FILE_END): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@5498 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/xcoffout.h')
-rw-r--r--gcc/xcoffout.h21
1 files changed, 16 insertions, 5 deletions
diff --git a/gcc/xcoffout.h b/gcc/xcoffout.h
index 9c38fc5b482..0fbd4131375 100644
--- a/gcc/xcoffout.h
+++ b/gcc/xcoffout.h
@@ -124,7 +124,11 @@ extern char *xcoff_read_only_section_name;
/* Write out main source file name using ".file" rather than ".stabs". */
#define DBX_OUTPUT_MAIN_SOURCE_FILENAME(FILE,FILENAME) \
- fprintf (FILE, "\t.file\t\"%s\"\n", FILENAME);
+ do { \
+ fprintf (FILE, "\t.file\t", FILENAME); \
+ output_quoted_string (FILE, FILENAME); \
+ fprintf (FILE, "\n"); \
+ } while (0)
#define ABS_OR_RELATIVE_LINENO(LINENO) \
((xcoff_current_include_file \
@@ -142,10 +146,16 @@ extern char *xcoff_read_only_section_name;
#define DBX_OUTPUT_SOURCE_FILENAME(FILE, FILENAME) \
{ \
if (xcoff_current_include_file) \
- fprintf (FILE, "\t.ei\t\"%s\"\n", xcoff_current_include_file);\
+ { \
+ fprintf (FILE, "\t.ei\t"); \
+ output_quoted_string (FILE, xcoff_current_include_file); \
+ fprintf (FILE, "\n"); \
+ } \
if (strcmp (main_input_filename, FILENAME)) \
{ \
- fprintf (FILE, "\t.bi\t\"%s\"\n", FILENAME); \
+ fprintf (FILE, "\t.bi\t"); \
+ output_quoted_string (FILE, FILENAME); \
+ fprintf (FILE, "\n"); \
xcoff_current_include_file = FILENAME; \
} \
else \
@@ -157,8 +167,9 @@ extern char *xcoff_read_only_section_name;
{ \
if (xcoff_current_include_file) \
{ \
- fprintf ((FILE), "\t.ei\t\"%s\"\n", \
- xcoff_current_include_file); \
+ fprintf (FILE, "\t.ei\t"); \
+ output_quoted_string (FILE, xcoff_current_include_file); \
+ fprintf (FILE, "\n"); \
xcoff_current_include_file = NULL; \
} \
}