mirror of
https://github.com/apache/nuttx.git
synced 2026-05-30 05:16:47 +08:00
net/local: rename NET_LOCAL_VFS_PATH to follow linux
And skip same prefix for unix path Signed-off-by: dongjiuzhu1 <dongjiuzhu1@xiaomi.com>
This commit is contained in:
+1
-1
@@ -17,7 +17,7 @@ if NET_LOCAL
|
|||||||
|
|
||||||
config NET_LOCAL_VFS_PATH
|
config NET_LOCAL_VFS_PATH
|
||||||
string "Path prefix to Unix domain sockets"
|
string "Path prefix to Unix domain sockets"
|
||||||
default "/var/socket"
|
default "/var/run"
|
||||||
---help---
|
---help---
|
||||||
The path prefix to where Unix domain sockets will exist in the VFS namespace.
|
The path prefix to where Unix domain sockets will exist in the VFS namespace.
|
||||||
|
|
||||||
|
|||||||
@@ -66,6 +66,11 @@
|
|||||||
static void local_format_name(FAR const char *inpath, FAR char *outpath,
|
static void local_format_name(FAR const char *inpath, FAR char *outpath,
|
||||||
FAR const char *suffix, int32_t id)
|
FAR const char *suffix, int32_t id)
|
||||||
{
|
{
|
||||||
|
if (strcmp(inpath, CONFIG_NET_LOCAL_VFS_PATH) == 0)
|
||||||
|
{
|
||||||
|
inpath += strlen(CONFIG_NET_LOCAL_VFS_PATH);
|
||||||
|
}
|
||||||
|
|
||||||
if (id < 0)
|
if (id < 0)
|
||||||
{
|
{
|
||||||
snprintf(outpath, LOCAL_FULLPATH_LEN - 1,
|
snprintf(outpath, LOCAL_FULLPATH_LEN - 1,
|
||||||
|
|||||||
Reference in New Issue
Block a user