From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <f.schauer@proxmox.com>
Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68])
 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
 key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256)
 (No client certificate requested)
 by lists.proxmox.com (Postfix) with ESMTPS id 870E3906B5
 for <pbs-devel@lists.proxmox.com>; Wed, 24 Jan 2024 11:19:42 +0100 (CET)
Received: from firstgate.proxmox.com (localhost [127.0.0.1])
 by firstgate.proxmox.com (Proxmox) with ESMTP id 7257DA191
 for <pbs-devel@lists.proxmox.com>; Wed, 24 Jan 2024 11:19:42 +0100 (CET)
Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com
 [94.136.29.106])
 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
 key-exchange X25519 server-signature RSA-PSS (2048 bits))
 (No client certificate requested)
 by firstgate.proxmox.com (Proxmox) with ESMTPS
 for <pbs-devel@lists.proxmox.com>; Wed, 24 Jan 2024 11:19:41 +0100 (CET)
Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1])
 by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 08CCE415B1
 for <pbs-devel@lists.proxmox.com>; Wed, 24 Jan 2024 11:19:41 +0100 (CET)
Message-ID: <d1be43b3-ede1-465a-a5df-4f16112d231d@proxmox.com>
Date: Wed, 24 Jan 2024 11:19:40 +0100
MIME-Version: 1.0
User-Agent: Mozilla Thunderbird
To: Wolfgang Bumiller <w.bumiller@proxmox.com>
Cc: pbs-devel@lists.proxmox.com
References: <20231214144824.100616-1-f.schauer@proxmox.com>
 <20231214144824.100616-3-f.schauer@proxmox.com>
 <ccc4uaslsrj67zrjeixmjwvofnqos4vuyp5e3a6niljmaovr4e@wl4dq2mjueiv>
 <086153c2-0458-409d-a241-2a2b02bbbb34@proxmox.com>
 <s453pl75cudevel6hkdewhxajeccderpc6vonaes77u42egxlt@sjjwnczhzphl>
Content-Language: en-US
From: Filip Schauer <f.schauer@proxmox.com>
In-Reply-To: <s453pl75cudevel6hkdewhxajeccderpc6vonaes77u42egxlt@sjjwnczhzphl>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
X-SPAM-LEVEL: Spam detection results:  0
 AWL -0.126 Adjusted score from AWL reputation of From: address
 BAYES_00                 -1.9 Bayes spam probability is 0 to 1%
 DMARC_MISSING             0.1 Missing DMARC policy
 KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment
 SPF_HELO_NONE           0.001 SPF: HELO does not publish an SPF Record
 SPF_PASS               -0.001 SPF: sender matches SPF record
 T_SCC_BODY_TEXT_LINE    -0.01 -
Subject: Re: [pbs-devel] [PATCH v3 proxmox 2/3] compression: Add support for
 symlinks in zip files
X-BeenThere: pbs-devel@lists.proxmox.com
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Proxmox Backup Server development discussion
 <pbs-devel.lists.proxmox.com>
List-Unsubscribe: <https://lists.proxmox.com/cgi-bin/mailman/options/pbs-devel>, 
 <mailto:pbs-devel-request@lists.proxmox.com?subject=unsubscribe>
List-Archive: <http://lists.proxmox.com/pipermail/pbs-devel/>
List-Post: <mailto:pbs-devel@lists.proxmox.com>
List-Help: <mailto:pbs-devel-request@lists.proxmox.com?subject=help>
List-Subscribe: <https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel>, 
 <mailto:pbs-devel-request@lists.proxmox.com?subject=subscribe>
X-List-Received-Date: Wed, 24 Jan 2024 10:19:42 -0000

New patch available:

https://lists.proxmox.com/pipermail/pbs-devel/2024-January/007679.html

On 21/12/2023 13:11, Wolfgang Bumiller wrote:
> forgot to include this in my other reply:
>
> On Thu, Dec 21, 2023 at 12:37:42PM +0100, Filip Schauer wrote:
>> On 20/12/2023 14:20, Wolfgang Bumiller wrote:
> (...)
>> I just thought of another way:
>>
>> How about inserting the content into FileType::Regular. This would
>> eliminate the need to pass None to add_entry. Therefore, it would be
>> impossible to pass conflicting parameters to the function, such as
>> FileType::Regular with content = None. This change would not get rid of
>> the hunk you mentioned, but the code seems cleaner to me this way.
> Works, too.
> If FileType has a getter to just get an Option<Reader> (possibly even as
> an internal `.*take*_reader()` since `add_entry` gets the full entry
> by-move anyway) that part of the code can still just gets an option as
> before without caring about the file mode so can otherwise stay the
> same.