From 69763672e04d292fd3a53e63e6dfcb44b4eae764 Mon Sep 17 00:00:00 2001 From: fyodor Date: Sat, 11 Aug 2007 04:56:38 +0000 Subject: [PATCH] merge soc07 r5049 - Print a more useful error message if an attempt is made to compare two unknown fingerprint tests. --- osscan.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/osscan.cc b/osscan.cc index a73c7dac8..70fb1610b 100644 --- a/osscan.cc +++ b/osscan.cc @@ -1740,8 +1740,10 @@ static bool FingerTest_lessthan(const FingerTest* a, const FingerTest* b) { return false; } - /* This shouldn't happen. */ - assert(false); + /* If neither test name was recognized, it probably indicates an error in + another part of the code. */ + fatal("%s received two unknown test lines \"%s\" and \"%s\".\n", __func__, + a->name, b->name); /* If neither was in the ordering list, just compare their names. */ return strcmp(a->name, b->name);