diff options
-rw-r--r-- | src/gdbmerrno.c | 1 | ||||
-rw-r--r-- | src/gdbmtool.c | 6 | ||||
-rw-r--r-- | src/hash.c | 6 | ||||
-rw-r--r-- | src/lex.l | 4 | ||||
-rw-r--r-- | src/proto.h | 1 | ||||
-rw-r--r-- | src/util.c | 1 |
6 files changed, 11 insertions, 8 deletions
diff --git a/src/gdbmerrno.c b/src/gdbmerrno.c index 50bcaf1..d6e5a31 100644 --- a/src/gdbmerrno.c +++ b/src/gdbmerrno.c @@ -133,6 +133,7 @@ const char * const gdbm_errlist[_GDBM_MAX_ERRNO+1] = { [GDBM_DIR_OVERFLOW] = N_("Bucket directory overflow"), [GDBM_BAD_BUCKET] = N_("Malformed bucket header"), [GDBM_BAD_HEADER] = N_("Malformed database file header"), + /* TRANSLATORS: avail_block is a field name. Don't translate it. */ [GDBM_BAD_AVAIL] = N_("Malformed avail_block"), [GDBM_BAD_HASH_TABLE] = N_("Malformed hash table"), [GDBM_BAD_DIR_ENTRY] = N_("Invalid directory entry"), diff --git a/src/gdbmtool.c b/src/gdbmtool.c index e93e977..20e85ea 100644 --- a/src/gdbmtool.c +++ b/src/gdbmtool.c @@ -311,7 +311,7 @@ _gdbm_print_avail_list (FILE *fp, GDBM_FILE dbf) if (gdbm_avail_block_validate (dbf, av_stk) == 0) av_table_display (av_stk->av_table, av_stk->count, fp); else - terror (_("invalid avail_block")); + terror ("%s", gdbm_strerror (GDBM_BAD_AVAIL)); temp = av_stk->next_block; } free (av_stk); @@ -1228,7 +1228,7 @@ struct command command_tab[] = { { NULL } }, FALSE, REPEAT_NOARG, - N_("nextkey") }, + N_("continue iteration: get next key and datum") }, { S(store), T_CMD, checkdb_begin, store_handler, NULL, { { N_("KEY"), GDBM_ARG_DATUM, DS_KEY }, @@ -1242,7 +1242,7 @@ struct command command_tab[] = { { { NULL } }, FALSE, REPEAT_NEVER, - N_("firstkey") }, + N_("begin iteration: get first key and datum") }, { S(reorganize), T_CMD, checkdb_begin, reorganize_handler, NULL, { { NULL } }, @@ -33,11 +33,11 @@ _gdbm_hash (datum key) int index; /* Used to cycle through random values. */ /* Set the initial value from key. */ - value = 0x238F13AF * key.dsize; + value = 0x238F13AFu * key.dsize; for (index = 0; index < key.dsize; index++) - value = (value + (key.dptr[index] << (index*5 % 24))) & 0x7FFFFFFF; + value = (value + (key.dptr[index] << ((unsigned) index * 5 % 24))) & 0x7FFFFFFF; - value = (1103515243 * value + 12345) & 0x7FFFFFFF; + value = (1103515243u * value + 12345) & 0x7FFFFFFF; /* Return the value. */ return((int) value); @@ -136,11 +136,11 @@ input_context_pop (void) cp = context_tos->parent; free (context_tos); context_tos = cp; + yy_delete_buffer (YY_CURRENT_BUFFER); if (!cp) return 1; - + yylloc = cp->locus; - yy_delete_buffer (YY_CURRENT_BUFFER); yy_switch_to_buffer (cp->buf); return 0; diff --git a/src/proto.h b/src/proto.h index 4ba5cc0..df5d83d 100644 --- a/src/proto.h +++ b/src/proto.h @@ -141,6 +141,7 @@ gdbm_file_sync (GDBM_FILE dbf) GDBM_SET_ERRNO (dbf, GDBM_FILE_SYNC_ERROR, TRUE); return 1; } + return 0; #else sync (); sync (); @@ -95,6 +95,7 @@ vgetyn (const char *prompt, va_list ap) case 'N': return 0; default: + /* TRANSLATORS: Please, don't translate 'y' and 'n'. */ fprintf (stdout, "%s\n", _("Please, reply 'y' or 'n'")); } /* fall through */ |