On 30/03/15 16:46, leledumbo wrote:
As far as I can tell, exceptions propagate through to the main app -
(written with Lazarus in this case).
I would like to trap them directly within the library.
// excp.pas
library excp;
{$mode objfpc}
uses sysutils;
procedure p;
begin
try
raise exc
> As far as I can tell, exceptions propagate through to the main app -
> (written with Lazarus in this case).
> I would like to trap them directly within the library.
// excp.pas
library excp;
{$mode objfpc}
uses sysutils;
procedure p;
begin
try
raise exception.create('an exception')
Would anybody be able to enlighten me on enabling exception trapping in
Linux libraries ?
As far as I can tell, exceptions propagate through to the main app -
(written with Lazarus in this case).
I would like to trap them directly within the library.
Pointers, clues, links, examples (heck, ev
On 28 May 2009, at 23:18, JoshyFun wrote:
Hello FPC-Pascal,
Thursday, May 28, 2009, 9:58:23 PM, you wrote:
RS> Shrinked down example of the program.
RS> Rainer
[...]
RS> procedure memclr( p : pointer ; len : longint );
Aside from the socket problem, can somebody explain me this line:
RS> b
Hello FPC-Pascal,
Thursday, May 28, 2009, 9:58:23 PM, you wrote:
RS> Shrinked down example of the program.
RS> Rainer
[...]
RS> procedure memclr( p : pointer ; len : longint );
RS> var x : longint;
RS> begin
RS> for x := 1 to len do begin
RS> byte( p^ ) := 0;
RS> inc( p );
RS> end;
RS> end;
On 28 May 2009, at 21:58, Rainer Stratmann wrote:
Shrinked down example of the program.
strace shows this:
accept(3, {sa_family=AF_INET, sin_port=htons(48134),
sin_addr=inet_addr("xxx.xxx.xxx.xxx")}, [16]) = 4
write(1, ".", 1)= 1
select(0, NULL, NULL, NULL, {0, 300
Shrinked down example of the program.
Rainer
program serverclient;
uses
baseunix ,
sockets,
crt;
const port_program = 12021;
procedure memclr( p : pointer ; len : longint );
var x : longint;
begin
for x := 1 to len do begin
byte( p^ ) := 0;
inc( p );
end;
end;
procedure se
On 27 May 2009, at 19:24, Rainer Stratmann wrote:
Am Mittwoch, 27. Mai 2009 11:45 schrieb Vincent Snijders:
Rainer Stratmann schreef:
Am Dienstag, 26. Mai 2009 22:27 schrieb Jonas Maebe:
Well, as I said: it does not raise any exceptions.
Would it be possible to catch that exception?
With t
Am Mittwoch, 27. Mai 2009 11:45 schrieb Vincent Snijders:
> Rainer Stratmann schreef:
> > Am Dienstag, 26. Mai 2009 22:27 schrieb Jonas Maebe:
> >> Well, as I said: it does not raise any exceptions.
> >
> > Would it be possible to catch that exception?
> > With the try except block?
> > Are other f
Rainer Stratmann schreef:
Am Dienstag, 26. Mai 2009 22:27 schrieb Jonas Maebe:
Well, as I said: it does not raise any exceptions.
Would it be possible to catch that exception?
With the try except block?
Are other functions existing to catch linux exceptions?
No, you cannot catch exception t
Am Dienstag, 26. Mai 2009 22:27 schrieb Jonas Maebe:
> Well, as I said: it does not raise any exceptions.
Would it be possible to catch that exception?
With the try except block?
Are other functions existing to catch linux exceptions?
> The socket unit calls through to unix routines (either via l
On 26 May 2009, at 22:18, Rainer Stratmann wrote:
Yes, the send function from the socket unit.
Well, as I said: it does not raise any exceptions.
Situation:
Connection is established.
Client closes connection
Server wants to sent data with send.
Program stops with errorcode 13 (I found out
Yes, the send function from the socket unit.
Situation:
Connection is established.
Client closes connection
Server wants to sent data with send.
Program stops with errorcode 13 (I found out that this is the linux errorcode
for permission denied).
The error is reproduceable.
I thought that may
On 26 May 2009, at 22:01, Rainer Stratmann wrote:
The send function causes sometimes an exception (permission denied).
Which send function? The one of the sockets unit? If never raises an
exception. It only sets socketerror. If you are not talking about that
send function, which one do yo
The send function causes sometimes an exception (permission denied).
try
l := send( ... )
except
l := 0;
end;
This does not work.
The Program always stops in case of an exception. With exitcode 13 (permission
denied).
What do I have to do that the program continuous execution also when
exce
Jonas,
Thanks for your response.
On Fri, 30 May 2003, Jonas Maebe wrote:
>
> On vrijdag, mei 30, 2003, at 12:47 Europe/Brussels, Adam Naumowicz
> wrote:
>
> > I found it a bit surprising that byte-variable overflow does not raise
> > EIntException...
> > I'm using FPC 1.0.6 (with -Co on the comm
On vrijdag, mei 30, 2003, at 12:47 Europe/Brussels, Adam Naumowicz
wrote:
I found it a bit surprising that byte-variable overflow does not raise
EIntException...
I'm using FPC 1.0.6 (with -Co on the command line).
Also use -Cr. An overflow and a range check are semantically exactly
the same (you
Hi,
Where can I find detailed information about all the predefined Exception
classes and their semantics?
I found it a bit surprising that byte-variable overflow does not raise
EIntException...
I'm using FPC 1.0.6 (with -Co on the command line).
Best regards,
Adam Naumowicz
=
18 matches
Mail list logo