Cannot open file with : in the path name

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
tlichev
Posts: 16
Joined: 2012-06-27T04:05:56-07:00
Authentication code: 13
Contact:

Cannot open file with : in the path name

Post by tlichev »

I'm using ImageMagick 6.7.7-9 Q16 on Linux
This is my convert command:

Code: Select all

/opt/ImageMagick-6.6.7-bin/bin/convert /S:/store/snowman_138060_0.psd[0] -flatten -rotate 0 -interpolate bicubic -resize 320x320! -verbose -depth 8 GIF:/S:/temp/media6669569482882550110.gif
As you can see there is a colon in the source path name and I'm getting an error (doesn't matter if the colon is escaped or not - /S:/... or /S\:/...)

Code: Select all

convert: unable to open image `/store/snowman_138060_0.psd': No such file or directory @ error/blob.c/OpenBlob/2638
It works if the source file name is without [0] or there is no colon in the path
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA
Contact:

Re: Cannot open file with : in the path name

Post by fmw42 »

try quotes around your file names (single or double?)

"/S:/store/snowman_138060_0.psd[0]"


Also search the archives and I seem to recall something about this not too long ago.

see viewtopic.php?f=3&t=19215&p=75045&hilit ... ame#p75045
tlichev
Posts: 16
Joined: 2012-06-27T04:05:56-07:00
Authentication code: 13
Contact:

Re: Cannot open file with : in the path name

Post by tlichev »

Tried with quotes, doesnt help much ...
And as far as I see from the post this problem has been reproduced in 6.7.3 and I dont know if it has been fixed in 6.7.7
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA
Contact:

Re: Cannot open file with : in the path name

Post by fmw42 »

Post the problem to the Bugs forum and ask if it was fixed or somehow got reverted.
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia
Contact:

Re: Cannot open file with : in the path name

Post by anthony »

Quotes are for the shell or DOS. The ':' problem is with Imagemagick. It thinks you have a 'coder' as part of the filename.

Backslash the ':' - ensuring the backslash is also passed to IM by doubling it.

See IM examples, File Handling, Meta-Character Handling
http://www.imagemagick.org/Usage/files/#read_meta

This was extracted from that discussion Fred remembered.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
tlichev
Posts: 16
Joined: 2012-06-27T04:05:56-07:00
Authentication code: 13
Contact:

Re: Cannot open file with : in the path name

Post by tlichev »

The same problem is reproducible in Linux with 6.8.3-7
There is no way to parse colon as part of the path. Tried escaping (single, double, triple), quotes, both ... no luck.
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 27 guests