diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2013-05-14 13:25:34 +0000 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2013-05-14 13:25:34 +0000 |
commit | 045ec749566683e9a4471a81901b7a3f37066376 (patch) | |
tree | 8109a733e90282f03ec1d5ed02f6ebaf3e0100e8 | |
parent | c3df0bf5f64241cb7ea00c1894da7f81e055a2aa (diff) | |
download | gdbm-045ec749566683e9a4471a81901b7a3f37066376.tar.gz gdbm-045ec749566683e9a4471a81901b7a3f37066376.tar.bz2 |
Fix distcheck.
-rw-r--r-- | po/POTFILES.in | 5 | ||||
-rw-r--r-- | src/Makefile.am | 2 | ||||
-rw-r--r-- | src/gdbmtool.c | 40 |
3 files changed, 27 insertions, 20 deletions
diff --git a/po/POTFILES.in b/po/POTFILES.in index ce3d71d..d259891 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in | |||
@@ -24,5 +24,8 @@ src/gdbmfetch.c | |||
24 | src/gdbmseq.c | 24 | src/gdbmseq.c |
25 | src/gdbmstore.c | 25 | src/gdbmstore.c |
26 | src/parseopt.c | 26 | src/parseopt.c |
27 | src/testgdbm.c | 27 | src/gdbmtool.c |
28 | src/update.c | 28 | src/update.c |
29 | src/gram.y | ||
30 | src/lex.l | ||
31 | src/datconv.c | ||
diff --git a/src/Makefile.am b/src/Makefile.am index 832fd55..bf2f21e 100644 --- a/src/Makefile.am +++ b/src/Makefile.am | |||
@@ -87,6 +87,8 @@ gdbmtool_SOURCES = \ | |||
87 | gdbmtool.c\ | 87 | gdbmtool.c\ |
88 | var.c | 88 | var.c |
89 | 89 | ||
90 | EXTRA_DIST = gram.h | ||
91 | |||
90 | AM_YFLAGS = -dtv | 92 | AM_YFLAGS = -dtv |
91 | #AM_LFLAGS = -d | 93 | #AM_LFLAGS = -d |
92 | 94 | ||
diff --git a/src/gdbmtool.c b/src/gdbmtool.c index 20c60d8..a561bfc 100644 --- a/src/gdbmtool.c +++ b/src/gdbmtool.c | |||
@@ -399,6 +399,7 @@ struct handler_param | |||
399 | }; | 399 | }; |
400 | 400 | ||
401 | 401 | ||
402 | /* Open database */ | ||
402 | void | 403 | void |
403 | open_handler (struct handler_param *param) | 404 | open_handler (struct handler_param *param) |
404 | { | 405 | { |
@@ -409,6 +410,7 @@ open_handler (struct handler_param *param) | |||
409 | } | 410 | } |
410 | } | 411 | } |
411 | 412 | ||
413 | /* Close database */ | ||
412 | void | 414 | void |
413 | close_handler (struct handler_param *param) | 415 | close_handler (struct handler_param *param) |
414 | { | 416 | { |
@@ -419,7 +421,7 @@ close_handler (struct handler_param *param) | |||
419 | } | 421 | } |
420 | 422 | ||
421 | 423 | ||
422 | /* c - count */ | 424 | /* count - count items in the database */ |
423 | void | 425 | void |
424 | count_handler (struct handler_param *param) | 426 | count_handler (struct handler_param *param) |
425 | { | 427 | { |
@@ -429,7 +431,7 @@ count_handler (struct handler_param *param) | |||
429 | count); | 431 | count); |
430 | } | 432 | } |
431 | 433 | ||
432 | /* d key - delete */ | 434 | /* delete KEY - delete a key*/ |
433 | void | 435 | void |
434 | delete_handler (struct handler_param *param) | 436 | delete_handler (struct handler_param *param) |
435 | { | 437 | { |
@@ -442,7 +444,7 @@ delete_handler (struct handler_param *param) | |||
442 | } | 444 | } |
443 | } | 445 | } |
444 | 446 | ||
445 | /* f key - fetch */ | 447 | /* fetch KEY - fetch a record by its key */ |
446 | void | 448 | void |
447 | fetch_handler (struct handler_param *param) | 449 | fetch_handler (struct handler_param *param) |
448 | { | 450 | { |
@@ -457,7 +459,7 @@ fetch_handler (struct handler_param *param) | |||
457 | fprintf (stderr, _("No such item found.\n")); | 459 | fprintf (stderr, _("No such item found.\n")); |
458 | } | 460 | } |
459 | 461 | ||
460 | /* s key data - store */ | 462 | /* store KEY DATA - store data */ |
461 | void | 463 | void |
462 | store_handler (struct handler_param *param) | 464 | store_handler (struct handler_param *param) |
463 | { | 465 | { |
@@ -467,7 +469,7 @@ store_handler (struct handler_param *param) | |||
467 | fprintf (stderr, _("Item not inserted.\n")); | 469 | fprintf (stderr, _("Item not inserted.\n")); |
468 | } | 470 | } |
469 | 471 | ||
470 | /* 1 - begin iteration */ | 472 | /* first - begin iteration */ |
471 | 473 | ||
472 | void | 474 | void |
473 | firstkey_handler (struct handler_param *param) | 475 | firstkey_handler (struct handler_param *param) |
@@ -490,7 +492,7 @@ firstkey_handler (struct handler_param *param) | |||
490 | fprintf (param->fp, _("No such item found.\n")); | 492 | fprintf (param->fp, _("No such item found.\n")); |
491 | } | 493 | } |
492 | 494 | ||
493 | /* n [key] - next key */ | 495 | /* next [KEY] - next key */ |
494 | void | 496 | void |
495 | nextkey_handler (struct handler_param *param) | 497 | nextkey_handler (struct handler_param *param) |
496 | { | 498 | { |
@@ -523,7 +525,7 @@ nextkey_handler (struct handler_param *param) | |||
523 | } | 525 | } |
524 | } | 526 | } |
525 | 527 | ||
526 | /* r - reorganize */ | 528 | /* reorganize */ |
527 | void | 529 | void |
528 | reorganize_handler (struct handler_param *param ARG_UNUSED) | 530 | reorganize_handler (struct handler_param *param ARG_UNUSED) |
529 | { | 531 | { |
@@ -533,7 +535,7 @@ reorganize_handler (struct handler_param *param ARG_UNUSED) | |||
533 | fprintf (stderr, _("Reorganization succeeded.\n")); | 535 | fprintf (stderr, _("Reorganization succeeded.\n")); |
534 | } | 536 | } |
535 | 537 | ||
536 | /* A - print available list */ | 538 | /* avail - print available list */ |
537 | int | 539 | int |
538 | avail_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) | 540 | avail_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) |
539 | { | 541 | { |
@@ -596,7 +598,7 @@ getnum (int *pnum, char *arg, char **endp) | |||
596 | return 0; | 598 | return 0; |
597 | } | 599 | } |
598 | 600 | ||
599 | /* B num - print a bucket and set is a current one. | 601 | /* bucket NUM - print a bucket and set it as a current one. |
600 | Uses print_current_bucket_handler */ | 602 | Uses print_current_bucket_handler */ |
601 | int | 603 | int |
602 | print_bucket_begin (struct handler_param *param, size_t *exp_count) | 604 | print_bucket_begin (struct handler_param *param, size_t *exp_count) |
@@ -621,7 +623,7 @@ print_bucket_begin (struct handler_param *param, size_t *exp_count) | |||
621 | } | 623 | } |
622 | 624 | ||
623 | 625 | ||
624 | /* D - print hash directory */ | 626 | /* dir - print hash directory */ |
625 | int | 627 | int |
626 | print_dir_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) | 628 | print_dir_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) |
627 | { | 629 | { |
@@ -646,7 +648,7 @@ print_dir_handler (struct handler_param *param) | |||
646 | i, (unsigned long) gdbm_file->dir[i]); | 648 | i, (unsigned long) gdbm_file->dir[i]); |
647 | } | 649 | } |
648 | 650 | ||
649 | /* F - print file handler */ | 651 | /* header - print file handler */ |
650 | int | 652 | int |
651 | print_header_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) | 653 | print_header_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) |
652 | { | 654 | { |
@@ -679,7 +681,7 @@ print_header_handler (struct handler_param *param) | |||
679 | (unsigned long) gdbm_file->header->avail.next_block); | 681 | (unsigned long) gdbm_file->header->avail.next_block); |
680 | } | 682 | } |
681 | 683 | ||
682 | /* H key - hash the key */ | 684 | /* hash KEY - hash the key */ |
683 | void | 685 | void |
684 | hash_handler (struct handler_param *param) | 686 | hash_handler (struct handler_param *param) |
685 | { | 687 | { |
@@ -687,7 +689,7 @@ hash_handler (struct handler_param *param) | |||
687 | _gdbm_hash (param->argv[0]->v.dat)); | 689 | _gdbm_hash (param->argv[0]->v.dat)); |
688 | } | 690 | } |
689 | 691 | ||
690 | /* K - print the bucket cache */ | 692 | /* cache - print the bucket cache */ |
691 | int | 693 | int |
692 | print_cache_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) | 694 | print_cache_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) |
693 | { | 695 | { |
@@ -704,14 +706,14 @@ print_cache_handler (struct handler_param *param) | |||
704 | _gdbm_print_bucket_cache (param->fp, gdbm_file); | 706 | _gdbm_print_bucket_cache (param->fp, gdbm_file); |
705 | } | 707 | } |
706 | 708 | ||
707 | /* V - print GDBM version */ | 709 | /* version - print GDBM version */ |
708 | void | 710 | void |
709 | print_version_handler (struct handler_param *param) | 711 | print_version_handler (struct handler_param *param) |
710 | { | 712 | { |
711 | fprintf (param->fp, "%s\n", gdbm_version); | 713 | fprintf (param->fp, "%s\n", gdbm_version); |
712 | } | 714 | } |
713 | 715 | ||
714 | /* l - List all entries */ | 716 | /* list - List all entries */ |
715 | int | 717 | int |
716 | list_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) | 718 | list_begin (struct handler_param *param ARG_UNUSED, size_t *exp_count) |
717 | { | 719 | { |
@@ -749,7 +751,7 @@ list_handler (struct handler_param *param) | |||
749 | } | 751 | } |
750 | } | 752 | } |
751 | 753 | ||
752 | /* q - quit the program */ | 754 | /* quit - quit the program */ |
753 | void | 755 | void |
754 | quit_handler (struct handler_param *param ARG_UNUSED) | 756 | quit_handler (struct handler_param *param ARG_UNUSED) |
755 | { | 757 | { |
@@ -759,7 +761,7 @@ quit_handler (struct handler_param *param ARG_UNUSED) | |||
759 | exit (EXIT_OK); | 761 | exit (EXIT_OK); |
760 | } | 762 | } |
761 | 763 | ||
762 | /* e file [truncate] - export to a flat file format */ | 764 | /* export FILE [truncate] - export to a flat file format */ |
763 | void | 765 | void |
764 | export_handler (struct handler_param *param) | 766 | export_handler (struct handler_param *param) |
765 | { | 767 | { |
@@ -789,7 +791,7 @@ export_handler (struct handler_param *param) | |||
789 | } | 791 | } |
790 | } | 792 | } |
791 | 793 | ||
792 | /* i file [replace] - import from a flat file */ | 794 | /* import FILE [replace] [nometa] - import from a flat file */ |
793 | void | 795 | void |
794 | import_handler (struct handler_param *param) | 796 | import_handler (struct handler_param *param) |
795 | { | 797 | { |
@@ -857,7 +859,7 @@ import_handler (struct handler_param *param) | |||