home-expand.c revision a8c5a86d183db25a57bf193c06b41e092ec2e151
/* Copyright (c) 2003-2014 Dovecot authors, see the included COPYING file */
#include "lib.h"
#include "ipwd.h"
#include "home-expand.h"
#include <stdlib.h>
int home_try_expand(const char **_path)
{
return 0;
path++;
} else {
if (p == NULL) {
path = "";
} else {
path = p+1;
}
case -1:
break;
case 0:
break;
default:
break;
}
}
return -1;
if (*path == '\0')
else
return 0;
}
const char *home_expand(const char *path)
{
(void)home_try_expand(&path);
return path;
}
{
return path;
return home;
return path;
/* ~/ used */
}