Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 23rd, 2012  |  syntax: C  |  size: 0.20 KB  |  hits: 49  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. #include "string.h"
  2.  
  3. unsigned long hexstr2ulong(const char* s, const char **p)
  4. {
  5.         *p = &s[2];
  6.         return 0;
  7. }
  8.  
  9. int main()
  10. {
  11.         const char * s = "Tralalii";
  12.         const char *p; 
  13.         hexstr2ulong(s, &p);
  14. }