[magick-users] Access Violation in Magick++ - new Image(char*)
Bob Friesenhahn
bfriesen at simple.dallas.tx.us
Mon Oct 28 11:33:58 PST 2002
1) Make sure that you are using a try/catch statement to capture any
thrown exceptions so that you don't get crashes from
'unhandled'. It may be that an error has been reported via an
exception.
2) If you are using the pre-compiled DLLs from 5.5.1, then Visual C++
7.0 is required.
3) There is practically no reason to use 'new' with Magick++ Images
since they are essentially a (managed) pointer themselves.
4) Make sure that your app is compiled using the same options as is
used to compile CORE_RL_MAGICK++.dll.
Bob
On Mon, 28 Oct 2002, Paul Harman wrote:
> I'm using MS VC++ to create a simple class and wrapper application. The
> wrapper app calls InitializeMagick() and then performs calls to my class.
>
> One of the first things I do is pass a command-line argument into the class
> which does the following:
>
> Image *newImage=new Image(filename_string)
>
> ...where filename_string has been set to argv[1] (say).
>
> This is throwing an Access Violation in CORE_RL_MAGICK++.dll at 0x1001EFE5
>
> I've no idea what's going on and I have no idea how to find out :*(
>
> BTW the path passed to InitializeMagick() - does it have to be the runline
> of the program, or can it simply be the path to where the ImageMagick DLLs
> are installed? I've tried both and it doesn't have any affect on my problem,
> just asking for future information...
>
> Paul
>
>
> This E-Mail and any attachment is intended only for the person or entity for
> which it is addressed and may contain confidential material. If you are not
> the addressee or have received this E-Mail in error, please inform the
> sender immediately and delete it from your computer. In addition, if you are
> not the addressee or have received this E-Mail in error, any disclosure,
> copying, distribution or any action taken or omitted to be taken in reliance
> upon it is prohibited and may be unlawful.
> If this E-Mail has been transmitted outside the ordinary course of its
> business, the company for which the sender works accepts no liability for
> any loss or damage suffered by any person arising from any use of or
> reliance on information contained in this E-Mail, and any opinion expressed
> in this E-Mail is personal to the sender and may not reflect the opinion of
> such company. Although the network operator makes every reasonable effort to
> keep its network free from viruses, neither the network operator nor the
> sender or the company for which the sender works accepts any responsibility
> for computer viruses transmitted through this E-Mail or any attachments; it
> is your responsibility to virus scan this E-Mail and any attachments. Any
> E-Mail reply to this address may be subject to interception or monitoring
> for operational reasons or for lawful business practices.
>
>
>
> _______________________________________________
> Magick-users mailing list
> Magick-users at imagemagick.org
> http://studio.imagemagick.org/mailman/listinfo/magick-users
>
======================================
Bob Friesenhahn
bfriesen at simple.dallas.tx.us
http://www.simplesystems.org/users/bfriesen
More information about the Magick-users
mailing list