gnu-arch-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnu-arch-users] proftpd fix - request for merge/application


From: Johannes Berg
Subject: [Gnu-arch-users] proftpd fix - request for merge/application
Date: Fri, 23 Jan 2004 21:54:50 +0100

Hi,

I've been having so many problems with proftpd and archive-mirror that I
decided it would be best to just ignore the 450 error from proftpd's
NLST if the directory exists.

Here's a patch, also at
address@hidden/tla--proftpd--1.2--patch-1
http://johannes.sipsolutions.de/archives/address@hidden/

This problem is really annoying to me since johannes.sipsolutions.de
uses proftpd (and I do not control that) and thus I can never use
archive-mirror when I created a new category, branch or version, I
always have to upload that completely by hand.

Because its so short, here's the patch:

--- orig/libarch/pfs-ftp.c
+++ mod/libarch/pfs-ftp.c
@@ -620,12 +620,14 @@
  
           if (0 > file_in_fd)
             {
-              /* Workaround for buggy ftp servers that respond a 550 code for 
empty directories
+              /* Workaround for buggy ftp servers that respond a 450 or 550 
code for empty directories.
+               * 450 is reported by proftpd:
+               *    "450 No files found"
                * The pfs_ftp_is_dir ensures the directory exists as it chdir 
to the given path.
                * Btw, we could not have used pfs_ftp_file_exists otherwise we 
would have created
                * an infinte function call loop because pfs_ftp_file_exists 
relies on
                * pfs_ftp_directory_files */
-              if (code != 550 || !pfs_ftp_is_dir (p, path))
+              if ((code != 450 && code != 550) || !pfs_ftp_is_dir (p, path))
                 goto put_error;
             }
           else
 
 
 


johannes
-- 
http://www.sipsolutions.de/
Key-ID: 9AB78CA5 Johannes Martin Berg <address@hidden>

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]