Alexandre Julliard : server: Print process/
thread id instead of pointer in protocol errors.
Alexandre Julliard
julliard at wine.codeweavers.com
Wed Jun 7 07:49:24 CDT 2006
Module: wine
Branch: refs/heads/master
Commit: 202ef6901e7e29f02d590278d7ab46991e262425
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=202ef6901e7e29f02d590278d7ab46991e262425
Author: Alexandre Julliard <julliard at winehq.org>
Date: Wed Jun 7 14:20:38 2006 +0200
server: Print process/thread id instead of pointer in protocol errors.
---
server/request.c | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/server/request.c b/server/request.c
index c6b4472..9ae5fa4 100644
--- a/server/request.c
+++ b/server/request.c
@@ -141,7 +141,7 @@ void fatal_protocol_error( struct thread
va_list args;
va_start( args, err );
- fprintf( stderr, "Protocol error:%p: ", thread );
+ fprintf( stderr, "Protocol error:%04x: ", thread->id );
vfprintf( stderr, err, args );
va_end( args );
thread->exit_code = 1;
@@ -154,7 +154,7 @@ void fatal_protocol_perror( struct threa
va_list args;
va_start( args, err );
- fprintf( stderr, "Protocol error:%p: ", thread );
+ fprintf( stderr, "Protocol error:%04x: ", thread->id );
vfprintf( stderr, err, args );
perror( " " );
va_end( args );
@@ -397,15 +397,15 @@ #endif
}
else if (ret > 0)
{
- fprintf( stderr, "Protocol error: process %p: partial recvmsg %d for fd\n",
- process, ret );
+ fprintf( stderr, "Protocol error: process %04x: partial recvmsg %d for fd\n",
+ process->id, ret );
kill_process( process, NULL, 1 );
}
else
{
if (errno != EWOULDBLOCK && errno != EAGAIN)
{
- fprintf( stderr, "Protocol error: process %p: ", process );
+ fprintf( stderr, "Protocol error: process %04x: ", process->id );
perror( "recvmsg" );
kill_process( process, NULL, 1 );
}
@@ -440,7 +440,7 @@ #endif /* HAVE_STRUCT_MSGHDR_MSG_ACCRIG
if (ret >= 0)
{
- fprintf( stderr, "Protocol error: process %p: partial sendmsg %d\n", process, ret );
+ fprintf( stderr, "Protocol error: process %04x: partial sendmsg %d\n", process->id, ret );
kill_process( process, NULL, 1 );
}
else if (errno == EPIPE)
@@ -449,7 +449,7 @@ #endif /* HAVE_STRUCT_MSGHDR_MSG_ACCRIG
}
else
{
- fprintf( stderr, "Protocol error: process %p: ", process );
+ fprintf( stderr, "Protocol error: process %04x: ", process->id );
perror( "sendmsg" );
kill_process( process, NULL, 1 );
}
More information about the wine-cvs
mailing list