Some translated messages changed



Hello,

I commited patch and there are some translated messages changed.
I fixed Russian and Ukrainian translations, but
other languages need to be fixed.

s/"ftpfs: storing file %d (%lu)"/"ftpfs: storing file %lu (%lu)"/
s/"%s: %s: %s %3d%% (%ld bytes transfered)"/"%s: %s: %s %3d%% (%lu bytes transfered)"/
s/"%s: %s: %s %ld bytes transfered"/"%s: %s: %s %lu bytes transfered"/

Regards,
Andrew.

Index: mc/vfs/ChangeLog
diff -u mc/vfs/ChangeLog:1.379 mc/vfs/ChangeLog:1.380
--- mc/vfs/ChangeLog:1.379	Thu Feb  7 14:22:21 2002
+++ mc/vfs/ChangeLog	Fri Feb  8 04:42:38 2002
@@ -1,3 +1,19 @@
+2002-02-08  Andrew V. Samoilov  <kai cmail ru>
+
+	* direntry.c (vfs_s_retrieve_file): Use off_t for total
+	and stat_size.
+
+	* vfs.c (vfs_s_resolve_symlink): Use snprintf
+	instead of sprintf.
+	(vfs_print_stats): Use off_t for have and need.  Cast
+	have to double to eliminate negative percent(s).
+	Fix print_vfs_message string formats.
+
+	* vfs.h (vfs_print_stats): Adjust declaration.
+
+	* ftpfs.c (file_store): Use off_t for total.
+	Fix print_vfs_message string format.
+
 2002-02-07  Andrew V. Samoilov  <kai cmail ru>
 
 	* ftpfs.c (dir_load): Speed up cd_first calculation.
Index: mc/vfs/ftpfs.c
diff -u mc/vfs/ftpfs.c:1.88 mc/vfs/ftpfs.c:1.89
--- mc/vfs/ftpfs.c:1.88	Thu Feb  7 14:22:20 2002
+++ mc/vfs/ftpfs.c	Fri Feb  8 04:42:38 2002
@@ -1359,7 +1359,8 @@
 static int
 file_store(vfs *me, vfs_s_super *super, char *name, char *localname)
 {
-    int h, sock, n, total;
+    int h, sock, n;
+    off_t total;
 #ifdef HAVE_STRUCT_LINGER
     struct linger li;
 #else
@@ -1415,8 +1416,8 @@
 	    goto error_return;
 	}
 	total += n;
-	print_vfs_message(_("ftpfs: storing file %d (%lu)"),
-			  total, (unsigned long) s.st_size);
+	print_vfs_message(_("ftpfs: storing file %lu (%lu)"),
+			  (unsigned long) total, (unsigned long) s.st_size);
     }
     disable_interrupt_key();
     close(sock);
Index: mc/vfs/vfs.h
diff -u mc/vfs/vfs.h:1.57 mc/vfs/vfs.h:1.58
--- mc/vfs/vfs.h:1.57	Mon Jan 21 16:26:50 2002
+++ mc/vfs/vfs.h	Fri Feb  8 04:42:38 2002
@@ -338,7 +338,8 @@
 
 #define URL_DEFAULTANON 1
 #define URL_NOSLASH 2
-extern void vfs_print_stats (char *fs_name, char *action, char *file_name, int have, int need);
+extern void vfs_print_stats (const char *fs_name, const char *action,
+			     const char *file_name, off_t have, off_t need);
 
 /* Don't use values 0..4 for a while -- 10/98, pavel ucw cz */
 #define MCCTL_REMOVELOCALCOPY   5
Index: mc/vfs/vfs.c
diff -u mc/vfs/vfs.c:1.80 mc/vfs/vfs.c:1.81
--- mc/vfs/vfs.c:1.80	Mon Jan 21 06:52:25 2002
+++ mc/vfs/vfs.c	Fri Feb  8 04:42:38 2002
@@ -1840,21 +1840,21 @@
 }
 
 void
-vfs_print_stats (char *fs_name, char *action, char *file_name, int have, int need)
+vfs_print_stats (const char *fs_name, const char *action, const char *file_name, off_t have, off_t need)
 {
     static char *i18n_percent_transf_format = NULL, *i18n_transf_format = NULL;
-    
+
     if (i18n_percent_transf_format == NULL) {
-        i18n_percent_transf_format = _("%s: %s: %s %3d%% (%ld bytes transfered)");
-	i18n_transf_format = _("%s: %s: %s %ld bytes transfered");
-	}
+	i18n_percent_transf_format = _("%s: %s: %s %3d%% (%lu bytes transfered)");
+	i18n_transf_format = _("%s: %s: %s %lu bytes transfered");
+    }
 
     if (need) 
-        print_vfs_message (i18n_percent_transf_format, 
-			   fs_name, action, file_name, have*100/need, have);
+	print_vfs_message (i18n_percent_transf_format, fs_name, action,
+			   file_name, (int)((double)have*100/need), (unsigned long) have);
     else
-        print_vfs_message (i18n_transf_format,
-			   fs_name, action, file_name, have);
+	print_vfs_message (i18n_transf_format,
+			   fs_name, action, file_name, (unsigned long) have);
 }
 
 #ifndef VFS_STANDALONE
Index: mc/vfs/direntry.c
diff -u mc/vfs/direntry.c:1.38 mc/vfs/direntry.c:1.39
--- mc/vfs/direntry.c:1.38	Thu Aug 16 18:23:05 2001
+++ mc/vfs/direntry.c	Fri Feb  8 04:42:38 2002
@@ -3,7 +3,7 @@
  *
  * Written at 1998 by Pavel Machek <pavel ucw cz>, distribute under LGPL.
  *
- * $Id: direntry.c,v 1.38 2001/08/16 22:23:05 proskin Exp $
+ * $Id: direntry.c,v 1.39 2002/02/08 09:42:38 andrew Exp $
  *
  * Very loosely based on tar.c from midnight and archives.[ch] from
  * avfs by Miklos Szeredi (mszeredi inf bme hu)
@@ -368,7 +368,7 @@
 	    return (MEDATA->find_entry) (me, entry->dir->super->root, linkname, follow - 1, 0);
 	else { /* FIXME: this does not work */ 
 	    char *fullpath = vfs_s_fullpath(me, entry->dir);
-	    sprintf(buf, "%s/%s", fullpath, linkname);
+	    snprintf(buf, sizeof (buf), "%s/%s", fullpath, linkname);
 	    g_free (fullpath);
 	    return (MEDATA->find_entry) (me, entry->dir->super->root, buf, follow - 1, 0);
 	}
@@ -934,14 +934,14 @@
 vfs_s_retrieve_file(vfs *me, struct vfs_s_inode *ino)
 {
     /* If you want reget, you'll have to open file with O_LINEAR */
-    int total = 0;
+    off_t total = 0;
     char buffer[8192];
     int handle, n;
-    int stat_size = ino->st.st_size;
+    off_t stat_size = ino->st.st_size;
     struct vfs_s_fh fh;
 
     memset(&fh, 0, sizeof(fh));
-    
+
     fh.ino = ino;
 
     handle = mc_mkstemps (&ino->localname, me->name, NULL);



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