[CRIU] [PATCH 08/15] image-desc: Use unsigned format for netdev

Cyrill Gorcunov gorcunov at openvz.org
Wed Oct 25 11:39:33 MSK 2017


Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
---
 criu/image-desc.c | 2 +-
 criu/net.c        | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/criu/image-desc.c b/criu/image-desc.c
index b5b55941d66f..6b1f5a007a24 100644
--- a/criu/image-desc.c
+++ b/criu/image-desc.c
@@ -68,7 +68,7 @@ struct cr_fd_desc_tmpl imgset_template[CR_FD_MAX] = {
 	FD_ENTRY_F(GHOST_FILE,	"ghost-file-%x", O_NOBUF),
 	FD_ENTRY(TCP_STREAM,	"tcp-stream-%x"),
 	FD_ENTRY(MNTS,		"mountpoints-%u"),
-	FD_ENTRY(NETDEV,	"netdev-%d"),
+	FD_ENTRY(NETDEV,	"netdev-%u"),
 	FD_ENTRY(NETNS,		"netns-%d"),
 	FD_ENTRY_F(IFADDR,	"ifaddr-%d", O_NOBUF),
 	FD_ENTRY_F(ROUTE,	"route-%d", O_NOBUF),
diff --git a/criu/net.c b/criu/net.c
index 618909eeaf76..5f2c627da5f4 100644
--- a/criu/net.c
+++ b/criu/net.c
@@ -1532,7 +1532,8 @@ static int __restore_link(struct ns_id *ns, struct net_link *link, int nlsk)
 
 static int read_links(struct ns_id *ns)
 {
-	int ret = -1, id = ns->id;
+	int ret = -1;
+	unsigned int id = ns->id;
 	struct cr_img *img;
 	NetDeviceEntry *nde;
 
-- 
2.7.5



More information about the CRIU mailing list