Add patches for politically correct syntax, silencing warnings.
PR: 249017 Submitted by: freebsd@dreamchaser.org Reported by: freebsd@dreamchaser.org
This commit is contained in:
parent
b2eb1dc48c
commit
7d816e6185
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=547150
@ -4,12 +4,12 @@
|
||||
PORTNAME= xtset
|
||||
PORTVERSION= 1.1
|
||||
CATEGORIES= x11
|
||||
MASTER_SITES= ftp://ftp.lemis.com/pub/
|
||||
MASTER_SITES= http://www.lemis.com/pub/
|
||||
|
||||
MAINTAINER= grog@FreeBSD.org
|
||||
COMMENT= Utility to set title on an xterm
|
||||
|
||||
LICENSE= NONE
|
||||
# LICENSE= NONE
|
||||
|
||||
NO_WRKSUBDIR= yes
|
||||
|
||||
|
@ -1,2 +1,3 @@
|
||||
TIMESTAMP = 1598851253
|
||||
SHA256 (xtset-1.1.tar.gz) = e507a3e31a693419fd0a760b392f6370299cdaba37c419b09f165771ae73ba5d
|
||||
SIZE (xtset-1.1.tar.gz) = 4310
|
||||
|
44
x11/xtset/files/patch-xtset.c
Normal file
44
x11/xtset/files/patch-xtset.c
Normal file
@ -0,0 +1,44 @@
|
||||
--- xtset.c.orig 2002-03-29 22:15:00.000000000 +1100
|
||||
+++ xtset.c 2020-08-31 15:29:45.583899000 +1000
|
||||
@@ -49,6 +49,7 @@
|
||||
#include <pwd.h>
|
||||
#include <grp.h>
|
||||
#include <sys/param.h>
|
||||
+#include <sys/stat.h>
|
||||
|
||||
/* SVR3 header files frequently don't define MAXPATHLEN. They probably can't
|
||||
* stomach a 1K path name, either, but this constant can err on the generous
|
||||
@@ -135,21 +136,21 @@
|
||||
|
||||
/* then the effective username */
|
||||
|
||||
- if (pwent = getpwuid (geteuid ()))
|
||||
+ if ((pwent = getpwuid (geteuid ())) != 0)
|
||||
eff_userid = strdup (pwent->pw_name);
|
||||
else
|
||||
eff_userid = "*no euid*";
|
||||
|
||||
/* then the real groupname */
|
||||
|
||||
- if (grent = getgrgid (getgid ()))
|
||||
+ if ((grent = getgrgid (getgid ())) != 0)
|
||||
real_groupid = strdup (grent->gr_name);
|
||||
else
|
||||
real_groupid = "*no gid*"; /* yes, this can be valid */
|
||||
|
||||
/* then the effective groupname */
|
||||
|
||||
- if (grent = getgrgid (getegid ()))
|
||||
+ if ((grent = getgrgid (getegid ())) != 0)
|
||||
eff_groupid = strdup (grent->gr_name);
|
||||
else
|
||||
eff_groupid = "*no egid*"; /* yes, this can be valid */
|
||||
@@ -163,7 +164,7 @@
|
||||
{
|
||||
char *point;
|
||||
strcpy (short_host, our_host);
|
||||
- if (point = strchr (short_host, '.')) /* got a point, */
|
||||
+ if ((point = strchr (short_host, '.')) != 0) /* got a point, */
|
||||
*point = '\0'; /* chop it off there */
|
||||
}
|
||||
if ( !getcwd (our_dir, MAXPATHLEN)) /* or can't get wd */
|
Loading…
Reference in New Issue
Block a user