comp.lang.ada
 help / color / mirror / Atom feed
From: Corey Ashford <yeroca@rocketmail.com>
Subject: Re: Constraint Error. Why?
Date: 1999/01/15
Date: 1999-01-15T00:00:00+00:00	[thread overview]
Message-ID: <369EE46B.89982F32@rocketmail.com> (raw)
In-Reply-To: 369E5053.5C5EF4A5@stelnj.nojunk.com

Roga Danar wrote:
> 
> Thanks for your reply.  I have fixed the problem by looking at an older example of
> code of I had a similiar problem.
> 
> The exception *is* coming from the "if" statement and not the Createfile call.
> 
> Handle is an access to an access to an integer.
> 
> What (appearently) is happening here is that the pointer is NOT NULL when it is
> check by the "if" statement but pointing to anything which I can validly
> deference.

It could be that "seg faults" are converted to constraint_errors within the Ada
runtime.  It's odd though.  Usually, if that is done at all, they are converted
to storage_errors.


> 
> The problem is easily solved with a call to a function which converts the HANDLE
> to an integer which I can then check against the "Invalid_Handle_Value".
> 

Glad you found a fix.

- Corey




      reply	other threads:[~1999-01-15  0:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-01-12  0:00 Constraint Error. Why? Roga Danar
1999-01-14  0:00 ` Corey Ashford
1999-01-14  0:00   ` Roga Danar
1999-01-15  0:00     ` Corey Ashford [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox