aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/fs/fs_namespace.c14
-rw-r--r--src/include/gnunet_fs_service.h10
2 files changed, 24 insertions, 0 deletions
diff --git a/src/fs/fs_namespace.c b/src/fs/fs_namespace.c
index ec4e2495a..9cb8cd5a4 100644
--- a/src/fs/fs_namespace.c
+++ b/src/fs/fs_namespace.c
@@ -520,6 +520,20 @@ GNUNET_FS_namespace_create (struct GNUNET_FS_Handle *h, const char *name)
520 520
521 521
522/** 522/**
523 * Duplicate a namespace handle.
524 *
525 * @param ns namespace handle
526 * @return duplicated handle to the namespace
527 */
528struct GNUNET_FS_Namespace *
529GNUNET_FS_namespace_dup (struct GNUNET_FS_Namespace *ns)
530{
531 ns->rc++;
532 return ns;
533}
534
535
536/**
523 * Delete a namespace handle. Can be used for a clean shutdown (free 537 * Delete a namespace handle. Can be used for a clean shutdown (free
524 * memory) or also to freeze the namespace to prevent further 538 * memory) or also to freeze the namespace to prevent further
525 * insertions by anyone. 539 * insertions by anyone.
diff --git a/src/include/gnunet_fs_service.h b/src/include/gnunet_fs_service.h
index bfaa98364..0c739709d 100644
--- a/src/include/gnunet_fs_service.h
+++ b/src/include/gnunet_fs_service.h
@@ -2157,6 +2157,16 @@ GNUNET_FS_namespace_create (struct GNUNET_FS_Handle *h, const char *name);
2157 2157
2158 2158
2159/** 2159/**
2160 * Duplicate a namespace handle.
2161 *
2162 * @param ns namespace handle
2163 * @return duplicated handle to the namespace
2164 */
2165struct GNUNET_FS_Namespace *
2166GNUNET_FS_namespace_dup (struct GNUNET_FS_Namespace *ns);
2167
2168
2169/**
2160 * Delete a namespace handle. Can be used for a clean shutdown (free 2170 * Delete a namespace handle. Can be used for a clean shutdown (free
2161 * memory) or also to freeze the namespace to prevent further 2171 * memory) or also to freeze the namespace to prevent further
2162 * insertions by anyone. 2172 * insertions by anyone.