version 1.19, 2014/05/20 01:25:23 |
version 1.20, 2015/01/16 06:40:13 |
|
|
* Used with uuencode. |
* Used with uuencode. |
*/ |
*/ |
|
|
#include <sys/param.h> |
|
#include <sys/socket.h> |
#include <sys/socket.h> |
#include <sys/stat.h> |
#include <sys/stat.h> |
|
|
|
|
#include <stdlib.h> |
#include <stdlib.h> |
#include <string.h> |
#include <string.h> |
#include <unistd.h> |
#include <unistd.h> |
|
#include <limits.h> |
|
|
static const char *infile, *outfile; |
static const char *infile, *outfile; |
static FILE *infp, *outfp; |
static FILE *infp, *outfp; |
|
|
void *handle; |
void *handle; |
struct passwd *pw; |
struct passwd *pw; |
struct stat st; |
struct stat st; |
char buf[MAXPATHLEN]; |
char buf[PATH_MAX]; |
|
|
base64 = 0; |
base64 = 0; |
/* search for header line */ |
/* search for header line */ |
|
|
{ |
{ |
int i, ch; |
int i, ch; |
char *p; |
char *p; |
char buf[MAXPATHLEN]; |
char buf[PATH_MAX]; |
|
|
/* for each input line */ |
/* for each input line */ |
for (;;) { |
for (;;) { |
|
|
base64_decode(void) |
base64_decode(void) |
{ |
{ |
int n; |
int n; |
char inbuf[MAXPATHLEN]; |
char inbuf[PATH_MAX]; |
unsigned char outbuf[MAXPATHLEN * 4]; |
unsigned char outbuf[PATH_MAX * 4]; |
|
|
for (;;) { |
for (;;) { |
switch (get_line(inbuf, sizeof(inbuf))) { |
switch (get_line(inbuf, sizeof(inbuf))) { |