🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #9149

Re: launching separate program

#9149
From: Remy Lebeau (TeamB)
Date: Wed, 28 Jul 2004 18:00
28 lines
1669 bytes
"Blake Young" <blakeyoung@mail.utexas.edu.NOSPAM> wrote in message
news:4107c722$1@newsgroups.borland.com...

> I intended on just removing the WaitForSingleObject
> and CloseHandle calls

Do not remove the CloseHandle() calls.  They are still needed.  Closing the
handles will not terminate the spawned process, but if you don't close the
handles then you will leak resources.

> If I remove those lines, my original program won't ever
> know when the external program has finished execution

But you just said that you don't care about that anymore, so why is it an
issue?

> and the handles will never be closed.

Close them immediately.

> Also, this external program that gets launched should remain
> running even if the original program is terminated.

It will.


Gambit
Technical Details
Message-ID: <4107e975$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <4107c722$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 10cc67,4306aa7d734acfa6
X-Google-Attributes: gid10cc67,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Remy Lebeau \(TeamB\)" <gambit47.no.spam@no.spam.yahoo.com>
Newsgroups: borland.public.cppbuilder.nativeapi
References: <4107c722$1@newsgroups.borland.com>
Subject: Re: launching separate program
Date: Wed, 28 Jul 2004 11:00:42 -0700
Lines: 30
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1409
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1409
NNTP-Posting-Host: 68.69.17.41
Message-ID: <4107e975$1@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1091037557 68.69.17.41 (28 Jul 2004 10:59:17 -0700)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail