Here is the serial fix for 2.1.

-----BEGIN PGP SIGNATURE-----
 Version: GnuPG v2.0.22 (GNU/Linux)
 
 iQIcBAABAgAGBQJT0k9HAAoJEBvWZb6bTYbyNl4P/18HrcfTMqqRPDjXKalEB530
 PtY4PlA/PDdk/LpfJhIbo7RreNd1L4UDpCrCju8xCDmBWgt0nk7MI5iHF90L2RGO
 mnOY6aHUApwTRYUfrUint/39+E0Y+jZ6VqzVLt5tbP3HlugBzeooE2+Og/171wC0
 7E9DokB5EyYcXPV5qlnZNnwiEoM2WKxQLTr9Cq2tcAwY89d2VrDeEa1ph3S6uGXa
 ycHv8AlLOj44vuKNDK1mTdQZrzx+pO+exD08jhrwqyAGHy1OQuTE/iyZfHB8byQ+
 L4weCMgIkN4hLahYfGhSyu9U9zFF6/LcgRzaewxQHOmJDs8VRcET3NfPrUgeS5Sh
 XcBEsFgPXXxBcET89HldDNg7bnCba/biTgjpWmRqjqj30EmaLzVFDbXjDOp7fxyt
 aaweoy9GWh4VFppfPCOHUMb7cGkBlmjh2NLsqI9ULSurBO+MOlERepqtqOwyEbgj
 qrYELA6N53C/F2ZOQtS6Pap5laVVqq49RTBitCpemd+kMiiwWTJ85lC0bakqgU6/
 qVIHFRwHNPy5JBbYAcQbDaftX1pEIrV6wpKTx3QoA/6vhe+fBFzUKirE0wEhUtKt
 Qt2A8GJdSNnmdj33h9ITHRZO0mhtB1zep02SHIK5no/PQRiMoD+ScvLxUCwj04sn
 EtT14fWcCGdGjfgAvXdz
 =v5wf
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging

Here is the serial fix for 2.1.

# gpg: Signature made Fri 25 Jul 2014 13:36:23 BST using RSA key ID 9B4D86F2
# gpg: Good signature from "Paolo Bonzini <pbonzini@redhat.com>"
# gpg:                 aka "Paolo Bonzini <bonzini@gnu.org>"

* remotes/bonzini/tags/for-upstream:
  qemu-char: ignore flow control if a PTY's slave is not connected

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
Peter Maydell 2014-07-25 16:58:41 +01:00
commit c60a57ff49

View File

@ -1168,6 +1168,9 @@ static int pty_chr_write(CharDriverState *chr, const uint8_t *buf, int len)
static GSource *pty_chr_add_watch(CharDriverState *chr, GIOCondition cond)
{
PtyCharDriver *s = chr->opaque;
if (!s->connected) {
return NULL;
}
return g_io_create_watch(s->fd, cond);
}
@ -3664,6 +3667,10 @@ int qemu_chr_fe_add_watch(CharDriverState *s, GIOCondition cond,
}
src = s->chr_add_watch(s, cond);
if (!src) {
return -EINVAL;
}
g_source_set_callback(src, (GSourceFunc)func, user_data, NULL);
tag = g_source_attach(src, NULL);
g_source_unref(src);