diff options
author | Pedro Alves <palves@redhat.com> | 2015-03-09 11:29:56 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2015-03-09 11:29:57 +0000 |
commit | 9a9df97001814c87929826e6538762f3be07c4a4 (patch) | |
tree | 35a39438a137f5ce1036cf99ed3a950e67dbcb6f /gdb | |
parent | 9eb1356e381f3412f53ffe5bc68ce854330600fb (diff) | |
download | gdb-9a9df97001814c87929826e6538762f3be07c4a4.zip gdb-9a9df97001814c87929826e6538762f3be07c4a4.tar.gz gdb-9a9df97001814c87929826e6538762f3be07c4a4.tar.bz2 |
gdbserver/tracepoint: Add 'struct sockaddr_un *' -> 'struct sockaddr *' cast
Fixes this in C++ mode:
gdb/gdbserver/tracepoint.c: In function ‘void* gdb_agent_helper_thread(void*)’:
gdb/gdbserver/tracepoint.c:7190:47: error: cannot convert ‘sockaddr_un*’ to ‘sockaddr*’ for argument ‘2’ to ‘int accept(int, sockaddr*, socklen_t*)’
fd = accept (listen_fd, &sockaddr, &tmp);
gdb/gdbserver/ChangeLog:
2015-03-09 Pedro Alves <palves@redhat.com>
* tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to
'struct sockaddr' pointer in 'accept' call.
Diffstat (limited to 'gdb')
-rwxr-xr-x[-rw-r--r--] | gdb/features/feature_to_c.sh | 0 | ||||
-rw-r--r-- | gdb/gdbserver/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/gdbserver/tracepoint.c | 2 |
3 files changed, 6 insertions, 1 deletions
diff --git a/gdb/features/feature_to_c.sh b/gdb/features/feature_to_c.sh index 35db791..35db791 100644..100755 --- a/gdb/features/feature_to_c.sh +++ b/gdb/features/feature_to_c.sh diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index e26f123..d611bfd 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,5 +1,10 @@ 2015-03-09 Pedro Alves <palves@redhat.com> + * tracepoint.c (gdb_agent_helper_thread): Cast '&sockaddr' to + 'struct sockaddr' pointer in 'accept' call. + +2015-03-09 Pedro Alves <palves@redhat.com> + Revert: 2015-03-07 Pedro Alves <palves@redhat.com> * gdbreplay.c: No longer include <netinet/in.h>, <sys/socket.h>, diff --git a/gdb/gdbserver/tracepoint.c b/gdb/gdbserver/tracepoint.c index 27fcf03..42b27c0 100644 --- a/gdb/gdbserver/tracepoint.c +++ b/gdb/gdbserver/tracepoint.c @@ -7174,7 +7174,7 @@ gdb_agent_helper_thread (void *arg) do { - fd = accept (listen_fd, &sockaddr, &tmp); + fd = accept (listen_fd, (struct sockaddr *) &sockaddr, &tmp); } /* It seems an ERESTARTSYS can escape out of accept. */ while (fd == -512 || (fd == -1 && errno == EINTR)); |