We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0bca799 commit 1e047eaCopy full SHA for 1e047ea
drivers/block/loop.c
@@ -1103,11 +1103,15 @@ loop_set_status(struct loop_device *lo, const struct loop_info64 *info)
1103
if (info->lo_encrypt_type) {
1104
unsigned int type = info->lo_encrypt_type;
1105
1106
- if (type >= MAX_LO_CRYPT)
1107
- return -EINVAL;
+ if (type >= MAX_LO_CRYPT) {
+ err = -EINVAL;
1108
+ goto exit;
1109
+ }
1110
xfer = xfer_funcs[type];
- if (xfer == NULL)
1111
+ if (xfer == NULL) {
1112
1113
1114
1115
} else
1116
xfer = NULL;
1117
0 commit comments