Use of uninitialized value in lc

Started by rbpeirce, January 27, 2012, 03:06:50 PM

Previous topic - Next topic

rbpeirce

I am running exiftool 8.77 on Mac OS 10.7.2.  The same problem occurred in 8.66.  I don't recall the release I was running before this upgrade but I don't recall seeing this message until now:

Use of uninitialized value in lc at /usr/bin/lib/Image/ExifTool/TagLookup.pm line 6880, <EXIFTOOL_FILE> chunk 3.

I don't know what this means.  It seems to happen on every use of exiftool.  Here is a recent one:


exiftool -nikon DSCN2034.jpg
Use of uninitialized value in lc at /usr/bin/lib/Image/ExifTool/TagLookup.pm line 6880, <EXIFTOOL_FILE> chunk 3.
Camera Model Name               : E4300
Focal Length                    : 8.0 mm
Image Size                      : 1704x2272
Shutter Speed                   : 1/46
Aperture                        : 2.8
ISO                             : 100
ISO                             : 0
Noise Reduction                 : Off
Exposure Program                : Program AE
Exposure Compensation           : 0
White Balance                   : Auto
White Balance                   : Auto
Quality                         : Fine
Metering Mode                   : Multi-segment
Focus Mode                      : AF-C
Color Space                     : sRGB
Saturation                      : 0
Saturation                      : Normal
Sharpness                       : Auto
Sharpness                       : Normal
Flash                           : Auto, Did not fire

Phil Harvey

Thanks for this report.  This one is new to me.

Do you have any user-defined tags?  If so, try running without the config file (-config "") to see if the problem still occurs.  If it does, could you please email me DSCN2034.jpg so I can attempt to reproduce the problem?  My email is philharvey66 at gmail.com.  Thanks.  I do have a sample image from a Coolpix 4300, but it doesn't give me this error.

If I can't reproduce the error the likely cause would be a bad installation or different versions of the exiftool application and its libraries.  Try "exiftool -ver" to see the version.  This will warn you if the libraries are a different version.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

rbpeirce

Adding -config "" removed the problem.  I tried it on some other jogs which were also producing this error and it went away.  I don't have any idea why.

exiftool -ver says 8.77.  There was no warning about libraries.

Phil Harvey

OK, great.  In your home directory or the exiftool application directory there is a hidden file called ".ExifTool_config" that you should erase or fix because it seems this is causing the problem.

use "ls -la ~" in the terminal to list hidden files in your home directory, then "rm ~/.ExifTool_config" to remove it.   If it isn't there, type "whereis exiftool" to determine the exiftool application directory, then try there instead.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

rbpeirce

Got it.  It was in my home directory.  I have viewable hidden files so it was easy to find.  After removal the error went away.  However, the file was not re-created when I ran exiftool.  How did it get there in the first place?

Phil Harvey

#5
Someone (ie. you) must have put the it there.  A sample user-defined file named "ExifTool_config" is included in the full ExifTool distribution, but to activate it you must manually rename it to ".ExifTool_config" and move it to your home directory.

It is possible that older versions of the sample config file are incompatible with the current ExifTool, which could have caused this problem if you had done this.

- Phil

Edit:  See this thread for a related discussion
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).