diff options
author | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2002-12-15 07:47:08 +0000 |
---|---|---|
committer | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2002-12-15 07:47:08 +0000 |
commit | dc1fdb7811138771e5e7a2014665712b8187bb21 (patch) | |
tree | 70da9e71158e9cac4b1f2c33ad60fd545401225d /TAO/TAO_IDL | |
parent | 8c04448a39b3a3655ec53a5732dc4a6fca10e0cc (diff) | |
download | ATCD-dc1fdb7811138771e5e7a2014665712b8187bb21.tar.gz |
ChangeLogTag: Sun Dec 15 01:37:14 2002 Jeff Parsons <j.parsons@vanderbilt.edu>
Diffstat (limited to 'TAO/TAO_IDL')
-rw-r--r-- | TAO/TAO_IDL/fe/idl.ll | 2 | ||||
-rw-r--r-- | TAO/TAO_IDL/fe/lex.yy.cpp | 2 | ||||
-rw-r--r-- | TAO/TAO_IDL/util/utl_global.cpp | 11 |
3 files changed, 13 insertions, 2 deletions
diff --git a/TAO/TAO_IDL/fe/idl.ll b/TAO/TAO_IDL/fe/idl.ll index 1f3daddcbca..28f0fb289bd 100644 --- a/TAO/TAO_IDL/fe/idl.ll +++ b/TAO/TAO_IDL/fe/idl.ll @@ -439,8 +439,8 @@ idl_parse_line_and_file (char *buf) h[i] = '\0'; ACE_NEW (tmp, UTL_String (h)); - idl_global->set_filename (tmp); idl_global->update_prefix (tmp->get_string ()); + idl_global->set_filename (tmp); } UTL_String *fname = idl_global->filename (); diff --git a/TAO/TAO_IDL/fe/lex.yy.cpp b/TAO/TAO_IDL/fe/lex.yy.cpp index 5882bb19706..7f3a3b949e4 100644 --- a/TAO/TAO_IDL/fe/lex.yy.cpp +++ b/TAO/TAO_IDL/fe/lex.yy.cpp @@ -2630,8 +2630,8 @@ idl_parse_line_and_file (char *buf) h[i] = '\0'; ACE_NEW (tmp, UTL_String (h)); - idl_global->set_filename (tmp); idl_global->update_prefix (tmp->get_string ()); + idl_global->set_filename (tmp); } UTL_String *fname = idl_global->filename (); diff --git a/TAO/TAO_IDL/util/utl_global.cpp b/TAO/TAO_IDL/util/utl_global.cpp index 38eb519013e..cb3b96b3170 100644 --- a/TAO/TAO_IDL/util/utl_global.cpp +++ b/TAO/TAO_IDL/util/utl_global.cpp @@ -914,6 +914,17 @@ IDL_GlobalData::pragma_prefixes (void) void IDL_GlobalData::update_prefix (char *filename) { + UTL_String *fname = idl_global->filename (); + + // We have to do this check because some preprocessors (gcc 3.2 + // on RedHat Linux 7.1, for one) output the same filename + // multiple times for no apparent reason, and we don't want it + // to clear the prefix. + if (fname && ACE_OS::strcmp (fname->get_string (), filename) == 0) + { + return; + } + ACE_CString tmp ("", 0, 0); ACE_CString fn (filename, 0, 0); (void) this->file_prefixes_.trybind (fn, tmp); |