From: Alan Modra Date: Wed, 10 Sep 2003 12:02:51 +0000 (+0000) Subject: basic_file_stdio.cc (_M_open_mode): Assign __p_mode rather than or'ing. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=80e46d778a7038aaed9b5bdee838cf5dca279d7e;p=gcc.git basic_file_stdio.cc (_M_open_mode): Assign __p_mode rather than or'ing. * config/io/basic_file_stdio.cc (_M_open_mode): Assign __p_mode rather than or'ing. From-SVN: r71265 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 776eadf72cc..6df79ce5cd8 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2003-09-10 Alan Modra + + * config/io/basic_file_stdio.cc (_M_open_mode): Assign __p_mode + rather than or'ing. + 2003-09-09 Alan Modra * configure: Regenerate. diff --git a/libstdc++-v3/config/io/basic_file_stdio.cc b/libstdc++-v3/config/io/basic_file_stdio.cc index 5a3921c46d3..5791135eb54 100644 --- a/libstdc++-v3/config/io/basic_file_stdio.cc +++ b/libstdc++-v3/config/io/basic_file_stdio.cc @@ -87,33 +87,33 @@ namespace std if (!__testi && __testo && !__testt && !__testa) { strcpy(__c_mode, "w"); - __p_mode = (O_WRONLY | O_CREAT); + __p_mode = O_WRONLY | O_CREAT; } if (!__testi && __testo && !__testt && __testa) { strcpy(__c_mode, "a"); - __p_mode |= O_WRONLY | O_CREAT | O_APPEND; + __p_mode = O_WRONLY | O_CREAT | O_APPEND; } if (!__testi && __testo && __testt && !__testa) { strcpy(__c_mode, "w"); - __p_mode |= O_WRONLY | O_CREAT | O_TRUNC; + __p_mode = O_WRONLY | O_CREAT | O_TRUNC; } if (__testi && !__testo && !__testt && !__testa) { strcpy(__c_mode, "r"); - __p_mode |= O_RDONLY; + __p_mode = O_RDONLY; } if (__testi && __testo && !__testt && !__testa) { strcpy(__c_mode, "r+"); - __p_mode |= O_RDWR | O_CREAT; + __p_mode = O_RDWR | O_CREAT; } if (__testi && __testo && __testt && !__testa) { strcpy(__c_mode, "w+"); - __p_mode |= O_RDWR | O_CREAT | O_TRUNC; + __p_mode = O_RDWR | O_CREAT | O_TRUNC; } if (__testb) strcat(__c_mode, "b");