From 0f8ec41b0ae522b73085fa1662461e6351ba7e54 Mon Sep 17 00:00:00 2001 From: rsc Date: Sun, 13 Feb 2005 05:58:45 +0000 Subject: moving to auth --- src/cmd/factotum/util.c | 54 ------------------------------------------------- 1 file changed, 54 deletions(-) delete mode 100644 src/cmd/factotum/util.c (limited to 'src/cmd/factotum/util.c') diff --git a/src/cmd/factotum/util.c b/src/cmd/factotum/util.c deleted file mode 100644 index accddddd..00000000 --- a/src/cmd/factotum/util.c +++ /dev/null @@ -1,54 +0,0 @@ -#include "std.h" -#include "dat.h" - -static int -unhex(char c) -{ - if('0' <= c && c <= '9') - return c-'0'; - if('a' <= c && c <= 'f') - return c-'a'+10; - if('A' <= c && c <= 'F') - return c-'A'+10; - abort(); - return -1; -} - -int -hexparse(char *hex, uchar *dat, int ndat) -{ - int i, n; - - n = strlen(hex); - if(n%2) - return -1; - n /= 2; - if(n > ndat) - return -1; - if(hex[strspn(hex, "0123456789abcdefABCDEF")] != '\0') - return -1; - for(i=0; i