Was going to decline the work anyway. I don't like solving puzzles just to be solving them so i would be unhappy untangling that spaghetti code. I prefer to write my own
Probably the right decision, I have done this on a similar sized project, it takes forever. You have to convert the bits you are working on as you go along otherwise you run the risk of breaking it. This can take many times as long to do so you need your employer to agree that this is going to happen otherwise you have no chance.
The converted project is still running after 5 years and is much improved but I still find bits that have never changed.
+++edit+++ Looking at the style of the code, it seems somewhat 'low level'. Maybe the developer was from an assembly language background?
Not necessarily true. The example is original K&R C which had a limitation on symbol name length of 8 characters so everybody used cryptic names back then. Almost all C code looked like that.
You could use longer names but only the first 8 characters were counted so you ran the risk of mixing variable names up and not realize.
May be the only available compiler is that old.
Non ANSI C still compiles in C99, or at least the example here still does. The only major difference is the parameter definitions appearing before the { and that still works. Probably the next problem are the differences in what is determined to be undefined behaviour.
No takers to re-implement the code example?
If you don't care what the exit value is then you could just replace it with something like
ULONG strlen = 10;
sprintf(strp, "%10ld", bind);
However if you care about the number of digits in the decimal number then you have to re-write the existing function.
Also you might have a dynamically sized buffer which is a problem for the format string "%10ld"