Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libpthread_dbg Fix pt_magic (part of pthread_t) read in ...
details: https://anonhg.NetBSD.org/src/rev/f5b84e984c6f
branches: trunk
changeset: 819142:f5b84e984c6f
user: kamil <kamil%NetBSD.org@localhost>
date: Sun Nov 20 02:27:56 2016 +0000
description:
Fix pt_magic (part of pthread_t) read in td_thr_info()
The pt_magic field is not the first one in the pthread_t structure.
After this fix, this code is confirmed to work and function td_thr_info()
is functional.
Sponsored by <The NetBSD Foundation>
diffstat:
lib/libpthread_dbg/pthread_dbg.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r ecc74608cab4 -r f5b84e984c6f lib/libpthread_dbg/pthread_dbg.c
--- a/lib/libpthread_dbg/pthread_dbg.c Sun Nov 20 00:19:55 2016 +0000
+++ b/lib/libpthread_dbg/pthread_dbg.c Sun Nov 20 02:27:56 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pthread_dbg.c,v 1.44 2016/01/23 14:02:21 christos Exp $ */
+/* $NetBSD: pthread_dbg.c,v 1.45 2016/11/20 02:27:56 kamil Exp $ */
/*-
* Copyright (c) 2002 Wasabi Systems, Inc.
@@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: pthread_dbg.c,v 1.44 2016/01/23 14:02:21 christos Exp $");
+__RCSID("$NetBSD: pthread_dbg.c,v 1.45 2016/11/20 02:27:56 kamil Exp $");
#define __EXPOSE_STACK 1
@@ -210,7 +210,7 @@
{
int tmp, val;
- val = READ(thread->proc, thread->addr, &tmp, sizeof(tmp));
+ val = READ(thread->proc, OFFSET(thread, pt_magic), &tmp, sizeof(tmp));
if (val != 0)
return val;
Home |
Main Index |
Thread Index |
Old Index