*** ../jabber-1.4.1.orig/./Makefile	Sat Jan 20 21:32:48 2001
--- ./Makefile	Tue Jan  8 19:50:24 2002
***************
*** 3,8 ****
--- 3,10 ----
  #
  include platform-settings
  
+ CFLAGS=$(CCFLAGS)
+ 
  SUBDIRS=pthsock xdb_file dnsrv jsm dialback jabberd
  
  all: all-recursive
***************
*** 29,39 ****
  check-recursive installcheck-recursive single-recursive static-recursive:
  	@set fnord $(MAKEFLAGS); amf=$$2; \
  	dot_seen=no; \
      if test "$@" = "single-recursive"; then \
!       export ISSINGLE=1; \
      fi; \
  	if test "$@" = "static-recursive"; then \
!       export ISSTATIC=1; \
  	fi; \
  	target=`echo $@ | sed s/-recursive//`; \
  	list='$(SUBDIRS)'; for subdir in $$list; do \
--- 31,42 ----
  check-recursive installcheck-recursive single-recursive static-recursive:
  	@set fnord $(MAKEFLAGS); amf=$$2; \
  	dot_seen=no; \
+     DEFINES='-DCONFIGXML="jabber.xml"'; \
      if test "$@" = "single-recursive"; then \
!       DEFINES='-DSINGLE -DSTATIC'; \
      fi; \
  	if test "$@" = "static-recursive"; then \
!       	    DEFINES='-DSTATIC'; \
  	fi; \
  	target=`echo $@ | sed s/-recursive//`; \
  	list='$(SUBDIRS)'; for subdir in $$list; do \
***************
*** 44,50 ****
  	  else \
  	    local_target="$$target"; \
  	  fi; \
! 	  (cd $$subdir && $(MAKE) $$local_target) \
  	   || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
  	done; \
  	if test "$$dot_seen" = "no"; then \
--- 47,53 ----
  	  else \
  	    local_target="$$target"; \
  	  fi; \
! 	  (cd $$subdir && $(MAKE) $$local_target DEFINES="$$DEFINES" )\
  	   || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
  	done; \
  	if test "$$dot_seen" = "no"; then \
*** ../jabber-1.4.1.orig/./configure	Fri Feb  2 21:06:24 2001
--- ./configure	Tue Jan  8 18:44:30 2002
***************
*** 22,34 ****
  ##
  # Setup our initial flags
  ##
! if [ -n "$CC" ]; then
!     CC="$CC";
! else
!     CC="gcc";
! fi;
! CFLAGS="$CFLAGS -g -Wall -fPIC -I. -I.."
! MCFLAGS="$MCFLAGS -shared"
  LDFLAGS="$LDFLAGS"
  LIBS="$LIBS"
  XLDFLAGS="$XLDFLAGS "
--- 22,41 ----
  ##
  # Setup our initial flags
  ##
! hosttype=`uname -s`
! case $hosttype in
!     HP-UX)
! 	    CC="cc -Ae"
! 	    CCFLAGS="$CFLAGS -g +z -I. -I.. +DS2.0 +DA2.0W"
! 	    MCFLAGS="$MCFLAGS -b"
! 	    ;;
!     *)
! 	    CC="gcc";
! 	    CCFLAGS="$CFLAGS -g -Wall -fPIC -I. -I.."
! 	    MCFLAGS="$MCFLAGS -shared"
! 	    ;;
! esac
! 
  LDFLAGS="$LDFLAGS"
  LIBS="$LIBS"
  XLDFLAGS="$XLDFLAGS "
***************
*** 50,56 ****
          if test -f "$dir/include/openssl/ssl.h"; then
              found_ssl="yes";
              printf "            Found.\n";
!     	    CFLAGS="$CFLAGS -I$ssldir/include/openssl -DHAVE_SSL";
  	        LIBS="$LIBS -lssl -lcrypto";
              LDFLAGS="$LDFLAGS -L$ssldir/lib";
              break;
--- 57,63 ----
          if test -f "$dir/include/openssl/ssl.h"; then
              found_ssl="yes";
              printf "            Found.\n";
!     	    CCFLAGS="$CCFLAGS -I$ssldir/include/openssl -DHAVE_SSL";
  	        LIBS="$LIBS -lssl -lcrypto";
              LDFLAGS="$LDFLAGS -L$ssldir/lib";
              break;
***************
*** 58,64 ****
          if test -f "$dir/include/ssl.h"; then
              found_ssl="yes";
              printf "            Found.\n";
!     	    CFLAGS="$CFLAGS -I$ssldir/include/ -DHAVE_SSL";
  	        LIBS="$LIBS -lssl -lcrypto";
              LDFLAGS="$LDFLAGS -L$ssldir/lib";
              break
--- 65,71 ----
          if test -f "$dir/include/ssl.h"; then
              found_ssl="yes";
              printf "            Found.\n";
!     	    CCFLAGS="$CCFLAGS -I$ssldir/include/ -DHAVE_SSL";
  	        LIBS="$LIBS -lssl -lcrypto";
              LDFLAGS="$LDFLAGS -L$ssldir/lib";
              break
***************
*** 76,88 ****
  ##
  # Pth check
  ##
! printf "Getting pth settings..."
! PTH_CFLAGS=`pth-config --cflags`
! PTH_LDFLAGS=`pth-config --ldflags`
! PTH_LIBS=`pth-config --libs`
! PTH_LIBDIR=`pth-config --libdir`
  if [ -n "$PTH_CFLAGS" ]; then
!     CFLAGS="$CFLAGS $PTH_CFLAGS";
      LDFLAGS="$LDFLAGS $PTH_LDFLAGS";
      LIBS="$LIBS $PTH_LIBS";
      SLIBS="$SLIBS $PTH_LIBDIR/libpth.a";
--- 83,100 ----
  ##
  # Pth check
  ##
! print "Getting pth settings..."
! 
! # Cheap & dirty test for pth-config. If not present, can't use...
! pth-config --version
! if [ $? -eq 0 ]; then
! 	PTH_CFLAGS=`pth-config --cflags`
! 	PTH_LDFLAGS=`pth-config --ldflags`
! 	PTH_LIBS=`pth-config --libs`
! 	PTH_LIBDIR=`pth-config --libdir`
! fi
  if [ -n "$PTH_CFLAGS" ]; then
!     CCFLAGS="$CCFLAGS $PTH_CFLAGS";
      LDFLAGS="$LDFLAGS $PTH_LDFLAGS";
      LIBS="$LIBS $PTH_LIBS";
      SLIBS="$SLIBS $PTH_LIBDIR/libpth.a";
***************
*** 96,102 ****
          PSUBDIR="pth-1.3.7";
          PTHP=`pwd`"/jabberd/pth-1.3.7";
          PLINK="$PTHP/pth_*.o";
!         CFLAGS="$CFLAGS -I`pwd`/jabberd/pth-1.3.7";
      else
          printf "          Error.\n\n No version of PTH is available on this system\nhttp://www.gnu.org/software/pth/";
      fi
--- 108,114 ----
          PSUBDIR="pth-1.3.7";
          PTHP=`pwd`"/jabberd/pth-1.3.7";
          PLINK="$PTHP/pth_*.o";
!         CCFLAGS="$CCFLAGS -I`pwd`/jabberd/pth-1.3.7";
      else
          printf "          Error.\n\n No version of PTH is available on this system\nhttp://www.gnu.org/software/pth/";
      fi
***************
*** 111,117 ****
  hosttype=`uname -s`
  case $hosttype in
      Linux)
!         CFLAGS="$CFLAGS"
          LIBS="$LIBS -ldl -lresolv"
          SLIBS="$SLIBS /usr/lib/libresolv.a";
          XLDFLAGS="$XLDFLAGS -Wl,--export-dynamic";;
--- 123,129 ----
  hosttype=`uname -s`
  case $hosttype in
      Linux)
!         CCFLAGS="$CCFLAGS"
          LIBS="$LIBS -ldl -lresolv"
          SLIBS="$SLIBS /usr/lib/libresolv.a";
          XLDFLAGS="$XLDFLAGS -Wl,--export-dynamic";;
***************
*** 120,130 ****
          if [ -n "$LDTEST" ]; then
              XLDFLAGS="$XLDFLAGS -Wl,-export-dynamic"
          fi
!         CFLAGS="$CFLAGS -D_REENTRANT"
          SLIBS="$SLIBS /usr/lib/libresolv.a";
          LIBS="$LIBS -ldl -lsocket -lnsl -lresolv";;
      FreeBSD)
          XLDFLAGS="$XLDFLAGS -Wl,-E";;
      AIX)
          # create an export file for AIX:
  cat <<EOF >jabberd/jabberd.exp
--- 132,144 ----
          if [ -n "$LDTEST" ]; then
              XLDFLAGS="$XLDFLAGS -Wl,-export-dynamic"
          fi
!         CCFLAGS="$CCFLAGS -D_REENTRANT"
          SLIBS="$SLIBS /usr/lib/libresolv.a";
          LIBS="$LIBS -ldl -lsocket -lnsl -lresolv";;
      FreeBSD)
          XLDFLAGS="$XLDFLAGS -Wl,-E";;
+     HP-UX)
+         XLDFLAGS="$XLDFLAGS -Wl,-E -lm -ldl -Wl,+std";;
      AIX)
          # create an export file for AIX:
  cat <<EOF >jabberd/jabberd.exp
***************
*** 133,139 ****
  _pool_new
  _pool_new_heap
  EOF
! CFLAGS="$CFLAGS -DMAXDNAME=1025"
  MCFLAGS="$MCFLAGS -Wl,-G"
  XLDFLAGS="$XLDFLAGS -Wl,-brtl,-bexpall,-bE:jabberd.exp";;
  
--- 147,153 ----
  _pool_new
  _pool_new_heap
  EOF
! CCFLAGS="$CCFLAGS -DMAXDNAME=1025"
  MCFLAGS="$MCFLAGS -Wl,-G"
  XLDFLAGS="$XLDFLAGS -Wl,-brtl,-bexpall,-bE:jabberd.exp";;
  
***************
*** 146,152 ****
  cat << EOF > platform-settings
  #!/bin/sh
  CC=$CC
! CFLAGS=$CFLAGS
  MCFLAGS=$MCFLAGS
  LDFLAGS=$LDFLAGS
  LIBS=$LIBS
--- 160,166 ----
  cat << EOF > platform-settings
  #!/bin/sh
  CC=$CC
! CCFLAGS=$CCFLAGS
  MCFLAGS=$MCFLAGS
  LDFLAGS=$LDFLAGS
  LIBS=$LIBS
*** ../jabber-1.4.1.orig/./jabber.xml	Mon Feb  5 14:19:20 2001
--- ./jabber.xml	Tue Jan  8 20:05:30 2002
***************
*** 43,49 ****
      be on one line, the server doesn't like it otherwise! :)
      -->
  
!     <host><jabberd:cmdline flag="h">localhost</jabberd:cmdline></host>
  
      <!-- 
      This is the custom configuration section for the 
--- 43,49 ----
      be on one line, the server doesn't like it otherwise! :)
      -->
  
!     <host><jabberd:cmdline flag="h">hpindgr.cup.hp.com</jabberd:cmdline></host>
  
      <!-- 
      This is the custom configuration section for the 
***************
*** 193,199 ****
--- 193,201 ----
        entry for <host/> above.
        -->
  
+       <!--
        <update><jabberd:cmdline flag="h">localhost</jabberd:cmdline></update>
+       -->
  
        <!--
        This enables the server to automatically update the 
*** ../jabber-1.4.1.orig/./jabberd/base/Makefile	Sat Jan 13 14:06:55 2001
--- ./jabberd/base/Makefile	Tue Jan  8 16:50:58 2002
***************
*** 3,9 ****
  #
  include ../../platform-settings
  
! CFLAGS:=$(CFLAGS)
  
  base_OBJECTS = \
  	base_connect.o \
--- 3,9 ----
  #
  include ../../platform-settings
  
! CFLAGS=$(CCFLAGS)
  
  base_OBJECTS = \
  	base_connect.o \
*** ../jabber-1.4.1.orig/./jabberd/lib/Makefile	Sun Jan 28 02:18:17 2001
--- ./jabberd/lib/Makefile	Tue Jan  8 16:50:59 2002
***************
*** 3,9 ****
  #
  include ../../platform-settings
  
! CFLAGS:=$(CFLAGS)
  
  lib_HEADERS= \
  	asciitab.h \
--- 3,9 ----
  #
  include ../../platform-settings
  
! CFLAGS=$(CCFLAGS)
  
  lib_HEADERS= \
  	asciitab.h \
*** ../jabber-1.4.1.orig/./jabberd/lib/jutil.c	Wed Jan  3 03:00:00 2001
--- ./jabberd/lib/jutil.c	Tue Jan  8 19:50:11 2002
***************
*** 275,277 ****
--- 275,285 ----
      return NULL;
  }
  
+ #ifndef GCC
+ terror TERROR(const int code, const char *msg) {
+ 	terror t;
+ 	t.code=code;
+ 	strncpy(t.msg,msg,64);
+ 	return t;
+ }
+ #endif
*** ../jabber-1.4.1.orig/./jabberd/lib/lib.h	Wed Apr  4 23:33:35 2001
--- ./jabberd/lib/lib.h	Tue Jan  8 19:56:34 2002
***************
*** 586,608 ****
      char msg[64];
  } terror;
  
! #define TERROR_BAD           (terror){400,"Bad Request"}
! #define TERROR_AUTH          (terror){401,"Unauthorized"}
! #define TERROR_PAY           (terror){402,"Payment Required"}
! #define TERROR_FORBIDDEN     (terror){403,"Forbidden"}
! #define TERROR_NOTFOUND      (terror){404,"Not Found"}
! #define TERROR_NOTALLOWED    (terror){405,"Not Allowed"}
! #define TERROR_NOTACCEPTABLE (terror){406,"Not Acceptable"}
! #define TERROR_REGISTER      (terror){407,"Registration Required"}
! #define TERROR_REQTIMEOUT    (terror){408,"Request Timeout"}
! #define TERROR_CONFLICT      (terror){409,"Conflict"}
  
! #define TERROR_INTERNAL   (terror){500,"Internal Server Error"}
! #define TERROR_NOTIMPL    (terror){501,"Not Implemented"}
! #define TERROR_EXTERNAL   (terror){502,"Remote Server Error"}
! #define TERROR_UNAVAIL    (terror){503,"Service Unavailable"}
! #define TERROR_EXTTIMEOUT (terror){504,"Remote Server Timeout"}
! #define TERROR_DISCONNECTED (terror){510,"Disconnected"}
  
  /* --------------------------------------------------------- */
  /*                                                           */
--- 586,617 ----
      char msg[64];
  } terror;
  
! #ifdef GCC
! #define TERROR(code, msg) (terror){code, msg}
! #else
! terror TERROR(const int code, const char *msg);
! #endif
  
! #define TERROR_BAD           TERROR(400,"Bad Request")
! #define TERROR_AUTH          TERROR(401,"Unauthorized")
! #define TERROR_PAY           TERROR(402,"Payment Required")
! #define TERROR_FORBIDDEN     TERROR(403,"Forbidden")
! #define TERROR_NOTFOUND      TERROR(404,"Not Found")
! #define TERROR_NOTALLOWED    TERROR(405,"Not Allowed")
! #define TERROR_NOTACCEPTABLE TERROR(406,"Not Acceptable")
! #define TERROR_REGISTER      TERROR(407,"Registration Required")
! #define TERROR_REQTIMEOUT    TERROR(408,"Request Timeout")
! #define TERROR_CONFLICT      TERROR(409,"Conflict")
! #define TERROR_USERNAMENOTOK TERROR(409,"Username Not Available")
! 
! #define TERROR_INTERNAL   TERROR(500,"Internal Server Error")
! #define TERROR_PASSWDNOSTORE TERROR(500,"Password Storage Failed")
! #define TERROR_NOTIMPL    TERROR(501,"Not Implemented")
! #define TERROR_EXTERNAL   TERROR(502,"Remote Server Error")
! #define TERROR_CANTRESOLVE TERROR(502,"Unable to resolve hostname")
! #define TERROR_UNAVAIL    TERROR(503,"Service Unavailable")
! #define TERROR_EXTTIMEOUT TERROR(504,"Remote Server Timeout")
! #define TERROR_DISCONNECTED TERROR(510,"Disconnected")
  
  /* --------------------------------------------------------- */
  /*                                                           */
*** ../jabber-1.4.1.orig/./jabberd/Makefile	Thu Feb  1 23:09:37 2001
--- ./jabberd/Makefile	Tue Jan  8 20:02:37 2002
***************
*** 3,19 ****
  #
  include ../platform-settings
  
! ifeq ($(ISSINGLE),1)
! 	DEFINES=-DHOME="\"$(JHOME)\"" -DSINGLE -DSTATIC
! else
! 	DEFINES=-DHOME="\"$(JHOME)\"" -DCONFIGXML="\"jabber.xml\""
! endif
! ifeq ($(ISSTATIC),1)
! 	DEFINES=-DHOME="\"$(JHOME)\"" -DSTATIC
! endif
  
- CFLAGS:=$(CFLAGS) $(DEFINES)
- 
  jabberd_HEADERS=jabberd.h single.h
  
  SUBDIRS=base lib $(PSUBDIR)
--- 3,10 ----
  #
  include ../platform-settings
  
! CFLAGS=$(CCFLAGS) -DHOME=\"$(JHOME)\"
  
  jabberd_HEADERS=jabberd.h single.h
  
  SUBDIRS=base lib $(PSUBDIR)
***************
*** 23,29 ****
  	mio.o \
  	mio_raw.o \
  	mio_xml.o \
!     mio_ssl.o \
  	deliver.o \
  	heartbeat.o \
  	jabberd.o \
--- 14,20 ----
  	mio.o \
  	mio_raw.o \
  	mio_xml.o \
! 	mio_ssl.o \
  	deliver.o \
  	heartbeat.o \
  	jabberd.o \
***************
*** 63,69 ****
  	base/base_format.o \
  	base/base_stderr.o \
  	base/base_to.o
! 	
  jabberd_STATICOBJS=\
  	$(JHOME)/jsm/deliver.o \
  	$(JHOME)/jsm/jsm.o \
--- 54,60 ----
  	base/base_format.o \
  	base/base_stderr.o \
  	base/base_to.o
! 
  jabberd_STATICOBJS=\
  	$(JHOME)/jsm/deliver.o \
  	$(JHOME)/jsm/jsm.o \
***************
*** 96,104 ****
  	$(JHOME)/jsm/modules/mod_xml.o \
  	$(JHOME)/dnsrv/dnsrv.o \
  	$(JHOME)/dnsrv/srv_resolv.o \
!     $(JHOME)/dialback/dialback.o \
!     $(JHOME)/dialback/dialback_out.o \
!     $(JHOME)/dialback/dialback_in.o \
  	$(JHOME)/pthsock/client.o \
  	$(JHOME)/xdb_file/xdb_file.o
  
--- 87,95 ----
  	$(JHOME)/jsm/modules/mod_xml.o \
  	$(JHOME)/dnsrv/dnsrv.o \
  	$(JHOME)/dnsrv/srv_resolv.o \
! 	$(JHOME)/dialback/dialback.o \
! 	$(JHOME)/dialback/dialback_out.o \
! 	$(JHOME)/dialback/dialback_in.o \
  	$(JHOME)/pthsock/client.o \
  	$(JHOME)/xdb_file/xdb_file.o
  
*** ../jabber-1.4.1.orig/./jabberd/deliver.c	Sat Feb  3 14:46:57 2001
--- ./jabberd/deliver.c	Tue Jan  8 18:29:22 2002
***************
*** 440,447 ****
  	 return;
  
      /* catch the @-internal xdb crap */
!     if(p->type == p_XDB && *(p->host) == '-')
!         return deliver_internal(p, i);
  
      if(deliver__flag == 0)
      { /* postpone delivery till later */
--- 440,449 ----
  	 return;
  
      /* catch the @-internal xdb crap */
!     if(p->type == p_XDB && *(p->host) == '-') {
!         deliver_internal(p, i);
! 	return;
!     }
  
      if(deliver__flag == 0)
      { /* postpone delivery till later */
***************
*** 565,570 ****
--- 567,573 ----
          h1->next = newh;
          break;
      default:
+ 	break;
      }
  }
  
***************
*** 630,635 ****
--- 633,639 ----
          }
          break;
      default:
+         break;
      }
  }
  
*** ../jabber-1.4.1.orig/./jabberd/mio.c	Tue Mar 27 20:33:38 2001
--- ./jabberd/mio.c	Tue Jan  8 18:30:57 2002
***************
*** 292,298 ****
          else if(len < cur->len)
          { 
  
!             cur->cur += len;
              cur->len -= len;
              return 1;
          } 
--- 292,298 ----
          else if(len < cur->len)
          { 
  
!             cur->cur = &cur->cur + len;
              cur->len -= len;
              return 1;
          } 
*** ../jabber-1.4.1.orig/./jabberd/mio_xml.c	Mon Apr  2 23:30:42 2001
--- ./jabberd/mio_xml.c	Tue Jan  8 18:31:10 2002
***************
*** 142,155 ****
          nul += 4;
          bufsz = bufsz - (nul - buf);
          buf = nul;
!         mio_write(m,NULL,"HTTP/1.0 200 Ok
! Server: jabber/xmlstream-hack-0.1
! Expires: Fri, 10 Oct 1997 10:10:10 GMT
! Pragma: no-cache
! Cache-control: private
! Connection: close
! 
! ",-1);
          m->type = type_NORMAL;
      }
  
--- 142,155 ----
          nul += 4;
          bufsz = bufsz - (nul - buf);
          buf = nul;
!         mio_write(m,NULL,"HTTP/1.0 200 Ok \n\
! Server: jabber/xmlstream-hack-0.1 \n\
! Expires: Fri, 10 Oct 1997 10:10:10 GMT \n\
! Pragma: no-cache \n\
! Cache-control: private \n\
! Connection: close \n\
!  \n\
! ", -1);
          m->type = type_NORMAL;
      }
  
*** ../jabber-1.4.1.orig/./jabberd/single.h	Sun Feb  4 21:25:57 2001
--- ./jabberd/single.h	Tue Jan  8 18:31:58 2002
***************
*** 3,10 ****
      if(ghash_get(cmd__line,"h") == NULL || (home == NULL && (ghash_get(cmd__line,"s") == NULL || ghash_get(cmd__line,"l") == NULL))) \
      { /* require hostname, and either a HOME or the spool and logs specifically */ \
          fprintf(stderr, "\
! Usage:
!  jabberd -h hostname -s /var/spool/jabber -l /var/log/jabber.log &\n\
  Required Parameters:\n\
   -h \t\t A valid hostname that this server is accessible via\n\
   -s \t\t A folder in which user account data can be stored\n\
--- 3,9 ----
      if(ghash_get(cmd__line,"h") == NULL || (home == NULL && (ghash_get(cmd__line,"s") == NULL || ghash_get(cmd__line,"l") == NULL))) \
      { /* require hostname, and either a HOME or the spool and logs specifically */ \
          fprintf(stderr, "\
! Usage: jabberd -h hostname -s /var/spool/jabber -l /var/log/jabber.log &\n\
  Required Parameters:\n\
   -h \t\t A valid hostname that this server is accessible via\n\
   -s \t\t A folder in which user account data can be stored\n\
*** ../jabber-1.4.1.orig/./jsm/modules/Makefile	Thu Feb  1 23:09:38 2001
--- ./jsm/modules/Makefile	Tue Jan  8 17:03:06 2002
***************
*** 1,6 ****
  include ../../platform-settings
  
! CFLAGS:=$(CFLAGS) $(DEFINES) -I../../jabberd/
  
  jsm_modules_HEADERS=../jsm.h ../../jabberd/jabberd.h
  
--- 1,6 ----
  include ../../platform-settings
  
! CFLAGS=$(CCFLAGS) -I../../jabberd/
  
  jsm_modules_HEADERS=../jsm.h ../../jabberd/jabberd.h
  
*** ../jabber-1.4.1.orig/./jsm/modules/mod_auth_0k.c	Mon Mar 12 12:44:50 2001
--- ./jsm/modules/mod_auth_0k.c	Tue Jan  8 20:10:41 2002
***************
*** 148,154 ****
  
      if(mod_auth_0k_reset(m,m->packet->to,xmlnode_get_tag(m->packet->iq,"password")))
      {
!         jutil_error(m->packet->x,(terror){500,"Password Storage Failed"});
          return M_HANDLED;
      }
  
--- 148,154 ----
  
      if(mod_auth_0k_reset(m,m->packet->to,xmlnode_get_tag(m->packet->iq,"password")))
      {
!         jutil_error(m->packet->x,TERROR_PASSWDNOSTORE);
          return M_HANDLED;
      }
  
***************
*** 168,174 ****
  
      if(mod_auth_0k_reset(m,m->user->id,pass))
      {
!         js_bounce(m->si,m->packet->x,(terror){500,"Password Storage Failed"});
          return M_HANDLED;
      }
      return M_PASS;
--- 168,174 ----
  
      if(mod_auth_0k_reset(m,m->user->id,pass))
      {
!         js_bounce(m->si,m->packet->x,TERROR_PASSWDNOSTORE);
          return M_HANDLED;
      }
      return M_PASS;
*** ../jabber-1.4.1.orig/./jsm/modules/mod_auth_plain.c	Mon Mar 12 12:44:50 2001
--- ./jsm/modules/mod_auth_plain.c	Tue Jan  8 18:49:09 2002
***************
*** 81,87 ****
  
      if(mod_auth_plain_reset(m,m->packet->to,xmlnode_get_tag(m->packet->iq,"password")))
      {
!         jutil_error(m->packet->x,(terror){500,"Password Storage Failed"});
          return M_HANDLED;
      }
  
--- 81,87 ----
  
      if(mod_auth_plain_reset(m,m->packet->to,xmlnode_get_tag(m->packet->iq,"password")))
      {
!         jutil_error(m->packet->x,TERROR_PASSWDNOSTORE);
          return M_HANDLED;
      }
  
***************
*** 101,107 ****
  
      if(mod_auth_plain_reset(m,m->user->id,pass))
      {
!         js_bounce(m->si,m->packet->x,(terror){500,"Password Storage Failed"});
          return M_HANDLED;
      }
      return M_PASS;
--- 101,107 ----
  
      if(mod_auth_plain_reset(m,m->user->id,pass))
      {
!         js_bounce(m->si,m->packet->x,TERROR_PASSWDNOSTORE);
          return M_HANDLED;
      }
      return M_PASS;
*** ../jabber-1.4.1.orig/./jsm/Makefile	Thu Feb  1 23:09:38 2001
--- ./jsm/Makefile	Tue Jan  8 19:27:10 2002
***************
*** 3,9 ****
  #
  include ../platform-settings
  
! CFLAGS:=$(CFLAGS) $(DEFINES) -I../jabberd/
  
  jsm_HEADERS=jsm.h ../jabberd/jabberd.h
  
--- 3,9 ----
  #
  include ../platform-settings
  
! CFLAGS=$(CCFLAGS) -I../jabberd/
  
  jsm_HEADERS=jsm.h ../jabberd/jabberd.h
  
***************
*** 51,57 ****
  $(jsm_OBJECTS): $(jsm_HEADERS)
  
  all-local: $(jsm_OBJECTS) $(jsm_HEADERS)
! 	$(CC) $(CFLAGS) $(MCFLAGS) -o jsm.so $(jsm_OBJECTS) $(jsm_EXOBJECTS) $(LDFLAGS) $(LIBS)
  
  static: static-recursive
  
--- 51,57 ----
  $(jsm_OBJECTS): $(jsm_HEADERS)
  
  all-local: $(jsm_OBJECTS) $(jsm_HEADERS)
! 	$(LD) $(MCFLAGS) -o jsm.so $(jsm_OBJECTS) $(jsm_EXOBJECTS) $(LDFLAGS) $(LIBS)
  
  static: static-recursive
  
*** ../jabber-1.4.1.orig/./jsm/authreg.c	Fri Oct 20 22:34:58 2000
--- ./jsm/authreg.c	Tue Jan  8 18:50:21 2002
***************
*** 86,92 ****
              {
                  jutil_error(p->x, TERROR_NOTACCEPTABLE);
              }else if(js_user(si,p->to,NULL) != NULL){
!                 jutil_error(p->x, (terror){409,"Username Not Available"});
              }else if(!js_mapi_call(si, e_REGISTER, p, NULL, NULL)){
                  jutil_error(p->x, TERROR_NOTIMPL);
              }
--- 86,92 ----
              {
                  jutil_error(p->x, TERROR_NOTACCEPTABLE);
              }else if(js_user(si,p->to,NULL) != NULL){
!                 jutil_error(p->x, TERROR_USERNAMENOTOK);
              }else if(!js_mapi_call(si, e_REGISTER, p, NULL, NULL)){
                  jutil_error(p->x, TERROR_NOTIMPL);
              }
*** ../jabber-1.4.1.orig/./jsm/modules.c	Fri Oct 20 22:34:58 2000
--- ./jsm/modules.c	Tue Jan  8 18:32:24 2002
***************
*** 157,162 ****
--- 157,163 ----
          case M_HANDLED:
              return 1;
          default:
+ 	    break;
          }
      }
  
*** ../jabber-1.4.1.orig/./pthsock/Makefile	Sat Jan 20 21:37:53 2001
--- ./pthsock/Makefile	Tue Jan  8 19:27:21 2002
***************
*** 1,6 ****
  include ../platform-settings
  
! CFLAGS:=$(CFLAGS) -I../jabberd/
  
  HEADERS=../jabberd/jabberd.h
  
--- 1,6 ----
  include ../platform-settings
  
! CFLAGS=$(CCFLAGS) -I../jabberd/
  
  HEADERS=../jabberd/jabberd.h
  
***************
*** 14,20 ****
  $(pthsock_client_OBJECTS): $(HEADERS)
  
  pthsock_client: $(pthsock_client_OBJECTS) $(HEADERS)
! 	$(CC) $(CFLAGS) $(MCFLAGS) -o pthsock_client.so $(pthsock_client_OBJECTS) $(LDFLAGS) $(LIBS)
  
  static: $(pthsock_client_OBJECTS) $(HEADERS)
  
--- 14,20 ----
  $(pthsock_client_OBJECTS): $(HEADERS)
  
  pthsock_client: $(pthsock_client_OBJECTS) $(HEADERS)
! 	$(LD) $(MCFLAGS) -o pthsock_client.so $(pthsock_client_OBJECTS) $(LDFLAGS) $(LIBS)
  
  static: $(pthsock_client_OBJECTS) $(HEADERS)
  
*** ../jabber-1.4.1.orig/./xdb_file/Makefile	Sat Jan 13 14:06:56 2001
--- ./xdb_file/Makefile	Tue Jan  8 19:27:27 2002
***************
*** 1,6 ****
  include ../platform-settings
  
! CFLAGS:=$(CFLAGS) -I../jabberd
  
  xdb_file_OBJECTS=xdb_file.o
  
--- 1,6 ----
  include ../platform-settings
  
! CFLAGS=$(CCFLAGS) -I../jabberd
  
  xdb_file_OBJECTS=xdb_file.o
  
***************
*** 9,15 ****
  all: xdb_file
  
  xdb_file: $(xdb_file_OBJECTS)
! 	$(CC) $(CFLAGS) $(MCFLAGS) -o xdb_file.so $(xdb_file_OBJECTS) $(LDFLAGS) $(LIBS)
  
  static: $(xdb_file_OBJECTS)
  
--- 9,15 ----
  all: xdb_file
  
  xdb_file: $(xdb_file_OBJECTS)
! 	$(LD) $(MCFLAGS) -o xdb_file.so $(xdb_file_OBJECTS) $(LDFLAGS) $(LIBS)
  
  static: $(xdb_file_OBJECTS)
  
*** ../jabber-1.4.1.orig/./dnsrv/Makefile	Tue Jan 23 02:48:30 2001
--- ./dnsrv/Makefile	Tue Jan  8 19:27:32 2002
***************
*** 1,6 ****
  include ../platform-settings
  
! CFLAGS:=$(CFLAGS) -I../jabberd/
  
  dnsrv_HEADERS=srv_resolv.h ../jabberd/jabberd.h
  
--- 1,6 ----
  include ../platform-settings
  
! CFLAGS=$(CCFLAGS) -I../jabberd/
  
  dnsrv_HEADERS=srv_resolv.h ../jabberd/jabberd.h
  
***************
*** 13,19 ****
  $(dnsrv_OBJECTS): $(dnsrv_HEADERS)
  
  dnsrv_build: $(dnsrv_OBJECTS) $(dnsrv_HEADERS)
! 	$(CC) $(CFLAGS) $(MCFLAGS) -o dnsrv.so $(dnsrv_OBJECTS) 
  
  static: $(dnsrv_OBJECTS) $(dnsrv_HEADERS)
  
--- 13,19 ----
  $(dnsrv_OBJECTS): $(dnsrv_HEADERS)
  
  dnsrv_build: $(dnsrv_OBJECTS) $(dnsrv_HEADERS)
! 	$(LD) $(MCFLAGS) -o dnsrv.so $(dnsrv_OBJECTS) $(LDFLAGS)
  
  static: $(dnsrv_OBJECTS) $(dnsrv_HEADERS)
  
*** ../jabber-1.4.1.orig/./dnsrv/dnsrv.c	Tue Feb 20 02:09:48 2001
--- ./dnsrv/dnsrv.c	Tue Jan  8 18:50:58 2002
***************
*** 205,211 ****
  	 xmlnode_put_attrib(pkt, "to", to);
  	 xmlnode_put_attrib(pkt, "ip", ip);
      }else{
! 	 jutil_error(pkt, (terror){502, "Unable to resolve hostname."});
  	 xmlnode_put_attrib(pkt, "iperror", "");
      }
      deliver(dpacket_new(pkt),NULL);
--- 205,211 ----
  	 xmlnode_put_attrib(pkt, "to", to);
  	 xmlnode_put_attrib(pkt, "ip", ip);
      }else{
! 	 jutil_error(pkt, TERROR_CANTRESOLVE);
  	 xmlnode_put_attrib(pkt, "iperror", "");
      }
      deliver(dpacket_new(pkt),NULL);
*** ../jabber-1.4.1.orig/./dialback/Makefile	Thu Jan 18 03:35:28 2001
--- ./dialback/Makefile	Tue Jan  8 19:27:38 2002
***************
*** 1,6 ****
  include ../platform-settings
  
! CFLAGS:=$(CFLAGS) -I../jabberd
  
  dialback_OBJECTS=dialback.o dialback_in.o dialback_out.o
  
--- 1,6 ----
  include ../platform-settings
  
! CFLAGS=$(CCFLAGS) -I../jabberd
  
  dialback_OBJECTS=dialback.o dialback_in.o dialback_out.o
  
***************
*** 7,13 ****
  all: dialback
  
  dialback: $(dialback_OBJECTS)
! 	$(CC) $(CFLAGS) $(MCFLAGS) -o dialback.so $(dialback_OBJECTS) $(LDFLAGS) $(LIBS)
  
  static: $(dialback_OBJECTS)
  
--- 7,13 ----
  all: dialback
  
  dialback: $(dialback_OBJECTS)
! 	$(LD) $(MCFLAGS) -o dialback.so $(dialback_OBJECTS) $(LDFLAGS) $(LIBS)
  
  static: $(dialback_OBJECTS)
  
