ports/56222: [patch] Fix compiler error in www/php-screw
Kang Liu
liukang at bjpu.edu.cn
Sun Aug 31 04:00:32 UTC 2003
>Number: 56222
>Category: ports
>Synopsis: [patch] Fix compiler error in www/php-screw
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Sat Aug 30 21:00:30 PDT 2003
>Closed-Date:
>Last-Modified:
>Originator: Kang Liu
>Release: FreeBSD 5.1-CURRENT i386
>Organization:
Beijing University of Technology
>Environment:
System: FreeBSD 5.1-CURRENT i386
>Description:
php-screw is not C99 compatible: the author use "exit()" while C99 forbid.
>How-To-Repeat:
Run make in ${PORTSDIR}/www/php-screw on a 5.1-current machine.
(bento)
>Fix:
diff -ruN php-screw.orig/Makefile php-screw/Makefile
--- php-screw.orig/Makefile Sat Jun 7 03:04:58 2003
+++ php-screw/Makefile Sun Aug 31 01:07:19 2003
@@ -7,6 +7,7 @@
PORTNAME= php-screw
PORTVERSION= 1.2.1
+PORTREVISION= 1
CATEGORIES= www security
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= ${PORTNAME}
diff -ruN php-screw.orig/files/patch-tools::screw.c php-screw/files/patch-tools::screw.c
--- php-screw.orig/files/patch-tools::screw.c Thu Jan 1 08:00:00 1970
+++ php-screw/files/patch-tools::screw.c Sun Aug 31 00:57:47 2003
@@ -0,0 +1,42 @@
+--- tools/screw.c.orig Sun Aug 31 00:55:45 2003
++++ tools/screw.c Sun Aug 31 00:56:14 2003
+@@ -18,12 +18,12 @@
+
+ if (argc != 2) {
+ fprintf(stderr, "Usage: filename.\n");
+- exit();
++ exit(1);
+ }
+ fp = fopen(argv[1], "r");
+ if (fp == NULL) {
+ fprintf(stderr, "File not found(%s)\n", argv[1]);
+- exit();
++ exit(1);
+ }
+
+ fstat(fileno(fp), &stat_buf);
+@@ -36,13 +36,13 @@
+
+ if (memcmp(datap, PM9SCREW, PM9SCREW_LEN) == 0) {
+ fprintf(stderr, "Already Crypted(%s)\n", argv[1]);
+- exit();
++ exit(1);
+ }
+
+ fp = fopen(oldfilename, "w");
+ if (fp == NULL) {
+ fprintf(stderr, "Can not create backup file(%s)\n", oldfilename);
+- exit();
++ exit(1);
+ }
+ fwrite(datap, datalen, 1, fp);
+ fclose(fp);
+@@ -56,7 +56,7 @@
+ fp = fopen(argv[1], "w");
+ if (fp == NULL) {
+ fprintf(stderr, "Can not create crypt file(%s)\n", oldfilename);
+- exit();
++ exit(1);
+ }
+ fwrite(PM9SCREW, PM9SCREW_LEN, 1, fp);
+ fwrite(newdatap, newdatalen, 1, fp);
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list