Article View: comp.lang.c++
Article #756Re: The end of software secrecy is almost upon
From: Rosario19
Date: Fri, 06 Nov 2026 11:43
Date: Fri, 06 Nov 2026 11:43
27 lines
2688 bytes
2688 bytes
On Tue, 20 Oct 2026 23:18:44 GMT, Charlie Gibbs wrote: >On 2026-10-20, Lawrence D’Oliveiro <ldo@nz.invalid> wrote: > >> On Tue, 20 Oct 2026 19:04:55 GMT, Charlie Gibbs wrote: >> >>> The undisciplined use of GOTOs is bad, agreed. >> >> Is there such a thing as a *disciplined* use of gotos? > >Yes, especially in COBOL or assembly language. For instance, >a GOTO to the end of a function ensures any of its cleanup code >gets executed, and fulfils a goal of structured proramming: >each function has one exit point. > >> I find the C code I write tends to do a lot of dynamic resource >> allocations. These can sometimes fail with errors. So error recovery >> will invariably involve cleaning up those parts of the allocations >> which already succeeded. > Gotos are no good for this; you need to exit >> levels of structure nesting one by one, disposing of allocations as >> you go. If in the start of the function all pointer are NULL, and in the end of the function there are all the free() I not have find all your problems with possibly multiple goto that point to the end of the function
Technical Details
Message-ID:
<kterellanc36d5bku3tov78jmflfnboa42@4ax.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mailReferences:
<11amvre$15far$1@dont-email.me> <11b5tdb$2cs5l$1@dont-email.me> <11b64cp$end$1@panix2.panix.com> <11b64hj$2faos$1@dont-email.me> <11b679m$6dl$1@panix2.panix.com> <11b6u68$2neta$1@dont-email.me> <11b6v90$2nine$3@dont-email.me> <11b87t8$379mv$1@dont-email.me> <11b8b2k$p44i$1@dont-email.me> <rXOBS.7015$5Iy.3911@fx04.iad> <11b8h83$3b48o$1@dont-email.me> <oFSBS.93666$Q3f.6740@fx05.iad>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail From: Rosario19 <Ros@invalid.invalid> Newsgroups: comp.lang.c++ Subject: Re: The end of software secrecy is almost upon Date: Fri, 06 Nov 2026 12:43:08 +0100 Organization: A noiseless patient Spider Lines: 27 Message-ID: <kterellanc36d5bku3tov78jmflfnboa42@4ax.com> References: <11amvre$15far$1@dont-email.me> <11b5tdb$2cs5l$1@dont-email.me> <11b64cp$end$1@panix2.panix.com> <11b64hj$2faos$1@dont-email.me> <11b679m$6dl$1@panix2.panix.com> <11b6u68$2neta$1@dont-email.me> <11b6v90$2nine$3@dont-email.me> <11b87t8$379mv$1@dont-email.me> <11b8b2k$p44i$1@dont-email.me> <rXOBS.7015$5Iy.3911@fx04.iad> <11b8h83$3b48o$1@dont-email.me> <oFSBS.93666$Q3f.6740@fx05.iad> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Date: Fri, 06 Nov 2026 11:35:08 +0000 (UTC) Injection-Info: dont-email.me; logging-data="2615314"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19wrYUnnJBtoEQ+RAtfLUDASEReyl6fsCQ="; posting-host="a60ec318c09e5b2e21171f455402efc2" Cancel-Lock: sha1:9ejyvXp6NNlNFkNGPYVLZ4TxyvI= sha256:txt20eB/ypi9pzz34uZAjU2VVE07ovs1iIlw9ioqZZk= sha1:6hMkX2D8dP+3Ew/HTN32UcfmYV0= sha256:rGy8OqYI04pRx/EPLkDst85igFKVKRf+Lm39b0VPU80= X-Newsreader: Forte Free Agent 1.93/32.576 English (American)