From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 42644 invoked by alias); 3 Aug 2018 18:14:20 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 42635 invoked by uid 89); 3 Aug 2018 18:14:20 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-3.2 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=H*R:U*cygwin, sk:newlib, Hx-spam-relays-external:ESMTPA, metal X-HELO: out1-smtp.messagingengine.com Received: from out1-smtp.messagingengine.com (HELO out1-smtp.messagingengine.com) (66.111.4.25) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 03 Aug 2018 18:14:18 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 9BE9321DFB; Fri, 3 Aug 2018 14:14:15 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Fri, 03 Aug 2018 14:14:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :reply-to:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; bh=ltOXowsNPcTq6cVfJhKqJspomfmRLk3ou/K+ZTVk63A=; b=ehml8AHMD2Lx /cmUO/0OoXxvoKgaKhFJD8SflqhCitW44/WGl8zitXP51cc/SeBA8b85jwRnALMV 1hZim7fV93tjn5WHmVuMnL56FXymlTBj+EKE2fBH0+8hIaJkXLN7qjIhs6fdfo9T 0JEynf6ZM7xochkjwCNdaQ71f+st/EOLJidfcRZ7IyiLGtHJ6l25sZ7w3m1djcMh 0EysqCuOkHfIVWUFC74uOvbHzld7psXhPcXSb1HPB48uo8CPBKxUeOs2M9FAEvDG Mfh1RrOyAzM3NKw1cx1hk0WnOhttIJzcbSiUvErIgd8bS94vBdSsi2AI/mo3Q1WU grjZfZ50ug== Received: from [192.168.1.102] (host86-151-121-200.range86-151.btcentralplus.com [86.151.121.200]) by mail.messagingengine.com (Postfix) with ESMTPA id DEA6DE4636; Fri, 3 Aug 2018 14:14:14 -0400 (EDT) Subject: Re: Self-compiled xorg-server 1.20.0 crashes at startup, buffer overflow To: tumtum00 References: <3bFLcaKIbW2ReAFfPR_VyPdeLOkhOtZMYWF_LXmhPBuysKqgz4kVUVRqtnu4RsPrGGfgMJSQzeFdAj3HMJgqWzDunzDSdF5kuycnE42YA08=@protonmail.com> Cc: The Cygwin Mailing List Reply-To: The Cygwin Mailing List From: Jon Turney Message-ID: Date: Fri, 03 Aug 2018 18:14:00 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <3bFLcaKIbW2ReAFfPR_VyPdeLOkhOtZMYWF_LXmhPBuysKqgz4kVUVRqtnu4RsPrGGfgMJSQzeFdAj3HMJgqWzDunzDSdF5kuycnE42YA08=@protonmail.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2018-08/txt/msg00038.txt.bz2 On 03/08/2018 18:19, tumtum00 wrote: > On 31 July 2018 7:57 PM, Jon Turney wrote: > > I tried 3 new machines today, can reproduce the issue in all of them. All were Win7 x86_64. 2 VMs installed from scratch (one in English, the other German as in my first report) plus a system running on bare metal. > >>> #7 0x000000018017e7e9 in __chk_fail () at /usr/src/debug/cygwin-2.10.0-1/newlib/libc/ssp/chk_fail.c:11 >>> msg = "*** buffer overflow detected ***: terminated\n" >>> #8 0x000000018018c1c3 in __memcpy_chk (dst=0x60008e570, src=0x45, len=0, slen=0) at /usr/src/debug/cygwin-2.10.0-1/newlib/libc/ssp/memcpy_chk.c:48 >> >> This is a wrapper around memcpy, which is being used as we are building >> with _FORTIFY_SOURCE >> >> I'd suggest setting a breakpoint on this line (after installing the >> cygwin-debuginfo package for relevant debug info) and trying to >> understand why it's not succeeding. > > Attached the backtrace at memcpy_chk.c:48. > I've been trying to figure out what is going on from the source code, but I'm not really getting anywhere. > > Does it suffice to install cygwin-debuginfo or do I need to set something up? > I ran gdb with `set cygwin-exceptions on` too, but no further information came up in the backtrace. > Thread 1 hit Breakpoint 1, __memcpy_chk (dst=0x60008c7a0, src=0x10059f4b0 , len=8, slen=4) > at /usr/src/debug/cygwin-2.10.0-1/newlib/libc/ssp/memcpy_chk.c:48 > 48 /usr/src/debug/cygwin-2.10.0-1/newlib/libc/ssp/memcpy_chk.c: No such file or directory. > #0 __memcpy_chk (dst=0x60008c7a0, src=0x10059f4b0 , len=8, slen=4) The "no such file or directory" doesn't make much sense to me. That file should be provided by cygwin-debuginfo package. Anyhow, I think to fix this, you need a cygwin with the following changes (the latest snapshot should be ok) https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;a=commitdiff;h=4564b30f331a067e71b25308ac7c8a85ceb4b122;hp=4d1a356f7b36905f5e2b616513b111ef042f1a43 https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;a=commitdiff;h=e494b560350cabef94126a4478096aae89ae35a0 Sorry for not working this out sooner, but I'd convinced myself that these changes are in the current cygwin-devel package, when in fact they aren't. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple