From a7d6a8b51213456e8be087f0e4e4e1f90c5b844a Mon Sep 17 00:00:00 2001
From: micah <devnull@localhost>
Date: Mon, 27 Aug 2007 14:28:22 -0700
Subject: [PATCH] [svn] Modification of patch to recur.c

---
 src/ChangeLog | 1 +
 src/recur.c   | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/ChangeLog b/src/ChangeLog
index 7de71b35..d727a40e 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -6,6 +6,7 @@
 	* getopt.c: Fix missing (but, accidentally, legal) comment
 	delimiter after licensing text.
 	* recur.c (retrieve_tree): Inserted missing cast for strip_auth.
+	Includes adjustment by Ralf Wildenhues.
 	* openssl.c (ssl_init): const-ified the meth local variable.
 	* main.c: Include all the static function definitions in the
 	"#ifndef TESTING" clause, leaving just the definitions for
diff --git a/src/recur.c b/src/recur.c
index 9de774c4..57932f8d 100644
--- a/src/recur.c
+++ b/src/recur.c
@@ -325,7 +325,8 @@ retrieve_tree (const char *start_url)
               struct urlpos *child = children;
               struct url *url_parsed = url_parsed = url_parse (url, NULL);
               char *referer_url = url;
-              bool strip_auth = (bool)url_parsed->user;
+              bool strip_auth = (url_parsed != NULL
+                                 && url_parsed->user != NULL);
               assert (url_parsed != NULL);
 
               /* Strip auth info if present */