[CRIU] [PATCH 3/5] files: Export collect_fd()

Kirill Tkhai ktkhai at virtuozzo.com
Thu Jun 1 04:34:50 PDT 2017


Declare it extern and allow to use outside files.c.

Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
---
 criu/files.c         |    2 +-
 criu/include/files.h |    1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/criu/files.c b/criu/files.c
index 3d997c560..00422be4f 100644
--- a/criu/files.c
+++ b/criu/files.c
@@ -685,7 +685,7 @@ int rst_file_params(int fd, FownEntry *fown, int flags)
 	return 0;
 }
 
-static int collect_fd(int pid, FdinfoEntry *e, struct rst_info *rst_info)
+int collect_fd(int pid, FdinfoEntry *e, struct rst_info *rst_info)
 {
 	struct fdinfo_list_entry *le, *new_le;
 	struct file_desc *fdesc;
diff --git a/criu/include/files.h b/criu/include/files.h
index 075c859d9..5ed33c0cc 100644
--- a/criu/include/files.h
+++ b/criu/include/files.h
@@ -107,6 +107,7 @@ struct file_desc_ops {
 	char *			(*name)(struct file_desc *, char *b, size_t s);
 };
 
+int collect_fd(int pid, FdinfoEntry *e, struct rst_info *rst_info);
 void collect_task_fd(struct fdinfo_list_entry *new_fle, struct rst_info *ri);
 
 unsigned int find_unused_fd(struct pstree_item *, int hint_fd);



More information about the CRIU mailing list