From alex@vaio.alexdupre.com  Tue Sep  2 06:11:11 2003
Return-Path: <alex@vaio.alexdupre.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP
	id 311D716A4BF; Tue,  2 Sep 2003 06:11:11 -0700 (PDT)
Received: from relay.gufi.org (civetta.gufi.org [212.110.23.10])
	by mx1.FreeBSD.org (Postfix) with ESMTP
	id E769743FBF; Tue,  2 Sep 2003 06:11:09 -0700 (PDT)
	(envelope-from alex@vaio.alexdupre.com)
Received: from vaio.alexdupre.com (host245-49.pool8288.interbusiness.it [82.88.49.245])
	by relay.gufi.org (Postfix) with ESMTP
	id 3689020F4E; Tue,  2 Sep 2003 15:11:08 +0200 (CEST)
Received: from vaio.alexdupre.com (localhost [127.0.0.1])
	by vaio.alexdupre.com (8.12.9/8.12.9) with ESMTP id h82DAums003463;
	Tue, 2 Sep 2003 15:10:56 +0200 (CEST)
	(envelope-from alex@vaio.alexdupre.com)
Received: (from alex@localhost)
	by vaio.alexdupre.com (8.12.9/8.12.9/Submit) id h82DAuHB003462;
	Tue, 2 Sep 2003 15:10:56 +0200 (CEST)
Message-Id: <200309021310.h82DAuHB003462@vaio.alexdupre.com>
Date: Tue, 2 Sep 2003 15:10:56 +0200 (CEST)
From: Alex Dupre <sysadmin@alexdupre.com>
Reply-To: Alex Dupre <sysadmin@alexdupre.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc: roam@freebsd.org
Subject: [Update] Port: autorespond-2.0.x-conf-strcasestr.patch
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         56310
>Category:       ports
>Synopsis:       [Update] Port: autorespond-2.0.x-conf-strcasestr.patch
>Confidential:   no
>Severity:       critical
>Priority:       high
>Responsible:    freebsd-ports-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          update
>Submitter-Id:   current-users
>Arrival-Date:   Tue Sep 02 06:20:08 PDT 2003
>Closed-Date:    Tue Sep 02 06:51:21 PDT 2003
>Last-Modified:  Tue Sep 02 06:51:21 PDT 2003
>Originator:     Alex Dupre
>Release:        FreeBSD 4.8-ALEXDUPRE i386
>Organization:
>Environment:
System: FreeBSD 4.8-ALEXDUPRE i386
>Description:
Update the patch for the new release.
>How-To-Repeat:
>Fix:

--- autorespond-conf-strcasestr.diff begins here ---
--- autorespond-2.0.3-conf-strcasestr.patch	Thu Apr  3 16:58:26 2003
+++ autorespond-2.0.4-conf-strcasestr.patch	Tue Sep  2 14:58:38 2003
@@ -6,27 +6,18 @@
 diff -u -r1.1.1.1 -r1.2
 --- Makefile	3 Apr 2003 13:58:32 -0000	1.1.1.1
 +++ Makefile	3 Apr 2003 14:51:10 -0000	1.2
-@@ -2,20 +2,29 @@
- # bdameron@tscnet.com
- #
- 
--CC = gcc
- BIN = autorespond
--DEFS = -Wall
--LINKDEFS =
--LIBS = 
--OBJS = autorespond.o
- 
--INSTALL_DIR = /usr/local/bin
-+INSTALL_DIR = `head -1 conf-home`/bin
- INSTALL_BIN = autorespond
- INSTALL_UID = root
- INSTALL_GID = root
- 
--all:
--	$(CC) $(DEFS) -o autorespond autorespond.c
-+all:	$(BIN)
-+
+@@ -1,14 +1,19 @@
+-CC=gcc
+-OPTS=-O2
+-LIBS=
+-CFLAGS=-Wall -g
+-DESTDIR=
+-PREFIX=$(DESTDIR)/usr
+-
+ all: autorespond
+
+-autorespond: autorespond.c
+-	$(CC) $(OPTS) $(CFLAGS) $(LIBS) $< -o $@
 +autorespond:	load autorespond.o strcasestr.o
 +	./load autorespond strcasestr.o
 +
@@ -42,15 +33,12 @@
 +strcasestr.c:	choose compile trystrcase.c strcasestr_ar.c strcasestr_sys.c
 +	./choose cl trystrcase strcasestr_ar.c strcasestr_sys.c > strcasestr.c
  
- install: all
- 	@echo "Installing..."
-@@ -25,5 +34,28 @@
- 
- clean:
- 	@echo -n "Cleaning up..."
--	@rm -rf *.core core $(BIN)
-+	@rm -rf *.core core `cat TARGETS`
- 	@echo "done."
+ distclean: clean
+
+@@ -19,4 +24,27 @@
+ 	install -d $(PREFIX)/bin $(PREFIX)/share/man/man1
+ 	install autorespond $(PREFIX)/bin
+ 	install autorespond.1 $(PREFIX)/share/man/man1
 +
 +choose: \
 +warn-auto.sh choose.sh conf-home
@@ -74,6 +62,7 @@
 +	'-o "$$main" "$$main".o $${1+"$$@"}' \
 +	) > load
 +	chmod 755 load
+
 Index: TARGETS
 ===================================================================
 RCS file: TARGETS
@@ -99,20 +88,19 @@
 @@ -80,6 +80,8 @@
  #include <sys/wait.h>
  #include <ctype.h>
- 
+
 +#include "strcasestr.h"
 +
  #define DEFAULT_MH	1	/* default value for message_handling flag */
  #define DEFAULT_FROM	"$"	/* default "from" for the autorespond */
- 
-@@ -374,32 +376,6 @@
- 
- 
- 
--/*********************************************************
+
+@@ -374,35 +374,6 @@
+
+
+ /*********************************************************
 -** find string in string - ignore case **/
 -
--char *strcasestr_ar( char *_s1, char *_s2 )
+-char *strcasestr( char *_s1, char *_s2 )
 -{
 -	char *s1;
 -	char *s2;
@@ -135,27 +123,13 @@
 -		return _s1 + (ptr - s1);
 -}
 -
- 
- 
- 
-@@ -420,7 +396,7 @@
- 			if ( ss == (char *)NULL )
- 				return act_header->content;
- 
--			if ( strcasestr_ar( act_header->content, ss ) != (char *)NULL )
-+			if ( strcasestr( act_header->content, ss ) != (char *)NULL )
- 				return act_header->content;
- 
- 			return (char *)NULL;
-@@ -441,7 +417,7 @@
- 	if ( (s = inspect_headers( "Content-Type", (char *)NULL )) == (char *)NULL) 
- 		return (char *)NULL;
- 
--	if ( (r = strcasestr_ar( s, "boundary=" )) == (char *)NULL)
-+	if ( (r = strcasestr( s, "boundary=" )) == (char *)NULL)
- 		return (char *)NULL;
- 	
- 	*(r+strlen(r)-2) = '\0'; /* delete quote at the end */
+-
+-
+-
+-/*********************************************************
+ ** look up header tag in chain and try to find search string 
+ ** returns pointer to contetnt on success other wise NULL */
+
 Index: choose.sh
 ===================================================================
 RCS file: choose.sh
--- autorespond-conf-strcasestr.diff ends here ---


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: roam 
State-Changed-When: Tue Sep 2 06:50:45 PDT 2003 
State-Changed-Why:  
Update committed, thanks a lot for helping maintain the strcasestr(3) 
compatibility! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=56310 
>Unformatted:
