From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dan Nicolaescu Newsgroups: gmane.emacs.bugs Subject: bug#9910: valgrind warning in coding.c:coding_set_destination Date: Sun, 06 Nov 2011 23:28:38 -0500 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1320640163 27091 80.91.229.12 (7 Nov 2011 04:29:23 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 7 Nov 2011 04:29:23 +0000 (UTC) Cc: 9910-done@debbugs.gnu.org, 9912-done@debbugs.gnu.org, 9911-done@debbugs.gnu.org To: Kenichi Handa Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Nov 07 05:29:19 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RNGpi-0004hc-QF for geb-bug-gnu-emacs@m.gmane.org; Mon, 07 Nov 2011 05:29:18 +0100 Original-Received: from localhost ([::1]:43775 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RNGpi-000611-7Z for geb-bug-gnu-emacs@m.gmane.org; Sun, 06 Nov 2011 23:29:18 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:47506) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RNGpe-00060X-4K for bug-gnu-emacs@gnu.org; Sun, 06 Nov 2011 23:29:16 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RNGpc-0003UE-No for bug-gnu-emacs@gnu.org; Sun, 06 Nov 2011 23:29:14 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:54984) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RNGpc-0003U2-Kq for bug-gnu-emacs@gnu.org; Sun, 06 Nov 2011 23:29:12 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1RNGsL-0001Rx-S8 for bug-gnu-emacs@gnu.org; Sun, 06 Nov 2011 23:32:01 -0500 Resent-From: Dan Nicolaescu Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Mon, 07 Nov 2011 04:32:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 9910 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Mail-Followup-To: 9910@debbugs.gnu.org, dann@gnu.org Original-Received: via spool by 9910-done@debbugs.gnu.org id=D9910.13206402915524 (code D ref 9910); Mon, 07 Nov 2011 04:32:01 +0000 Original-Received: (at 9910-done) by debbugs.gnu.org; 7 Nov 2011 04:31:31 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RNGrr-0001R2-AX for submit@debbugs.gnu.org; Sun, 06 Nov 2011 23:31:31 -0500 Original-Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1RNGrp-0001Qp-BL; Sun, 06 Nov 2011 23:31:30 -0500 Original-Received: from dann by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1RNGp4-0008N2-6h; Sun, 06 Nov 2011 23:28:38 -0500 In-Reply-To: (Kenichi Handa's message of "Mon, 07 Nov 2011 11:38:35 +0900") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Sun, 06 Nov 2011 23:32:01 -0500 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:53640 Archived-At: Kenichi Handa writes: > In article , Dan Nicolaescu writes: > >> valgrind ./temacs > >> produces this warning: > >> ==30382== Conditional jump or move depends on uninitialised value(s) >> ==30382== at 0x499251: coding_set_destination (coding.c:1046) >> ==30382== by 0x4B477A: decode_coding (coding.c:7022) >> ==30382== by 0x4B7317: decode_coding_object (coding.c:7671) >> ==30382== by 0x63610F: Fcall_process (callproc.c:813) >> ==30382== by 0x5D6C07: Ffuncall (eval.c:2956) >> ==30382== by 0x5D5ECA: Fapply (eval.c:2479) >> ==30382== by 0x5D6C07: Ffuncall (eval.c:2956) >> ==30382== by 0x622C5B: exec_byte_code (bytecode.c:785) >> ==30382== by 0x5D77BA: funcall_lambda (eval.c:3205) >> ==30382== by 0x5D6F4C: Ffuncall (eval.c:3023) >> ==30382== by 0x622C5B: exec_byte_code (bytecode.c:785) >> ==30382== by 0x5D77BA: funcall_lambda (eval.c:3205) > >> This looks like setup_coding_system (or whatever else initializes struct >> coding_system) does not initialize the src_pos field. > > I fixed it. But as "valgrind ./temacs" segfaults in my > environment, I can't confirm the fix. Please check if the > fix is correct or not. Thank you very much! The fix looks good, the warning does not appear anymore. valgrind ./temacs also segfaults for me in 32 bit mode (i686), it works in 64 bit mode (x86_64).