[Bug 16734] New: get_ptrace_tid defined but not used on OpenBSD
http://bugs.winehq.org/show_bug.cgi?id=16734 Summary: get_ptrace_tid defined but not used on OpenBSD Product: Wine Version: 1.1.12 Platform: PC OS/Version: OpenBSD Status: NEW Keywords: patch, source Severity: trivial Priority: P2 Component: build-env AssignedTo: wine-bugs(a)winehq.org ReportedBy: austinenglish(a)gmail.com ccache gcc -c -I. -I. -I../include -I../include -D__WINESRC__ -Wall -pipe -fno-strict-aliasing -Wwrite-strings -Wpointer-arith -I/usr/local/include -g -O2 -o ptrace.o ptrace.c ptrace.c:174: warning: `get_ptrace_tid' defined but not used There's an '#ifdef linux' on the same code a few lines earlier (in get_ptrace_tid), which fixes compile here as well: diff --git a/server/ptrace.c b/server/ptrace.c index b446de9..92b7db5 100644 --- a/server/ptrace.c +++ b/server/ptrace.c @@ -172,7 +172,9 @@ static int get_ptrace_pid( struct thread *thread ) /* return the Unix tid to use in ptrace calls for a given thread */ static int get_ptrace_tid( struct thread *thread ) { +#ifdef linux if (thread->unix_tid != -1) return thread->unix_tid; +#endif return thread->unix_pid; } but I'm not sure if that's right or not. Comments welcome. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #1 from Austin English <austinenglish(a)gmail.com> 2009-01-02 23:28:38 --- Also affects linux on ppc. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #2 from Austin English <austinenglish(a)gmail.com> 2009-03-29 21:29:53 --- Still present in git. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 Austin English <austinenglish(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|get_ptrace_tid defined but |get_ptrace_tid defined but |not used on OpenBSD |not used on OpenBSD/NetBSD --- Comment #3 from Austin English <austinenglish(a)gmail.com> 2009-04-23 01:52:48 --- Also affects NetBSD 5.0. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #4 from Austin English <austinenglish(a)gmail.com> 2009-05-28 22:10:19 --- Still present. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #5 from Austin English <austinenglish(a)gmail.com> 2010-02-27 17:58:56 --- Still present. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #6 from Wolfram Sang <wolfram(a)the-dreams.de> 2010-03-20 01:53:17 --- Created an attachment (id=26901) --> (http://bugs.winehq.org/attachment.cgi?id=26901) Patch replacing signal numbers with names in config.guess Also sent upstream, should then flow back to wine. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 Wolfram Sang <wolfram(a)the-dreams.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #26901|0 |1 is obsolete| | --- Comment #7 from Wolfram Sang <wolfram(a)the-dreams.de> 2010-03-20 01:54:33 --- (From update of attachment 26901) ??? How did I get to this Patch number. Sorry for the noise! Obsoleting. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 Austin English <austinenglish(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|get_ptrace_tid defined but |get_ptrace_tid defined but |not used on OpenBSD/NetBSD |not used on GNU | |Hurd/OpenBSD/NetBSD --- Comment #8 from Austin English <austinenglish(a)gmail.com> 2011-04-10 15:53:06 CDT --- Also affects GNU Hurd. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #9 from Austin English <austinenglish(a)gmail.com> 2013-01-25 20:37:16 CST --- Still in wine-1.5.22-158-g236b4da -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=16734 André H. <nerv(a)dawncrow.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nerv(a)dawncrow.de --- Comment #10 from André H. <nerv(a)dawncrow.de> --- (In reply to Austin English from comment #0)
ccache gcc -c -I. -I. -I../include -I../include -D__WINESRC__ -Wall -pipe -fno-strict-aliasing -Wwrite-strings -Wpointer-arith -I/usr/local/include -g -O2 -o ptrace.o ptrace.c ptrace.c:174: warning: `get_ptrace_tid' defined but not used
There's an '#ifdef linux' on the same code a few lines earlier (in get_ptrace_tid), which fixes compile here as well:
diff --git a/server/ptrace.c b/server/ptrace.c index b446de9..92b7db5 100644 --- a/server/ptrace.c +++ b/server/ptrace.c @@ -172,7 +172,9 @@ static int get_ptrace_pid( struct thread *thread ) /* return the Unix tid to use in ptrace calls for a given thread */ static int get_ptrace_tid( struct thread *thread ) { +#ifdef linux if (thread->unix_tid != -1) return thread->unix_tid; +#endif return thread->unix_pid; }
but I'm not sure if that's right or not. Comments welcome.
sorry, this is wrong, and i don't know how this would remove the warning. Checking for the complicated cases when it's used is also a bad idea. so i suggest: https://source.winehq.org/patches/data/107662 -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #11 from Austin English <austinenglish(a)gmail.com> --- (In reply to André H. from comment #10)
Checking for the complicated cases when it's used is also a bad idea. so i suggest: https://source.winehq.org/patches/data/107662
That gets rid of the warning on OpenBSD. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=16734 --- Comment #12 from Austin English <austinenglish(a)gmail.com> --- Still present in wine-9.19. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (2)
-
wine-bugs@winehq.org -
WineHQ Bugzilla