home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!spool.mu.edu!agate!doc.ic.ac.uk!pipex!demon!cix.compulink.co.uk!tbunce
- Newsgroups: comp.lang.perl
- From: tbunce@cix.compulink.co.uk (Tim Bunce)
- Subject: Memory leak using `...` and a workaround.
- Reply-To: tbunce@cix.compulink.co.uk
- Date: Thu, 28 Jan 1993 21:50:00 +0000
- Message-ID: <memo.903981@cix.compulink.co.uk>
- Sender: usenet@demon.co.uk
- Lines: 15
-
-
- Using backticks in an array context such as:
-
- local($output) = `ls`;
-
- leaks memory. The workaround is to force the evaluation to be
- in a scalar context, e.g.,
-
- local($output) = scalar `ls`;
-
- This relates to perl4 pl35 on a sun4 machine and maybe others.
-
- Regards,
- Tim Bunce.
- tbunce@cix.compulink.co.uk
-