Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 May 2000 08:15:23 +0200 (CEST)
From:      lkoeller@cc.fh-lippe.de
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/18643: tclock additional patch avoids segfaults.
Message-ID:  <200005180615.IAA85841@odie.lippe.de>

next in thread | raw e-mail | index | archive | help

>Number:         18643
>Category:       ports
>Synopsis:       tclock additional patch avoids segfaults.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Thu May 18 00:10:01 PDT 2000
>Closed-Date:
>Last-Modified:
>Originator:     Lars Koeller
>Release:        FreeBSD 3.4-RELEASE i386
>Organization:
Fachhochschule Lippe, Lemgo, Germany
>Environment:

	FreeBSD-3.4 with ports up to date.

>Description:

	In some special cases tclock segfaults after startup. This is due
	to special cases with the merging of X11 resources.

>How-To-Repeat:

	-

>Fix:

	The appended patch avoids this problem! Simple place it as patch-ab
	int the ports patch-dir.


Regards

Lars

--
E-Mail:                                     |  Lars Koeller
  Lars.Koeller@Uni-Bielefeld.DE              |  UNIX Sysadmin
  lkoeller@cc.fh-lippe.de                     |  Computing Center
PGP-key:                                       |  University of Bielefeld
  http://www.pgp.net/pgpnet/www-key.html        |  Germany
----------- FreeBSD, what else? ---- http://www.freebsd.org -------------


------------------------- patch-ab for tclock ---------------------------

diff -u ../../tclock.old/work/tclock.c ./tclock.c
--- ../../tclock.old/work/tclock.c	Mon May 15 13:07:35 2000
+++ ./tclock.c	Mon May 15 13:18:02 2000
@@ -312,6 +312,7 @@
   extern
   char		*getenv();
   char		*displayName, fn[1000];
+  char		*sdb;
   int		parseReturn, rc;

   XrmParseCommand(&db, option, numOptions, "tclock", &ac, av);
@@ -344,7 +345,8 @@
     exit(1);

   db = XrmGetStringDatabase(tclockDefaults);
-  XrmMergeDatabases(XrmGetStringDatabase(XResourceManagerString(display)), &db);
+  if(sdb = XResourceManagerString(display))
+    XrmMergeDatabases(XrmGetStringDatabase(sdb), &db);

   sprintf(fn, "%s/.Xdefaults", getenv("HOME"));
   if(access(fn, R_OK) == 0)

--------------------------------------------------------------------------

>Release-Note:
>Audit-Trail:
>Unformatted:


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200005180615.IAA85841>