etc/services - sync with NetBSD-8
[minix.git] / minix / lib / libc / sys / loadname.c
bloba4187cd8b591710d181f4d7709e0ae799bb79f0e
1 #include <sys/cdefs.h>
2 #include <lib.h>
3 #include "namespace.h"
5 #include <string.h>
7 void _loadname(const char *name, message *msgptr)
9 /* This function is used to load a string into a type m3 message. If the
10 * string fits in the message, it is copied there. If not, a pointer to
11 * it is passed.
13 register size_t k;
15 k = strlen(name) + 1;
16 msgptr->m_lc_vfs_path.len = k;
17 msgptr->m_lc_vfs_path.name = (vir_bytes)name;
18 if (k <= M_PATH_STRING_MAX) strcpy(msgptr->m_lc_vfs_path.buf, name);