NetBSD Problem Report #52248

From mlr@cterm.rse.com  Sat May 20 20:04:58 2017
Return-Path: <mlr@cterm.rse.com>
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 E138E7A200
	for <gnats-bugs@gnats.NetBSD.org>; Sat, 20 May 2017 20:04:58 +0000 (UTC)
Message-Id: <20170520185031.4BFB111AD80@cterm.rse.com>
Date: Sat, 20 May 2017 14:50:31 -0400 (EDT)
From: mlr@rse.com
Reply-To: mlr@rse.com
To: gnats-bugs@NetBSD.org
Subject: xrolodex core dumps on amd64 (64 bit) machines
X-Send-Pr-Version: 3.95

>Number:         52248
>Category:       pkg
>Synopsis:       xrolodex core dumps on amd64 (64 bit) machines.
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat May 20 20:05:00 +0000 2017
>Closed-Date:    Sun Apr 29 04:41:45 +0000 2018
>Last-Modified:  Sun Apr 29 04:41:45 +0000 2018
>Originator:     Michael L. Riechers
>Release:        NetBSD 7.1_RC2
>Organization:
Kind Regards, I am

 /s/ Michael L. Riechers

Michael L. Riechers,
Owner,					M L Riechers Systems Engineering
513/844-2220 (voice)			530 Main Street
513/205-5589 (cell)			Hamilton, Ohio 45013
513/844-2279 (fax)
mlr@rse.com  (internet)
www.rse.com  (WEB)

Systems Programming: The three most adverse malignancies in life are:
  1)signed numbers,  2)floating point numbers, and  3)little endians.

Adams wrote to his fellow founding father Thomas Jefferson in 1816:
"Britain will never be our Friend, till We are her Master"
So I propose:
"MicroSoft will never be our Friend, till We are her Master"
>Environment:


System: NetBSD cterm.rse.com 7.1_RC2 NetBSD 7.1_RC2 (HOUSE-7.1_RC2) #0: Sun Feb 26 11:56:07 EST 2017 root@cterm.rse.com:/usr/local/src/usr/usr.201702210824Z/src/sys/arch/amd64/compile/obj/HOUSE-7.1_RC2 amd64
Architecture: x86_64
Machine: amd64
>Description:
xrolodex core dumps on amd64 (64 bit) machines.

>How-To-Repeat:

1. Compile xrolodex.
2. Start xrolodex.
3. xrolodex immediately core dumps.
>Fix:

add into xrolo.h:
38a39
#include <Xm/FileSB.h>

this wipes out xrolodex's confusion regarding 32 vs 64 bit references.

it does not, however, get rid of these confusions:

xrolo.c: In function 'FileSelectionOK':
xrolo.c:1035:6: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  if ((int) client_data == xrolo_OPEN)
      ^
xrolo.c:1037:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  else if ((int) client_data == xrolo_SAVE_AS) {
           ^
xrolo.c: In function 'SaveUnsavedChanges':
xrolo.c:1085:6: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  if ((int) client_data == xrolo_EXIT_WARNING) {
      ^
xrolo.c:1089:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  else if ((int) client_data == xrolo_OPEN_WARNING) {
           ^
xrolo.c: In function 'DiscardUnsavedChanges':
xrolo.c:1114:6: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  if ((int) client_data == xrolo_EXIT_WARNING) {
      ^
xrolo.c:1118:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  else if ((int) client_data == xrolo_OPEN_WARNING) {
           ^
xrolo.c: In function 'CancelUnsavedChanges':
xrolo.c:1143:6: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  if ((int) client_data == xrolo_EXIT_WARNING)
      ^
xrolo.c:1145:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  else if ((int) client_data == xrolo_OPEN_WARNING)
           ^
xrolo.c: In function 'Sort':
xrolo.c:1479:16: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  temp_entry = ((int) client_data == xrolo_ASCEND) ?
                ^ 

I don't know if these matter, especially on other architectures.  It
doesn't seem to bother me.

Yours,

-Mike

>Release-Note:

>Audit-Trail:
From: "David A. Holland" <dholland@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/52248 CVS commit: pkgsrc/misc/xrolodex
Date: Sun, 29 Apr 2018 03:56:08 +0000

 Module Name:	pkgsrc
 Committed By:	dholland
 Date:		Sun Apr 29 03:56:08 UTC 2018

 Modified Files:
 	pkgsrc/misc/xrolodex: PLIST distinfo
 	pkgsrc/misc/xrolodex/patches: patch-aa
 Added Files:
 	pkgsrc/misc/xrolodex/patches: patch-editor.c patch-xrolo.h

 Log Message:
 PR 52248 Michael L. Riechers: xrolodex dumps core on 64-bit machines
 While here, fix some pkglint.


 To generate a diff of this commit:
 cvs rdiff -u -r1.3 -r1.4 pkgsrc/misc/xrolodex/PLIST
 cvs rdiff -u -r1.5 -r1.6 pkgsrc/misc/xrolodex/distinfo
 cvs rdiff -u -r1.1 -r1.2 pkgsrc/misc/xrolodex/patches/patch-aa
 cvs rdiff -u -r0 -r1.1 pkgsrc/misc/xrolodex/patches/patch-editor.c \
     pkgsrc/misc/xrolodex/patches/patch-xrolo.h

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

From: David Holland <dholland-pbugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/52248: xrolodex core dumps on amd64 (64 bit) machines
Date: Sun, 29 Apr 2018 03:58:13 +0000

 On Sat, May 20, 2017 at 08:05:00PM +0000, mlr@rse.com wrote:
  > it does not, however, get rid of these confusions:
  > 
  > xrolo.c: In function 'FileSelectionOK':
  > xrolo.c:1035:6: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
  >   if ((int) client_data == xrolo_OPEN)
  >       ^

 These are probably ok; it's passing integer codes through a
 "client_data" argument, which is a pointer.

 One can silence the warnings by using intptr_t instead of int, but
 it's probably not worth bothering.

 -- 
 David A. Holland
 dholland@netbsd.org

State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sun, 29 Apr 2018 04:41:45 +0000
State-Changed-Why:
committed, thanks


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.