ExifTool Forum

ExifTool => Bug Reports / Feature Requests => Topic started by: ywzc on July 02, 2025, 10:04:46 AM

Title: Bug with -fileNUM option
Post by: ywzc on July 02, 2025, 10:04:46 AM
I think there is a bug with the -fileNUM option. When using a tag name as the ALTFILE format (e.g. -file1 '$XMP-xmpMM:PreservedFileName') with more than one file, the ALTFILE becomes the same one for all files (probably the first one) even though each SRCFILE has a different XMP-xmpMM:PreservedFileName value.

Steps to reproduce:

1. Directory with 3 images IMG_0001.JPG, IMG_0002.JPG, IMG_0003.JPG.
2. exiftool -overwrite_original '-XMP-xmpMM:PreservedFileName<FileName' DIR3. Create copies of these three images and name them 1.JPG, 2.JPG, 3.JPG respectivly.
4. exiftool -s -G1:8 -file1 '$XMP-xmpMM:PreservedFileName' -FileName -file1:FileName 1.JPG 2.JPG 3.JPGThe output is:
======== 1.JPG
[System]        FileName                        : 1.JPG
[System:File1]  FileName                        : IMG_0001.JPG
======== 2.JPG
[System]        FileName                        : 2.JPG
[System:File1]  FileName                        : IMG_0001.JPG
======== 3.JPG
[System]        FileName                        : 3.JPG
[System:File1]  FileName                        : IMG_0001.JPG
    3 image files read

Is this a bug or am I missing something?
Title: Re: Bug with -fileNUM option
Post by: Phil Harvey on July 02, 2025, 08:20:57 PM
Great, thanks for this report, and for the detailed description to allow this bug to be reproduced.

This will be fixed in version 13.32.

- Phil
Title: Re: Bug with -fileNUM option
Post by: ywzc on July 03, 2025, 04:53:10 AM
Version 13.32 works as expected. Great, thank you.