From: Wolfgang Bangerth Date: Tue, 1 Oct 2002 18:57:52 +0000 (+0000) Subject: Check for the right thing. X-Git-Tag: v8.0.0~17401 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=142ee794637b6b29f4b0666d39cfa3f171c4423c;p=dealii.git Check for the right thing. git-svn-id: https://svn.dealii.org/trunk@6584 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/lac/source/sparse_direct.cc b/deal.II/lac/source/sparse_direct.cc index 551e1df71e..938fa204d7 100644 --- a/deal.II/lac/source/sparse_direct.cc +++ b/deal.II/lac/source/sparse_direct.cc @@ -29,6 +29,8 @@ #endif #include +#include +#include #include #ifndef DEAL_II_USE_DIRECT_ERRNO_H @@ -331,10 +333,10 @@ void monitor_child_liveness (const pid_t child_pid) // die ("Child process seems to have died!"); int ret = kill (child_pid, 0); if (ret != 0) - if (ret == ESRCH) + if ((ret == -1) && (errno == ESRCH)) die ("Child process seems to have died!"); else - die ("Unspecified error while checking for other process!"); + die ("Unspecified error while checking for other process!", ret, errno); // ok, master still running, // take a little rest and then