From f35fd3d5eeb3e35660ea87adbc170978c3cdf9e3 Mon Sep 17 00:00:00 2001 From: Theodore Ts'o Date: Mon, 9 May 2005 16:22:17 -0400 Subject: [PATCH] Fix some minor typo's and grammar's strings, and remove debugging strings from needing to be translated. Patch is from Benno Schulenberg. --- misc/ChangeLog | 7 +++++++ misc/chattr.c | 2 +- misc/tune2fs.c | 2 +- resize/ChangeLog | 8 ++++++++ resize/main.c | 5 +++-- resize/resize2fs.c | 25 ++++++++++++------------- 6 files changed, 32 insertions(+), 17 deletions(-) diff --git a/misc/ChangeLog b/misc/ChangeLog index 67dec48f..5399e735 100644 --- a/misc/ChangeLog +++ b/misc/ChangeLog @@ -1,3 +1,10 @@ +2005-05-09 Theodore Ts'o + + * tune2fs.c (main): Fix grammar in message printed when setting + the check interval (tune2fs -i) + + * chattr.c: Fix case on usage message. + 2005-05-07 Theodore Ts'o * blkid.c (main): Use the new functions blkid_dev_set_search() and diff --git a/misc/chattr.c b/misc/chattr.c index bb968646..0b800ef1 100644 --- a/misc/chattr.c +++ b/misc/chattr.c @@ -84,7 +84,7 @@ static void fatal_error(const char * fmt_string, int errcode) exit (errcode); } -#define usage() fatal_error(_("usage: %s [-RV] [-+=AacDdijsSu] [-v version] files...\n"), \ +#define usage() fatal_error(_("Usage: %s [-RV] [-+=AacDdijsSu] [-v version] files...\n"), \ 1) struct flags_char { diff --git a/misc/tune2fs.c b/misc/tune2fs.c index e0d7dd67..83851870 100644 --- a/misc/tune2fs.c +++ b/misc/tune2fs.c @@ -819,7 +819,7 @@ int main (int argc, char ** argv) if (i_flag) { sb->s_checkinterval = interval; ext2fs_mark_super_dirty(fs); - printf (_("Setting interval between check %lu seconds\n"), interval); + printf (_("Setting interval between checks to %lu seconds\n"), interval); } if (m_flag) { sb->s_r_blocks_count = (sb->s_blocks_count / 100) diff --git a/resize/ChangeLog b/resize/ChangeLog index f51550a4..b2df47f2 100644 --- a/resize/ChangeLog +++ b/resize/ChangeLog @@ -1,3 +1,11 @@ +2005-05-09 Theodore Ts'o + + * resize2fs.c (fix_resize_inode): Don't bother to translate + debugging printf's. + + * main.c: Fix case on usage message, and remove _() from messages + from a version string that doesn't need translation. + 2005-03-21 Theodore Ts'o * Release of E2fsprogs 1.37 diff --git a/resize/main.c b/resize/main.c index 46c2d6c4..f4abf3ae 100644 --- a/resize/main.c +++ b/resize/main.c @@ -31,7 +31,8 @@ char *program_name, *device_name, *io_options; static void usage (char *prog) { - fprintf (stderr, _("usage: %s [-d debug_flags] [-f] [-F] [-p] device [new-size]\n\n"), prog); + fprintf (stderr, _("Usage: %s [-d debug_flags] [-f] [-F] [-p] " + "device [new_size]\n\n"), prog); exit (1); } @@ -135,7 +136,7 @@ int main (int argc, char ** argv) initialize_ext2_error_table(); - fprintf (stderr, _("resize2fs %s (%s)\n"), + fprintf (stderr, "resize2fs %s (%s)\n", E2FSPROGS_VERSION, E2FSPROGS_DATE); if (argc && *argv) program_name = *argv; diff --git a/resize/resize2fs.c b/resize/resize2fs.c index 9356d067..fd14c840 100644 --- a/resize/resize2fs.c +++ b/resize/resize2fs.c @@ -108,7 +108,7 @@ errcode_t resize_fs(ext2_filsys fs, blk_t *new_size, int flags, #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_BMOVE) - printf(_("Number of free blocks: %d/%d, Needed: %d\n"), + printf("Number of free blocks: %d/%d, Needed: %d\n", rfs->old_fs->super->s_free_blocks_count, rfs->new_fs->super->s_free_blocks_count, rfs->needed_blocks); @@ -816,8 +816,8 @@ static blk_t get_new_block(ext2_resize_t rfs) #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_BMOVE) - printf(_("Going into desperation " - "mode for block allocations\n")); + printf("Going into desperation mode " + "for block allocations\n"); #endif rfs->alloc_state = DESPERATION; rfs->new_blk = fs->super->s_first_data_block; @@ -920,8 +920,8 @@ static errcode_t block_mover(ext2_resize_t rfs) break; #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_BMOVE) - printf(_("Moving %d blocks %u->%u\n"), size, - old_blk, new_blk); + printf("Moving %d blocks %u->%u\n", + size, old_blk, new_blk); #endif do { c = size; @@ -997,7 +997,7 @@ static int process_block(ext2_filsys fs, blk_t *block_nr, pb->changed = 1; #ifdef RESIZE2FS_DEBUG if (pb->rfs->flags & RESIZE_DEBUG_BMOVE) - printf(_("ino=%u, blockcnt=%lld, %u->%u\n"), + printf("ino=%u, blockcnt=%lld, %u->%u\n", pb->ino, blockcnt, block, new_block); #endif block = new_block; @@ -1165,7 +1165,7 @@ static errcode_t inode_scan_and_fix(ext2_resize_t rfs) #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_INODEMAP) - printf(_("Inode moved %u->%u\n"), ino, new_inode); + printf("Inode moved %u->%u\n", ino, new_inode); #endif if (!rfs->imap) { retval = ext2fs_create_extent_table(&rfs->imap, 0); @@ -1233,7 +1233,7 @@ static int check_and_change_inodes(ext2_ino_t dir, return 0; #ifdef RESIZE2FS_DEBUG if (is->rfs->flags & RESIZE_DEBUG_INODEMAP) - printf(_("Inode translate (dir=%u, name=%.*s, %u->%u)\n"), + printf("Inode translate (dir=%u, name=%.*s, %u->%u)\n", dir, dirent->name_len&0xFF, dirent->name, dirent->inode, new_inode); #endif @@ -1360,8 +1360,7 @@ static errcode_t move_itables(ext2_resize_t rfs) #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_ITABLEMOVE) - printf(_("Itable move group %d block " - "%u->%u (diff %d)\n"), + printf("Itable move group %d block %u->%u (diff %d)\n", i, old_blk, new_blk, diff); #endif @@ -1386,7 +1385,7 @@ static errcode_t move_itables(ext2_resize_t rfs) n = n >> EXT2_BLOCK_SIZE_BITS(fs->super); #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_ITABLEMOVE) - printf(_("%d blocks of zeros...\n"), n); + printf("%d blocks of zeros...\n", n); #endif num = fs->inode_blocks_per_group; if (n > diff) @@ -1428,7 +1427,7 @@ static errcode_t move_itables(ext2_resize_t rfs) ext2fs_flush(fs); #ifdef RESIZE2FS_DEBUG if (rfs->flags & RESIZE_DEBUG_ITABLEMOVE) - printf(_("Inode table move finished.\n")); + printf("Inode table move finished.\n"); #endif return 0; @@ -1467,7 +1466,7 @@ static errcode_t fix_resize_inode(ext2_filsys fs) * should be fsck'ed and we assume it is consistent. */ fprintf(stderr, - _("Should never happen resize inode corrupt!\n")); + _("Should never happen: resize inode corrupt!\n")); exit(1); }