Return to tildexpand.c CVS log | Up to [local] / src / usr.bin / ssh |
version 1.8, 2000/09/07 20:27:55 | version 1.8.2.4, 2001/05/07 21:09:38 | ||
---|---|---|---|
|
|
||
RCSID("$OpenBSD$"); | RCSID("$OpenBSD$"); | ||
#include "xmalloc.h" | #include "xmalloc.h" | ||
#include "ssh.h" | #include "log.h" | ||
#include "tildexpand.h" | |||
/* | /* | ||
* Expands tildes in the file name. Returns data allocated by xmalloc. | * Expands tildes in the file name. Returns data allocated by xmalloc. | ||
|
|
||
tilde_expand_filename(const char *filename, uid_t my_uid) | tilde_expand_filename(const char *filename, uid_t my_uid) | ||
{ | { | ||
const char *cp; | const char *cp; | ||
unsigned int userlen; | u_int userlen; | ||
char *expanded; | char *expanded; | ||
struct passwd *pw; | struct passwd *pw; | ||
char user[100]; | char user[100]; |