diff options
author | Darren Tucker <dtucker@zip.com.au> | 2007-06-25 18:34:43 +1000 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2007-06-25 18:34:43 +1000 |
commit | d989adadd33ed305a22f555d7d69db3cff4e83da (patch) | |
tree | 225085c8a5b282438ca0df1cc8f046efcafa79f1 /ssh.c | |
parent | 067263e84800c4b35f9bbbfafdd92aea493b6e0b (diff) |
- djm@cvs.openbsd.org 2007/06/14 21:43:25
[ssh.c]
handle EINTR when waiting for mux exit status properly
Diffstat (limited to 'ssh.c')
-rw-r--r-- | ssh.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssh.c,v 1.298 2007/06/12 11:45:27 djm Exp $ */ | 1 | /* $OpenBSD: ssh.c,v 1.299 2007/06/14 21:43:25 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -1468,8 +1468,11 @@ control_client(const char *path) | |||
1468 | debug2("Received EOF from master"); | 1468 | debug2("Received EOF from master"); |
1469 | break; | 1469 | break; |
1470 | } | 1470 | } |
1471 | if (r == -1 && errno != EINTR) | 1471 | if (r == -1) { |
1472 | if (errno == EINTR) | ||
1473 | continue; | ||
1472 | fatal("%s: read %s", __func__, strerror(errno)); | 1474 | fatal("%s: read %s", __func__, strerror(errno)); |
1475 | } | ||
1473 | i += r; | 1476 | i += r; |
1474 | } | 1477 | } |
1475 | close(sock); | 1478 | close(sock); |