diff --git a/cg/cg6901.cpp b/cg/cg6901.cpp index ddb950819..6ee6e5862 100755 --- a/cg/cg6901.cpp +++ b/cg/cg6901.cpp @@ -157,14 +157,14 @@ bool TLista_archivi::set() bool TLista_archivi::controlla_valore(const TString& val,int lim, int len) { - if (val.len() > len) - return FALSE; if (real::is_natural(val)) { - int app = atoi(val); - if (app > lim) + if (atoi(val) > lim) return FALSE; } + else + if (val.len() > len) + return FALSE; return TRUE; }