Bug#1138812: With =?UTF-8?Q?=E2=80=9C-ow=E2=80=9D, ?= write through soft links or bail out on soft links or at least warn on soft links

xiao sheng wen(肖盛文) atzlinux at sina.com
Fri Jun 5 09:28:55 BST 2026


Control: tags -1 upstream

Hi,

在 2026/6/4 13:57, Md Ayquassar 写道:
> Package: pngcrush
> Version: 1.8.13-3
> 
> pngcrush -ow softlink_to_a_png_file
> 
> currently removes the soft link and replaces it with a regular file. No warning is issued. Changing the file type silently by an image-processing tool is substandard behavior.
> This is unwanted, particularly if you run this in scripts, such as
> 
> for file in *.png; do pngcrush -ow $file; done
> 
> In this situation, if the current directory contains a mixture of links with the extension .png and regular .png files, all the soft links will be silently turned into regular files, and their origins get forgotten forever.
The origins still on the disk.

> 
> At the very least, pngcrush should warn the caller or simply bail out with an error message and a nonzero error code. In my personal use cases, I need the tool to write through a soft link. (An alternative solution, though an overkill for me, would be to have an option, say, “-dereference”, which would allow for writing through a soft link specified with the option “-ow” and bailing out on a soft link if “-dereference” is not supplied.)
> 
The pngcrush only a simple tool.

The filesystem links is a little complex for such a simple tool.


Regards,

-- 
肖盛文 xiao sheng wen -- Debian Developer(atzlinux)
Debian QA page: https://qa.debian.org/developer.php?login=atzlinux%40debian.org
GnuPG Public Key: 0x00186602339240CB

-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature.asc
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-phototools-devel/attachments/20260605/e7776a61/attachment.sig>


More information about the Pkg-phototools-devel mailing list