masqmail-0.2
diff src/base64/base64dec.c @ 0:08114f7dcc23
this is masqmail-0.2.21 from oliver kurth
author | meillo@marmaro.de |
---|---|
date | Fri, 26 Sep 2008 17:05:23 +0200 |
parents | |
children | 26e34ae9a3e3 |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/src/base64/base64dec.c Fri Sep 26 17:05:23 2008 +0200 1.3 @@ -0,0 +1,19 @@ 1.4 +#include <glib.h> 1.5 +#include <stdio.h> 1.6 +#include <stdlib.h> 1.7 + 1.8 +#include "base64.h" 1.9 + 1.10 +int main() 1.11 +{ 1.12 + gchar line[100]; 1.13 + gchar *buf; 1.14 + gint size; 1.15 + 1.16 + while(fgets(line, 100, stdin)){ 1.17 + buf = base64_decode(line, &size); 1.18 + fwrite(buf, size, 1, stdout); 1.19 + g_free(buf); 1.20 + } 1.21 + exit(0); 1.22 +}