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


Groups > comp.lang.c > #60916

Re: Null Pointer exceptions

From Stephen Sprunk <stephen@sprunk.org>
Newsgroups comp.lang.c
Subject Re: Null Pointer exceptions
Date 2015-04-23 11:53 -0500
Organization A noiseless patient Spider
Message-ID <mhb818$on$1@dont-email.me> (permalink)
References <mh9451$ib4$1@speranza.aioe.org> <55381A74.3000107@verizon.net> <mh9at9$q53$1@dont-email.me> <5538327A.2090208@verizon.net>

Show all headers | View raw


On 22-Apr-15 18:44, James Kuyper wrote:
> On 04/22/2015 07:30 PM, Stephen Sprunk wrote:
>> On 22-Apr-15 17:02, James Kuyper wrote:
>>> You're like a doctor who sees a patient coughing up blood, and
>>> concentrates his attention on cleaning up the blood. A proper
>>> doctor need to figure out why the patient is bleeding internally
>>> before the doctor can put a stop to it, otherwise the bleeding
>>> will just continue until the patient dies as a result.
>> 
>> Figuring out the cause (and treating it) takes time, and if you do 
>> nothing for the symptoms in the meantime, the patient may die
>> anyway.
> 
> True - symptoms do need to be treated - but that should generally not
> be the only thing you do about them.
> 
> At a minimum, you should seek a diagnosis. The diagnosis might
> indicate that there is no need for anything more than symptomatic
> relief, or it might indicated that there is no known cure, in which
> case symptomatic relief is the best you can do - but it could also
> identify a treatment plan that should be put into effect as soon as
> possible. Until you at least attempt diagnosis, you can't be sure
> which of those cases apply.

Of course; that's why I said "in the meantime".

>> If no cure exists for the particular disease, then all you can do
>> is manage the symptoms.
> 
> Granted - but seldom completely relevant to computer bugs. Almost
> all computer bugs are solvable, once you identify them sufficiently
> well - the hard part is identifying them.

Indeed, and that was the point behind the following paragraph that
discussed unreproducible bugs.

My experience is that if we can reproduce a bug, we can almost certainly
fix it--and usually with very little effort unless it requires a design
change.  However, if we can't reproduce a bug, it's much more likely we
can't fix it--and even if we try, we can't be sure we actually did so.

S

-- 
Stephen Sprunk         "God does not play dice."  --Albert Einstein
CCIE #3723         "God is an inveterate gambler, and He throws the
K5SSS        dice at every possible opportunity." --Stephen Hawking

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


Thread

Null Pointer exceptions jeff <nospam@nospam.com> - 2015-04-22 21:34 +0000
  Re: Null Pointer exceptions James Kuyper <jameskuyper@verizon.net> - 2015-04-22 18:02 -0400
    Re: Null Pointer exceptions Stephen Sprunk <stephen@sprunk.org> - 2015-04-22 18:30 -0500
      Re: Null Pointer exceptions James Kuyper <jameskuyper@verizon.net> - 2015-04-22 19:44 -0400
        Re: Null Pointer exceptions Stephen Sprunk <stephen@sprunk.org> - 2015-04-23 11:53 -0500
          Re: Null Pointer exceptions Richard Heathfield <rjh@cpax.org.uk> - 2015-04-23 18:59 +0100
  Re: Null Pointer exceptions Barry Schwarz <schwarzb@dqel.com> - 2015-04-22 15:17 -0700
    Re: Null Pointer exceptions James Dow Allen <gmail@jamesdowallen.nospam> - 2015-04-23 04:11 +0000
  Re: Null Pointer exceptions Robert Wessel <robertwessel2@yahoo.com> - 2015-04-22 17:19 -0500
  Re: Null Pointer exceptions Ben Bacarisse <ben.lists@bsb.me.uk> - 2015-04-22 23:46 +0100
  Re: Null Pointer exceptions Nobody <nobody@nowhere.invalid> - 2015-04-23 03:14 +0100
    Re: Null Pointer exceptions James Kuyper <jameskuyper@verizon.net> - 2015-04-23 12:32 -0400

csiph-web