* [Qemu-devel] [PATCH v2] tpm: Fix write to file descriptor function
@ 2016-04-06 0:21 Stefan Berger
2016-04-09 18:08 ` Stefan Berger
0 siblings, 1 reply; 2+ messages in thread
From: Stefan Berger @ 2016-04-06 0:21 UTC (permalink / raw)
To: qemu-trivial, qemu-devel; +Cc: Stefan Berger, Stefan Berger
Fix a bug introduced in commit 46f296c while moving send_all to the
tpm_passthrough code. Fix the name of the variable used in the loop.
Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
---
hw/tpm/tpm_passthrough.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/tpm/tpm_passthrough.c b/hw/tpm/tpm_passthrough.c
index e98efb7..e88c0d2 100644
--- a/hw/tpm/tpm_passthrough.c
+++ b/hw/tpm/tpm_passthrough.c
@@ -86,7 +86,7 @@ static int tpm_passthrough_unix_write(int fd, const uint8_t *buf, uint32_t len)
int ret, remain;
remain = len;
- while (len > 0) {
+ while (remain > 0) {
ret = write(fd, buf, remain);
if (ret < 0) {
if (errno != EINTR && errno != EAGAIN) {
--
2.5.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH v2] tpm: Fix write to file descriptor function
2016-04-06 0:21 [Qemu-devel] [PATCH v2] tpm: Fix write to file descriptor function Stefan Berger
@ 2016-04-09 18:08 ` Stefan Berger
0 siblings, 0 replies; 2+ messages in thread
From: Stefan Berger @ 2016-04-09 18:08 UTC (permalink / raw)
To: Stefan Berger, qemu-trivial, qemu-devel, Peter Maydell,
Michael S. Tsirkin
On 04/05/2016 08:21 PM, Stefan Berger wrote:
> Fix a bug introduced in commit 46f296c while moving send_all to the
> tpm_passthrough code. Fix the name of the variable used in the loop.
Would someone please pick up this fix?
> Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
> ---
> hw/tpm/tpm_passthrough.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/tpm/tpm_passthrough.c b/hw/tpm/tpm_passthrough.c
> index e98efb7..e88c0d2 100644
> --- a/hw/tpm/tpm_passthrough.c
> +++ b/hw/tpm/tpm_passthrough.c
> @@ -86,7 +86,7 @@ static int tpm_passthrough_unix_write(int fd, const uint8_t *buf, uint32_t len)
> int ret, remain;
>
> remain = len;
> - while (len > 0) {
> + while (remain > 0) {
> ret = write(fd, buf, remain);
> if (ret < 0) {
> if (errno != EINTR && errno != EAGAIN) {
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-04-09 18:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-06 0:21 [Qemu-devel] [PATCH v2] tpm: Fix write to file descriptor function Stefan Berger
2016-04-09 18:08 ` Stefan Berger
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).