Commit 86854189 authored by rswindell's avatar rswindell
Browse files

Changed order of function definition: ahtoul

parent d71bd5b1
......@@ -380,6 +380,19 @@ char *hexplus(uint num, char *str)
return(str);
}
/****************************************************************************/
/* Converts an ASCII Hex string into an ulong */
/* by Steve Deppe (Ille Homine Albe) */
/****************************************************************************/
ulong ahtoul(char *str)
{
ulong l,val=0;
while((l=(*str++)|0x20)!=0x20)
val=(l&0xf)+(l>>6&1)*9+val*16;
return(val);
}
uint hptoi(char *str)
{
char tmp[128];
......@@ -393,16 +406,4 @@ uint hptoi(char *str)
return(i);
}
/****************************************************************************/
/* Converts an ASCII Hex string into an ulong */
/* by Steve Deppe (Ille Homine Albe) */
/****************************************************************************/
ulong ahtoul(char *str)
{
ulong l,val=0;
while((l=(*str++)|0x20)!=0x20)
val=(l&0xf)+(l>>6&1)*9+val*16;
return(val);
}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment