in reply to Strange behaviour from two pieces of similar code in different running environments
Ok. I'll put in a quarter and play again. The Image::Magick module is just a thin wrapper on the libMagick libraries. Unlike a pure perl module, which is interpreted, the libMagick libraries have to be dynamically linked during a load phase. Many common problems encountered when linking is when calling and called routines are compiled with different compilers or when executables were linked with different header files. To cover the first how was the Image::Magick module installed? Has it been tested? Was it compiled against the same perl distribution as is currently being used? To cover the second, is the CGI server using the same perl executable as the command line example? Are there different perl executables living on the system?
The DynaLoader process relies on the @ISA array to lookup symbol names. For your test script to accurately model the behavior of the CGI script @ISA would have to be correctly initialized to be the same as the CGI version
|
|---|