[pve-devel] applied: [PATCH pve-manager 1/1] fix #2634: if hook-script without permission, prints message, that the script not executable
Thomas Lamprecht
t.lamprecht at proxmox.com
Thu Mar 12 17:48:37 CET 2020
On 3/12/20 12:29 PM, Oguz Bektas wrote:
> hi,
>
> works fine. also tested with symlinks.
> i'd remove the extra whitespace near the end though.
>
> Tested-by: Oguz Bektas <o.bektas at proxmox.com>
>
With your T-b tag: applied
But yes, FYI, i followed up and dropped some extra empty newlines, fixed
indentation of the "die ..." and added a missing semicolon there.
Thanks!
> On Thu, Mar 12, 2020 at 12:18:18PM +0100, Moayad Almalat wrote:
>> Signed-off-by: Moayad Almalat <m.almalat at proxmox.com>
>> ---
>> PVE/VZDump.pm | 6 ++++++
>> 1 file changed, 6 insertions(+)
>>
>> diff --git a/PVE/VZDump.pm b/PVE/VZDump.pm
>> index ada3681e..5f7f7725 100644
>> --- a/PVE/VZDump.pm
>> +++ b/PVE/VZDump.pm
>> @@ -571,6 +571,12 @@ sub run_hook_script {
>>
>> return if !$script;
>>
>> + if (!-x $script) {
>> + die "The hook-script '$script' is not executable.\n"
>> + }
>> +
>> +
>> +
>> my $cmd = "$script $phase";
>>
>> $cmd .= " $task->{mode} $task->{vmid}" if ($task);
>> --
>> 2.20.1
>>
More information about the pve-devel
mailing list