diff --git a/dfhack/DFHackAPI.cpp b/dfhack/DFHackAPI.cpp index b023ccbd6..995a7326c 100644 --- a/dfhack/DFHackAPI.cpp +++ b/dfhack/DFHackAPI.cpp @@ -66,6 +66,10 @@ API::~API() bool API::Attach() { + if(d->p != NULL) + { + return d->p->suspend(); + } // detach all processes, destroy manager if (d->pm == 0) {