Mail Archives: djgpp/1996/12/12/23:43:24
ff AT kom DOT auc DOT dk (Frank Frederiksen) wrote:
>
>When we symify the program the first two lines are:
>__doprnt+1432
>_fprintf+105
>
>So, is there a (simple)way of detecting if a floating point number
>is legal, before printing it, or do we have to investigate the
>numbers individually to see if they are valid numbers?
>
i would assume that if trying to print a floating point number gives an
error, the comparison you would make would also be unreliable.
i would concentrate my effort on making sure the receiving program
accepts only uncorrupted data. this does not mean examining individual numbers
but using some sort of mechanism (like checksums) to ensure the integrity
of the data your receive, and do a re-transmit if necessary.
i am no expert on the subject. i recall that the author of kermit had a
very good article which might prove to be useful. it was in dr dobbs
journal (http://www.ddj..com) (if you need the reference, i can try to
find the magazine.)
sinan.
- Raw text -