X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=vtep%2Fvtep-ctl.c;h=25470ff1ca89e45fe41cbb1589fafe333e6adb61;hb=3ba9c6a5a5468626dcfeb1f9a750bb0efc8c6a7a;hp=7b904f625730f72a9c6ffd8ef6ac5927be765fa7;hpb=ffc759c62a37dbf286f0f54577754fabd907234d;p=sliver-openvswitch.git diff --git a/vtep/vtep-ctl.c b/vtep/vtep-ctl.c index 7b904f625..25470ff1c 100644 --- a/vtep/vtep-ctl.c +++ b/vtep/vtep-ctl.c @@ -31,6 +31,7 @@ #include "compiler.h" #include "dirs.h" #include "dynamic-string.h" +#include "fatal-signal.h" #include "hash.h" #include "json.h" #include "ovsdb-data.h" @@ -167,7 +168,7 @@ main(int argc, char *argv[]) char *args; set_program_name(argv[0]); - signal(SIGPIPE, SIG_IGN); + fatal_ignore_sigpipe(); vlog_set_levels(NULL, VLF_CONSOLE, VLL_WARN); vlog_set_levels(&VLM_reconnect, VLF_ANY_FACILITY, VLL_WARN); vteprec_init(); @@ -369,6 +370,7 @@ parse_options(int argc, char *argv[], struct shash *local_options) case 'V': ovs_print_version(0, 0); + printf("DB Schema %s\n", vteprec_get_db_version()); exit(EXIT_SUCCESS); case 't': @@ -3324,7 +3326,7 @@ post_create(struct vtep_ctl_context *ctx) struct uuid dummy; if (!uuid_from_string(&dummy, ds_cstr(&ctx->output))) { - NOT_REACHED(); + OVS_NOT_REACHED(); } real = ovsdb_idl_txn_get_insert_uuid(ctx->txn, &dummy); if (real) { @@ -3441,7 +3443,7 @@ evaluate_relop(const struct ovsdb_datum *a, const struct ovsdb_datum *b, return ovsdb_datum_includes_all(b, a, type); default: - NOT_REACHED(); + OVS_NOT_REACHED(); } } @@ -3739,7 +3741,7 @@ do_vtep_ctl(const char *args, struct vtep_ctl_command *commands, switch (status) { case TXN_UNCOMMITTED: case TXN_INCOMPLETE: - NOT_REACHED(); + OVS_NOT_REACHED(); case TXN_ABORTED: /* Should not happen--we never call ovsdb_idl_txn_abort(). */ @@ -3760,7 +3762,7 @@ do_vtep_ctl(const char *args, struct vtep_ctl_command *commands, vtep_ctl_fatal("database not locked"); default: - NOT_REACHED(); + OVS_NOT_REACHED(); } free(error);