diff options
author | Johnny Willemsen <jwillemsen@remedy.nl> | 2009-02-13 13:31:02 +0000 |
---|---|---|
committer | Johnny Willemsen <jwillemsen@remedy.nl> | 2009-02-13 13:31:02 +0000 |
commit | 8bd3b08eb5ea4d76a7f025de00b89c040c056c27 (patch) | |
tree | 8cdee4d34eea2e115fdf686776522a440c1bb410 /ACE/ace/Dev_Poll_Reactor.cpp | |
parent | 6db2901cb5fb8b7d8f303e199406f603354fa2b4 (diff) | |
download | ATCD-8bd3b08eb5ea4d76a7f025de00b89c040c056c27.tar.gz |
Fri Feb 13 13:30:28 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl>
* ace/Dev_Poll_Reactor.cpp
* ace/Log_Msg.cpp
* ace/MEM_Acceptor.cpp
* ace/MMAP_Memory_Pool.cpp
* ace/POSIX_Asynch_IO.cpp
* ace/POSIX_CB_Proactor.cpp
* ace/POSIX_Proactor.cpp
* ace/Registry_Name_Space.cpp
* ace/Remote_Tokens.cpp
* ace/Service_Config.cpp
* ace/Service_Gestalt.cpp
* ace/Shared_Memory_Pool.cpp
* ace/SOCK_Dgram_Bcast.cpp
* ace/SUN_Proactor.cpp
* ace/TLI.cpp
Use ACE_TEXT() with %p in ACE_DEBUG/ACE_ERROR. The log string
passed to ACE_DEBUG/ACE_ERROR is converted automatically to
unicode in an unicode build. The %p expects an unicode string,
if a plain ascii string is passed in, this is just handled as
unicode string and could lead to a crash because then we are
just reading random memory
Diffstat (limited to 'ACE/ace/Dev_Poll_Reactor.cpp')
-rw-r--r-- | ACE/ace/Dev_Poll_Reactor.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ACE/ace/Dev_Poll_Reactor.cpp b/ACE/ace/Dev_Poll_Reactor.cpp index 98dfbace9c5..7697bc48383 100644 --- a/ACE/ace/Dev_Poll_Reactor.cpp +++ b/ACE/ace/Dev_Poll_Reactor.cpp @@ -1051,7 +1051,7 @@ ACE_Dev_Poll_Reactor::handle_events_i (ACE_Time_Value *max_wait_time, { result = this->work_pending_i (max_wait_time); if (result == -1) - ACE_ERROR ((LM_ERROR, "%t: %p\n", "work_pending_i")); + ACE_ERROR ((LM_ERROR, ACE_TEXT("%t: %p\n"), ACE_TEXT("work_pending_i"))); } while (result == -1 && this->restart_ != 0 && errno == EINTR); @@ -1415,7 +1415,7 @@ ACE_Dev_Poll_Reactor::register_handler_i (ACE_HANDLE handle, if (::epoll_ctl (this->poll_fd_, op, handle, &epev) == -1) { - ACE_ERROR ((LM_ERROR, "%p\n", "epoll_ctl")); + ACE_ERROR ((LM_ERROR, ACE_TEXT("%p\n"), ACE_TEXT("epoll_ctl"))); (void) this->handler_rep_.unbind (handle); return -1; } @@ -1428,7 +1428,7 @@ ACE_Dev_Poll_Reactor::register_handler_i (ACE_HANDLE handle, // again, possibly for different event. Add new mask to the // current one. if (this->mask_ops_i (handle, mask, ACE_Reactor::ADD_MASK) == -1) - ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "mask_ops_i"), -1); + ACE_ERROR_RETURN ((LM_ERROR, ACE_TEXT("%p\n"), ACE_TEXT("mask_ops_i")), -1); } #ifndef ACE_HAS_EVENT_POLL @@ -2465,7 +2465,7 @@ ACE_Dev_Poll_Reactor::Token_Guard::acquire_quietly (ACE_Time_Value *max_wait) return 0; else { - ACE_ERROR ((LM_ERROR, "%t: %p\n", "token acquire_read")); + ACE_ERROR ((LM_ERROR, ACE_TEXT("%t: %p\n"), ACE_TEXT("token acquire_read"))); return -1; } } |