I am dealing with an old language for the front end to a c program. I am running into coredumps when I pass a float that has more than 4 digits after the decimal.

To get around this, I did the following:

passRt=(int)(combRt*10000)

where passRt is an int being passed back to the calling function, and combRt is a float.

Then once the passRt value is back in the calling function, I

LET floatPassRt=passRt/10000

and end up with a 4 digit precision float.

Problem is, this is messing with the rounding.

Without having to write an extensive rounding function (tax logic and all), is there a way that I can actually set a varible to be a 4 digit precision float in C?

thanks!!