# HG changeset patch # User Mychaela Falconia # Date 1500151651 0 # Node ID 1d3dd589a85744fb204d3e04cb3784199380f368 # Parent 3f63e71b6422be19cf3566cd2a4e57132ebb9729 fc-rfcal-txband: implemented check for increasing basis points diff -r 3f63e71b6422 -r 1d3dd589a857 autocal/txcalconf.c --- a/autocal/txcalconf.c Sat Jul 15 20:25:31 2017 +0000 +++ b/autocal/txcalconf.c Sat Jul 15 20:47:31 2017 +0000 @@ -47,6 +47,12 @@ exit(ERROR_USAGE); } tx_basis[n].apc = atoi(cp); + if (n && tx_basis[n].apc <= tx_basis[n-1].apc) { + fprintf(stderr, + "%s line %d: basis points must be increasing\n", + filename_for_errs, lineno); + exit(ERROR_USAGE); + } while (isdigit(*cp)) cp++; }