Moved the max-size checking code down so that it only checks
authorWayne Davison <wayned@samba.org>
Thu, 28 Apr 2005 16:26:23 +0000 (16:26 +0000)
committerWayne Davison <wayned@samba.org>
Thu, 28 Apr 2005 16:26:23 +0000 (16:26 +0000)
regular files.

generator.c

index a1e5663..3a7dda3 100644 (file)
@@ -726,16 +726,6 @@ static void recv_generator(char *fname, struct file_struct *file, int ndx,
                return;
        }
 
-       if (max_size && file->length > max_size) {
-               if (verbose > 1) {
-                       if (the_file_list->count == 1)
-                               fname = f_name(file);
-                       rprintf(FINFO, "%s is over max-size\n",
-                               safe_fname(fname));
-               }
-               return;
-       }
-
        if (preserve_links && S_ISLNK(file->mode)) {
 #ifdef SUPPORT_LINKS
                if (safe_symlinks && unsafe_symlink(file->u.link, fname)) {
@@ -847,6 +837,16 @@ static void recv_generator(char *fname, struct file_struct *file, int ndx,
                return;
        }
 
+       if (max_size && file->length > max_size) {
+               if (verbose > 1) {
+                       if (the_file_list->count == 1)
+                               fname = f_name(file);
+                       rprintf(FINFO, "%s is over max-size\n",
+                               safe_fname(fname));
+               }
+               return;
+       }
+
        if (opt_ignore_existing && statret == 0) {
                if (verbose > 1)
                        rprintf(FINFO, "%s exists\n", safe_fname(fname));