Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion criu/cr-service.c
Original file line number Diff line number Diff line change
Expand Up @@ -674,7 +674,7 @@ static int setup_opts_from_req(int sk, CriuOpts *req)
}

/*
* open images_dir - images_dir_fd is a required RPC parameter
* open images_dir - images_dir_fd is -1 by default
*
* This assumes that if opts.imgs_dir is set we have a value
* from the configuration file parser. The test to see that
Expand Down
2 changes: 1 addition & 1 deletion images/rpc.proto
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ enum criu_pre_dump_mode {
};

message criu_opts {
required int32 images_dir_fd = 1 [default = -1];
optional int32 images_dir_fd = 1 [default = -1];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change is likely to break existing users:
https://protobuf.dev/programming-guides/proto2/#required-deprecated

Copy link
Member Author

@herheliuk herheliuk Oct 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can hardcode req.opts.images_dir_fd = self.opts.images_dir_fd on every request, (in pycriu)
but it won't be that pretty.

I'm down for any solution, just to fix this inconvenience (and realistically barrier for newbies).

optional string images_dir = 68; /* used only if images_dir_fd == -1 */
optional int32 pid = 2; /* if not set on dump, will dump requesting process */

Expand Down
Loading