UnitFileChange *changes = NULL;
size_t n_changes = 0;
Manager *m = userdata;
- UnitFilePresetMode mm;
+ UnitFilePresetMode preset_mode;
int runtime, force, r;
UnitFileFlags flags;
const char *mode;
flags = unit_file_bools_to_flags(runtime, force);
if (isempty(mode))
- mm = UNIT_FILE_PRESET_FULL;
+ preset_mode = UNIT_FILE_PRESET_FULL;
else {
- mm = unit_file_preset_mode_from_string(mode);
- if (mm < 0)
+ preset_mode = unit_file_preset_mode_from_string(mode);
+ if (preset_mode < 0)
return -EINVAL;
}
if (r == 0)
return 1; /* No authorization for now, but the async polkit stuff will call us again when it has it */
- r = unit_file_preset(m->unit_file_scope, flags, NULL, l, mm, &changes, &n_changes);
+ r = unit_file_preset(m->unit_file_scope, flags, NULL, l, preset_mode, &changes, &n_changes);
if (r < 0)
return install_error(error, r, changes, n_changes);
UnitFileChange *changes = NULL;
size_t n_changes = 0;
Manager *m = userdata;
- UnitFilePresetMode mm;
+ UnitFilePresetMode preset_mode;
const char *mode;
UnitFileFlags flags;
int force, runtime, r;
flags = unit_file_bools_to_flags(runtime, force);
if (isempty(mode))
- mm = UNIT_FILE_PRESET_FULL;
+ preset_mode = UNIT_FILE_PRESET_FULL;
else {
- mm = unit_file_preset_mode_from_string(mode);
- if (mm < 0)
+ preset_mode = unit_file_preset_mode_from_string(mode);
+ if (preset_mode < 0)
return -EINVAL;
}
if (r == 0)
return 1; /* No authorization for now, but the async polkit stuff will call us again when it has it */
- r = unit_file_preset_all(m->unit_file_scope, flags, NULL, mm, &changes, &n_changes);
+ r = unit_file_preset_all(m->unit_file_scope, flags, NULL, preset_mode, &changes, &n_changes);
if (r < 0)
return install_error(error, r, changes, n_changes);