diff --git a/include/dongle.cpp b/include/dongle.cpp index 3f172aac9..615612aee 100755 --- a/include/dongle.cpp +++ b/include/dongle.cpp @@ -1375,23 +1375,18 @@ int Tdninst::check_customer() const if (em.ok() && em.year_assist() > 2100 && em.find_serno(serno)) { error = 0; - const TDate oggi(TODAY); TToken_string l(80, '='); - TString16 str; - TDate ds; while (em.line(l) && error == 0) { if (l.empty() || l[0] == '[') break; - if (parse_date(l, str, ds)) + if (l[0]=='*' || l.starts_with("MustCall")) { - if (ds >= oggi) - { - if (str == "*") - error = 2; else - if (str == "MustCall") - error = 1; - } + const TDate oggi(TODAY); + TString16 str; + TDate ds; + if (parse_date(l, str, ds) && oggi >= ds) + error = (l[0] == '*') ? 2 : 1; } } }