Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
nofork leaves tmp files behind on errexit and ${foo?bar}
- X-seq: zsh-workers 54464
- From: Mikael Magnusson <mikachu@xxxxxxxxx>
- To: zsh workers <zsh-workers@xxxxxxx>
- Subject: nofork leaves tmp files behind on errexit and ${foo?bar}
- Date: Mon, 4 May 2026 04:55:36 +0200
- Arc-authentication-results: i=1; mx.google.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=to:subject:message-id:date:from:mime-version:dkim-signature; bh=vXgpJBQ/dSjszS7XVb8Qj09hoAi0E4Rj1nqItNmEgXg=; fh=DSq7imBqIFzdbbKtbVCpdy8HVz0gMsj8pDLr9jpnRMA=; b=LGPsWQA8vag/eYCFXwfl238xhAsGnd9NU4/BhwR3//dNcYqcXY/7D8fd/QjZEFbIEi QD7wMIjl9jBtv8k/sKGu0RAVqLZqIIwzz5ATfA6dub3OZD2AgY2EKRdY6OMiwR17I3GR cRJ2Eac9rh/h1bEW46w1WtBpPvHFNHac5hloST5Q3QA35sRV289dAAnD7YyReDDJ4PAl YH5L4dqpBfsQ5zXyGqaKq4TxWkbkNNwFjic3iPiGYEwamKrVkf8+OhQrdOhLi9cCh8V9 LVMy+ZeZ2Fb10lnuF2BkT7xCasIgwWcS9FjAFJKSIBDbOeOFJcXt23df+hhTgwAyPIJJ jrQg==; darn=zsh.org
- Arc-seal: i=1; a=rsa-sha256; t=1777863352; cv=none; d=google.com; s=arc-20240605; b=VnerwJC0fTmHTeuNgJg4FQSGd2BQ2DeSt30sMhcpfoBoLD59iUKAYU/GUwSCXXmDl0 3XJxn61p3ZwBSzFp3yQF6A+TRi03pY1wOmd4OCfWNnwy84xFFMkzBlFhlCHK7qwddB6S iGPr1IgYxuZZppIMjLJVn5YL8D9OH6ZHnzQGDic9GUPYn/F0I4ipNOE9kCcUx6t3SHVg RCcHPNGf/WAF9JpgGGZsRBtRdfWo02PFf5qt43gW8A/vcwW71IdTxLcZwllH3UicymSK qEqoWCCzrOYOez85Wmea99ZlJjaXgrJB/k6C6a4NhoUHEBWN6IedZIxuo3cy0Yy77j1S sOfw==
- Archived-at: <https://zsh.org/workers/54464>
- List-id: <zsh-workers.zsh.org>
I noticed this because the test suite does this, and my /tmp had a ton
of zshdo8sar files. I can reproduce the errexit interactively but not
the other one for some reason, maybe it depends on an option? Anyway,
the test that explicitly exits rather than depend on errexit does not
leave the tmpfile behind, which makes me think this can possibly be
fixed?
% (echo "${ print INNER; exit 7; echo not reached >&2 }"); echo /tmp/zsh*
zsh: no matches found: /tmp/zsh*
% (echo "${ setopt errexit; print INNER; false; exit 7; echo not
reached >&2 }"); echo /tmp/zsh*
/tmp/zshV4lx90
% rm /tmp/zsh*
# this last one leaves the file behind from the testcase but not in my
interactive shell
% (echo "${ print INNER; echo ${unset?bar}; echo not reached >&2 }");
echo /tmp/zsh*
zsh:134: unset: bar
zsh: no matches found: /tmp/zsh*
--
Mikael Magnusson
Messages sorted by:
Reverse Date,
Date,
Thread,
Author