NetBSD Problem Report #50742

From www@NetBSD.org  Mon Feb  1 19:37:29 2016
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.NetBSD.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.netbsd.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 89F157A20F
	for <gnats-bugs@gnats.NetBSD.org>; Mon,  1 Feb 2016 19:37:29 +0000 (UTC)
Message-Id: <20160201193728.1C7267ACA7@mollari.NetBSD.org>
Date: Mon,  1 Feb 2016 19:37:28 +0000 (UTC)
From: joseyluis@gmail.com
Reply-To: joseyluis@gmail.com
To: gnats-bugs@NetBSD.org
Subject: wine gives the error: wine: Unhandled page fault on read access to 0x0069004c at address 0x0017:0x7f1d20c0 (thread 0021), starting debugger...
X-Send-Pr-Version: www-1.0

>Number:         50742
>Category:       port-i386
>Synopsis:       wine gives the error: wine: Unhandled page fault on read access to 0x0069004c at address 0x0017:0x7f1d20c0 (thread 0021), starting debugger...
>Confidential:   no
>Severity:       critical
>Priority:       low
>Responsible:    port-i386-maintainer
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Feb 01 19:40:00 +0000 2016
>Closed-Date:    Sat May 23 22:47:10 +0000 2020
>Last-Modified:  Sat May 23 22:47:10 +0000 2020
>Originator:     Jose Luis Rodriguez Garcia
>Release:        NetBSD pc1 6.1.5 NetBSD 6.1.5 (GENERIC) i386
>Organization:
>Environment:
NetBSD pc1 6.1.5 NetBSD 6.1.5 (GENERIC) i386

>Description:
When trying to execute several programs of windows using Wine/winetricks, I obtain the next error: "wine gives the error: wine: Unhandled page fault on read access to ". The address changes with every program.

The error of this is trying to install Explorer 8 with winetricks and crypt32:


./winetricks ie8 crypt32

It is NetBSD 6.1.5 i386 / wine 1.6.2

I don't know if this is due a bug in NetBSD or in wine. It will be useful some guidance about this.

Unhandled exception: page fault on read access to 0x00000000 in 32-bit code (0x7f1d20c0).
Register dump:
 CS:0017 SS:001f DS:001f ES:001f FS:1007 GS:00b3
 EIP:7f1d20c0 ESP:0033ba38 EBP:0033ba50 EFLAGS:00010246(  R- --  I  Z- -P- )
 EAX:00000000 EBX:7f1f4264 ECX:0012d150 EDX:0012d144
 ESI:00000000 EDI:0012d144
Stack dump:
0x0033ba38:  00000014 7ffc398c 0012d13c 7f1f4264
0x0033ba48:  0012d130 0012d130 0033ba98 7f1d457a
0x0033ba58:  0012d130 0101aab0 00000014 01000009
0x0033ba68:  7ffc398c 0033ba88 00000000 0033ba98
0x0033ba78:  7ff88360 0033babc 0033ba88 00000001
0x0033ba88:  00150014 7f1f4264 0033babc 00000000
0200: sel=1007 base=00ff8000 limit=00000fff 32-bit rw-
Backtrace:
=>0 0x7f1d20c0 in setupapi (+0x220c0) (0x0033ba50)
  1 0x7f1d457a SetupFindFirstLineW+0x2c() in setupapi (0x0033ba98)
  2 0x7f1d47ea SetupFindFirstLineA+0xe4() in setupapi (0x0033bad0)
  3 0x0107435f in update (+0x7435e) (0x0033bc54)
  4 0x0105c375 in update (+0x5c374) (0x0033f2f4)
  5 0x0104aa75 in update (+0x4aa74) (0x0033fe64)
  6 0x0106c0ac in update (+0x6c0ab) (0x0033ff08)
  7 0x7fd22a5c call_process_entry+0xb() in kernel32 (0x0033ff20)
  8 0x7fd23b7f in kernel32 (+0x43b7e) (0x0033ff48)
  9 0x7ff90dd8 call_thread_func_wrapper+0xb() in ntdll (0x0033ff58)
  10 0x7ff92dd8 call_thread_func+0x6e() in ntdll (0x0033ffb8)
  11 0x7ff90db6 RtlRaiseException+0x21() in ntdll (0x0033ffd8)
  12 0x7ff6b4bc call_dll_entry_point+0x55b() in ntdll (0x0033ffe8)
  13 0xbba3b77d wine_call_on_stack+0x1c() in libwine.so.1 (0x00000000)
  14 0xbba3b82c wine_switch_to_stack+0x2b() in libwine.so.1 (0xbfbfd4b0)
  15 0x7ff70871 LdrInitializeThunk+0x2d1() in ntdll (0xbfbfd4f8)
  16 0x7fd29744 __wine_kernel_init+0x8cb() in kernel32 (0xbfbfe694)
  17 0x7ff71030 __wine_process_init+0x252() in ntdll (0xbfbfe6fc)
  18 0xbba39372 wine_init+0x275() in libwine.so.1 (0xbfbfe740)
  19 0x7bf00d74 main+0x73() in <wine-loader> (0xbfbfeb64)
  20 0x7bf00c05 __start+0x134() in <wine-loader> (0xbfbfeb8c)
0x7f1d20c0: movl	0x0(%eax),%eax
Modules:
Module	Address			Debug info	Name (88 modules)
PE	  490000-  49f000	Deferred        iecustom
PE	 1000000- 1134000	Export          update
ELF	7bf00000-7bf02000	Dwarf           <wine-loader>
ELF	7e7c4000-7e800000	Deferred        rsaenh<elf>
  \-PE	7e7d0000-7e800000	\               rsaenh
ELF	7ec59000-7ec70000	Deferred        clusapi<elf>
  \-PE	7ec60000-7ec70000	\               clusapi
ELF	7ec70000-7ec89000	Deferred        sxs<elf>
  \-PE	7ec80000-7ec89000	\               sxs
ELF	7ec89000-7ec9c000	Deferred        newdev<elf>
  \-PE	7ec90000-7ec9c000	\               newdev
ELF	7ec9c000-7eccd000	Deferred        wintrust<elf>
  \-PE	7eca0000-7eccd000	\               wintrust
ELF	7eccd000-7ed00000	Deferred        uxtheme<elf>
  \-PE	7ecd0000-7ed00000	\               uxtheme
ELF	7ee09000-7ee28000	Deferred        cabinet<elf>
  \-PE	7ee10000-7ee28000	\               cabinet
ELF	7ee28000-7ee62000	Deferred        winspool<elf>
  \-PE	7ee30000-7ee62000	\               winspool
ELF	7ee64000-7ee6d000	Deferred        libxcursor.so.2
ELF	7ee6d000-7ee73000	Deferred        xlibi18n.so.2
ELF	7ee73000-7ee80000	Deferred        libxi.so.7
ELF	7ee80000-7ee83000	Deferred        libxcomposite.so.2
ELF	7ee83000-7ee8a000	Deferred        libxrandr.so.3
ELF	7ee8a000-7ee92000	Deferred        libxrender.so.2
ELF	7ee92000-7ee97000	Deferred        libxxf86vm.so.2
ELF	7ee97000-7ee9a000	Deferred        libxinerama.so.2
ELF	7eea3000-7eea6000	Deferred        libxau.so.7
ELF	7eea6000-7eeab000	Deferred        libxdmcp.so.7
ELF	7eeab000-7eec2000	Deferred        libxcb.so.1
ELF	7eec2000-7efb1000	Deferred        libx11.so.7
ELF	7efb1000-7efbf000	Deferred        libxext.so.7
ELF	7efbf000-7f046000	Deferred        winex11<elf>
  \-PE	7efd0000-7f046000	\               winex11
ELF	7f0c9000-7f0eb000	Deferred        libexpat.so.2
ELF	7f0eb000-7f11d000	Deferred        libfontconfig.so.1
ELF	7f11d000-7f12d000	Deferred        libbz2.so.1
ELF	7f12d000-7f1a0000	Deferred        libfreetype.so.7
ELF	7f1a0000-7f206000	Dwarf           setupapi<elf>
  \-PE	7f1b0000-7f206000	\               setupapi
ELF	7f206000-7f21a000	Deferred        updspapi<elf>
  \-PE	7f210000-7f21a000	\               updspapi
ELF	7f21a000-7f282000	Deferred        shlwapi<elf>
  \-PE	7f230000-7f282000	\               shlwapi
ELF	7f282000-7f493000	Deferred        shell32<elf>
  \-PE	7f290000-7f493000	\               shell32
ELF	7f493000-7f598000	Deferred        oleaut32<elf>
  \-PE	7f4b0000-7f598000	\               oleaut32
ELF	7f598000-7f60b000	Deferred        rpcrt4<elf>
  \-PE	7f5a0000-7f60b000	\               rpcrt4
ELF	7f60b000-7f70a000	Deferred        ole32<elf>
  \-PE	7f620000-7f70a000	\               ole32
ELF	7f70a000-7f79f000	Deferred        msvcrt<elf>
  \-PE	7f720000-7f79f000	\               msvcrt
ELF	7f79f000-7f7c4000	Deferred        mpr<elf>
  \-PE	7f7b0000-7f7c4000	\               mpr
ELF	7f7c4000-7f7d7000	Deferred        psapi<elf>
  \-PE	7f7d0000-7f7d7000	\               psapi
ELF	7f7e0000-7f7f2000	Deferred        libz.so.1
ELF	7f7f2000-7f84f000	Deferred        dbghelp<elf>
  \-PE	7f800000-7f84f000	\               dbghelp
ELF	7f84f000-7f868000	Deferred        imagehlp<elf>
  \-PE	7f850000-7f868000	\               imagehlp
ELF	7f868000-7f922000	Deferred        crypt32<elf>
  \-PE	7f870000-7f922000	\               crypt32
ELF	7f922000-7f93a000	Deferred        version<elf>
  \-PE	7f930000-7f93a000	\               version
ELF	7f93a000-7fa3b000	Deferred        gdi32<elf>
  \-PE	7f950000-7fa3b000	\               gdi32
ELF	7fa3b000-7fb76000	Deferred        user32<elf>
  \-PE	7fa50000-7fb76000	\               user32
ELF	7fb76000-7fc6b000	Deferred        comctl32<elf>
  \-PE	7fb80000-7fc6b000	\               comctl32
ELF	7fc6b000-7fcca000	Deferred        advapi32<elf>
  \-PE	7fc80000-7fcca000	\               advapi32
ELF	7fcca000-7ff08000	Dwarf           kernel32<elf>
  \-PE	7fce0000-7ff08000	\               kernel32
ELF	7ff08000-7ff25000	Deferred        libm.so.0
ELF	7ff25000-7ffe0000	Dwarf           ntdll<elf>
  \-PE	7ff40000-7ffe0000	\               ntdll
ELF	bb8e7000-bb8e9000	Deferred        libm387.so.0
ELF	bb902000-bb904000	Deferred        libi386.so.1
ELF	bb904000-bb907000	Deferred        libossaudio.so.1
ELF	bb907000-bb913000	Deferred        libgcc_s.so.1
ELF	bb913000-bba24000	Deferred        libc.so.12
ELF	bba24000-bba33000	Deferred        libpthread.so.1
ELF	bba33000-bbbe5000	Dwarf           libwine.so.1
PE	bbbee000-bbc00000	Deferred        ld.elf_so
Threads:
process  tid      prio (all id:s are in hex)
0000000c services.exe
	00000028    0
	0000002f    0
	0000000e    0
	0000000d    0
0000002d winedevice.exe
	00000032    0
	00000031    0
	0000002e    0
0000003b explorer.exe
	0000003d    0
	0000003c    0
00000044 IE8-WindowsXP-x86-ENU.exe
	00000046    0
	00000045    0
00000047 iesetup.exe
	0000001c    0
	00000015    0
0000001b (D) C:\c052afe826cae61754\update\update.exe
	00000026    0
	00000027    0 <==
System information:
    Wine build: wine-1.6.2
    Platform: i386
    Host system: NetBSD
    Host version: 6.1.5

>How-To-Repeat:
export WINEPREFIX=/home/jose/.wine_stable_ie8
export WINEARCH=win32
export http_proxy=http://localhost:8080/
export https_proxy=http://localhost:8080/
rm -rf .wine_stable_ie8
./winetricks ie8 crypt32


diff -u winetricks.orig winetricks
--- winetricks.orig     2016-01-30 09:14:28.000000000 +0100
+++ winetricks  2016-01-30 23:12:25.000000000 +0100
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/usr/pkg/bin/bash

 # Name of this version of winetricks (YYYYMMDD)
 # (This doesn't change often, use the sha1sum of the file when reporting problems)
@@ -536,7 +536,7 @@
         # Usa a subshell so if the user clicks 'Cancel',
         # the --auto-kill kills the subshell, not the current shell
         (
-            wget "$@" 2>&1 |
+            wget --no-check-certificate "$@" 2>&1 |
             winetricks_parse_wget_progress | \
             $WINETRICKS_GUI --progress --width 400 --title="$_W_file" --auto-kill --auto-close
         )
@@ -556,7 +556,7 @@
         fi
         return $err
         ;;
-    *) wget "$@" ;;
+    *) wget --no-check-certificate "$@" ;;
     esac
 }

>Fix:

>Release-Note:

>Audit-Trail:
From: Thomas Klausner <wiz@NetBSD.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: port-i386/50742: wine gives the error: wine: Unhandled page
 fault on read access to 0x0069004c at address 0x0017:0x7f1d20c0 (thread
 0021), starting debugger...
Date: Mon, 1 Feb 2016 20:45:29 +0100

 On Mon, Feb 01, 2016 at 07:40:00PM +0000, joseyluis@gmail.com wrote:
 > @@ -536,7 +536,7 @@
 >          # Usa a subshell so if the user clicks 'Cancel',
 >          # the --auto-kill kills the subshell, not the current shell
 >          (
 > -            wget "$@" 2>&1 |
 > +            wget --no-check-certificate "$@" 2>&1 |
 >              winetricks_parse_wget_progress | \
 >              $WINETRICKS_GUI --progress --width 400 --title="$_W_file" --auto-kill --auto-close
 >          )
 > @@ -556,7 +556,7 @@
 >          fi
 >          return $err
 >          ;;
 > -    *) wget "$@" ;;
 > +    *) wget --no-check-certificate "$@" ;;
 >      esac
 >  }
 > 

 To have wget find SSL certificates, install mozilla-rootcerts package
 and follow the MESSAGE you get when installing it.
  Thomas

State-Changed-From-To: open->analyzed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Fri, 22 May 2020 23:25:35 +0000
State-Changed-Why:
This was resolved by Naveen Narayanan as part of GSoC 2019. Since it isn't in pkgsrc proper, not closing yet.
Fix Unhandled page fault on write access owing to pthread_attr_setstack(3)
setting guard on NetBSD 8.0 and newer. This patch has been submitted to Wine
and can be removed to once upstreamed.

--- dlls/ntdll/thread.c.orig	2019-03-15 20:18:31.000000000 +0000
+++ dlls/ntdll/thread.c
@@ -526,6 +526,7 @@ NTSTATUS WINAPI RtlCreateUserThread( HAN
     pthread_attr_init( &attr );
     pthread_attr_setstack( &attr, teb->DeallocationStack,
                          (char *)teb->Tib.StackBase + extra_stack - (char *)teb->DeallocationStack );
+    pthread_attr_setguardsize(&attr, 0);
     pthread_attr_setscope( &attr, PTHREAD_SCOPE_SYSTEM ); /* force creating a kernel thread */
     interlocked_xchg_add( &nb_threads, 1 );
     if (pthread_create( &pthread_id, &attr, (void * (*)(void *))start_thread, info ))



State-Changed-From-To: analyzed->closed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Sat, 23 May 2020 22:47:10 +0000
State-Changed-Why:
Nia committed the package done by Naveen, so now it is in pkgsrc proper.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.46 2020/01/03 16:35:01 leot Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2020 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.