Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #12783

Re: Error handling

From t1t0 <t1t0@noemail.not>
Newsgroups comp.lang.c
Subject Re: Error handling
Date 2011-11-05 18:37 +0000
Organization Aioe.org NNTP Server
Message-ID <j93vpg$t9v$1@speranza.aioe.org> (permalink)
References <j93dqr$d4u$1@speranza.aioe.org> <j93fac$mgp$1@dont-email.me>

Show all headers | View raw


On Sat, 05 Nov 2011 09:55:03 -0400, Eric Sosman wrote:

> An attractive approach on
> systems that allow more than one program to execute (again, this is
> beyond the realm of the C language) is to write a simple "watchdog"
> program that just observes the "worker" program.

Nice idea, that's remember some 'guardian' process like the Firebird one.

But, there is a way to get the core dump on Windows OS ? I would like to 
find a solution for a generic program, like an pattern to have the error 
reported. 

I would resolve this problem before write the application, I want know 
all the app errors...


On Sat, 05 Nov 2011 14:10:00 +0000, Nobody wrote:

> Also, trying to report a "crash" from within the process which has
> crashed is a fool's errand. If you want crash reporting, you need to
> wrap the process so that the parent process handles the reporting when
> the child crashes. In which case, you can just use the resulting core
> dump.

I understand, but what about a thread crash ? Could I write some 
informations on a log file from a catched signal of a secondary thread
(like division for 0) and perform a read from the main thread to send 
informations by email (for example)? Is it very fool?


On Sat, 05 Nov 2011 15:31:31 +0000, Kaz Kylheku wrote:
> 
> On glibc-based Linux, you have a function called backtrace.

Nice, but there is a way to do the same think on windows? With a library 
maybe? Do you know one that do this that is platform-independent ?




Thanks to all, and sorry for my english
t1t0

Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Error handling t1t0 <t1t0@noemail.not> - 2011-11-05 13:31 +0000
  Re: Error handling Eric Sosman <esosman@ieee-dot-org.invalid> - 2011-11-05 09:55 -0400
    Re: Error handling t1t0 <t1t0@noemail.not> - 2011-11-05 18:37 +0000
      Re: Error handling Eric Sosman <esosman@ieee-dot-org.invalid> - 2011-11-05 14:50 -0400
        Re: Error handling t1t0 <t1t0@noemail.not> - 2011-11-06 10:36 +0000
      Re: Error handling Kaz Kylheku <kaz@kylheku.com> - 2011-11-06 01:15 +0000
        Re: Error handling t1t0 <t1t0@noemail.not> - 2011-11-06 10:44 +0000
          Re: Error handling Nick Keighley <nick_keighley_nospam@hotmail.com> - 2011-11-06 06:02 -0800
          Re: Error handling Kaz Kylheku <kaz@kylheku.com> - 2011-11-06 16:21 +0000
  Re: Error handling Nobody <nobody@nowhere.com> - 2011-11-05 14:10 +0000
  Re: Error handling Kaz Kylheku <kaz@kylheku.com> - 2011-11-05 15:31 +0000
  Re: Error handling Mike Manilone <zhtx10@gmail.com> - 2011-11-06 03:56 +0000

csiph-web