zsh-workers
 help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-workers@zsh.org
Subject: Re: (anon):disown: no current job
Date: Wed, 11 Feb 2015 20:00:07 -0800	[thread overview]
Message-ID: <150211200007.ZM18484@torch.brasslantern.com> (raw)
In-Reply-To: <20150212015249.GF1845@tarsus.local2>

On Feb 12,  1:52am, Daniel Shahaf wrote:
}
} $ zsh -f
} % cat
} ^Z
} zsh: suspended  cat
} % () { bg && disown }    
} [1]  - continued  cat
} (anon):disown: no current job

I can reproduce this, with one extra bit:

zsh: suspended  cat
torch% () { bg && disown }
[1]  - continued  cat
(anon):disown: no current job
torch% 
[1]  + suspended (tty input)  cat


} It happens with da86d6b4f2c3eef5b1f0860c9dae433f3a540951 (workers/34485)
} but not with the commit before that one.
} 
} Haven't looked into cause/fix.

Looks like it's related to this (diff here reverts a change):

diff --git a/Src/parse.c b/Src/parse.c
index ffd25de..236789d 100644
--- a/Src/parse.c
+++ b/Src/parse.c
@@ -1612,7 +1612,8 @@ par_funcdef(int *cmplx)
 	    num++;
 	    zshlex();
 	}
-	*cmplx = 1;
+	if (num > 0)
+	    *cmplx = 1;
 	ecbuf[parg] = ecused - parg; /*?*/
 	ecbuf[parg+1] = num;
     }


zsh: suspended  cat
torch% () { bg && disown }
[1]  - continued  cat
[1]  + suspended (tty input)  cat
(anon):disown: warning: job is suspended, use `kill -CONT -18480' to resume
torch% 

There's a similar change in par_simple() that may also need to be reversed.

I'm not sure about the exec.c change that moved the "if (do_exec)" block,
but I'm wondering whether it has to do with Ray's mysterious shell exits,
because it makes an _exit() call.


      reply	other threads:[~2015-02-12  4:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-12  1:52 Daniel Shahaf
2015-02-12  4:00 ` Bart Schaefer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=150211200007.ZM18484@torch.brasslantern.com \
    --to=schaefer@brasslantern.com \
    --cc=zsh-workers@zsh.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).