Skip site navigation (1)Skip section navigation (2)
Date:      Sun,  6 Aug 2006 14:00:21 +0400 (MSD)
From:      Stanislav Sedov <ssedov@mbsd.msk.ru>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        cy@FreeBSD.org
Subject:   ports/101459: [PATCH] misc/screen: fix overflow on 64-bit
Message-ID:  <20060806100021.1717D120CA@fonon.realnet>
Resent-Message-ID: <200608061010.k76AA9KV061448@freefall.freebsd.org>

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

>Number:         101459
>Category:       ports
>Synopsis:       [PATCH] misc/screen: fix overflow on 64-bit
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Aug 06 10:10:08 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Stanislav Sedov
>Release:        FreeBSD 7.0-CURRENT i386
>Organization:
MBSD labs, Inc.
>Environment:
System: FreeBSD fonon.realnet 7.0-CURRENT FreeBSD 7.0-CURRENT #1: Wed Aug  2 21:44:37 MSD
>Description:
- Fix overflow on 64-bit platforms (ut_time is int32_t and time_t is of platform-dependent length)
- Add missing includes to avoid warnings

The following files was added:
- files/patch-layer.c
- files/patch-screen.c
- files/patch-utmp.c

Copy of this message was sent to (cy@FreeBSD.org).

>How-To-Repeat:
>Fix:

--- screen-4.0.2_2.patch begins here ---
diff -ruN --exclude=CVS /usr/ports/misc/screen/Makefile /var/tmp/screen/Makefile
--- /usr/ports/misc/screen/Makefile	Mon Jul 19 11:21:17 2004
+++ /var/tmp/screen/Makefile	Sun Aug  6 13:45:15 2006
@@ -7,7 +7,7 @@
 
 PORTNAME=	screen
 PORTVERSION=	4.0.2
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	misc
 MASTER_SITES=	ftp://ftp.uni-erlangen.de/pub/utilities/screen/ \
 		${MASTER_SITE_GNU}
diff -ruN --exclude=CVS /usr/ports/misc/screen/files/patch-layer.c /var/tmp/screen/files/patch-layer.c
--- /usr/ports/misc/screen/files/patch-layer.c	Thu Jan  1 03:00:00 1970
+++ /var/tmp/screen/files/patch-layer.c	Sun Aug  6 13:55:10 2006
@@ -0,0 +1,10 @@
+--- layer.c.orig	Mon Sep  8 18:25:46 2003
++++ layer.c	Sun Aug  6 13:54:40 2006
+@@ -22,6 +22,7 @@
+  */
+ 
+ #include <sys/types.h>
++#include <string.h>
+ 
+ #include "config.h"
+ #include "screen.h"
diff -ruN --exclude=CVS /usr/ports/misc/screen/files/patch-screen.c /var/tmp/screen/files/patch-screen.c
--- /usr/ports/misc/screen/files/patch-screen.c	Thu Jan  1 03:00:00 1970
+++ /var/tmp/screen/files/patch-screen.c	Sun Aug  6 13:56:14 2006
@@ -0,0 +1,10 @@
+--- screen.c.orig	Sun Aug  6 13:55:39 2006
++++ screen.c	Sun Aug  6 13:56:00 2006
+@@ -32,6 +32,7 @@
+ 
+ #include <sys/types.h>
+ #include <ctype.h>
++#include <string.h>
+ 
+ #include <fcntl.h>
+ 
diff -ruN --exclude=CVS /usr/ports/misc/screen/files/patch-utmp.c /var/tmp/screen/files/patch-utmp.c
--- /usr/ports/misc/screen/files/patch-utmp.c	Thu Jan  1 03:00:00 1970
+++ /var/tmp/screen/files/patch-utmp.c	Sun Aug  6 13:49:17 2006
@@ -0,0 +1,11 @@
+--- utmp.c.orig	Sun Aug  6 13:48:54 2006
++++ utmp.c	Sun Aug  6 13:49:14 2006
+@@ -618,7 +618,7 @@
+ #endif /* sgi */
+   strncpy(u->ut_line, line, sizeof(u->ut_line));
+   u->ut_pid = pid;
+-  (void)time((time_t *)&u->ut_time);
++  u->ut_time = time(NULL);
+ }
+ 
+ static slot_t
--- screen-4.0.2_2.patch ends here ---

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



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