zhanghailiang <zhang.zhanghaili...@huawei.com> writes: > It is either "Failed _to_ do something", or "something failed", > but not "failed something". > > Signed-off-by: zhanghailiang <zhang.zhanghaili...@huawei.com>
Semantically I'm fine to add: Reviewed-by: Alex Bennée <alex.ben...@linaro.org> I'll leave it to the language pedants to rule on the grammar ;-) > --- > qemu-char.c | 26 +++++++++++++------------- > 1 file changed, 13 insertions(+), 13 deletions(-) > > diff --git a/qemu-char.c b/qemu-char.c > index a09bbf6..0f38cdd 100644 > --- a/qemu-char.c > +++ b/qemu-char.c > @@ -1872,25 +1872,25 @@ static int win_chr_init(CharDriverState *chr, const > char *filename) > > s->hsend = CreateEvent(NULL, TRUE, FALSE, NULL); > if (!s->hsend) { > - fprintf(stderr, "Failed CreateEvent\n"); > + fprintf(stderr, "CreateEvent failed\n"); > goto fail; > } > s->hrecv = CreateEvent(NULL, TRUE, FALSE, NULL); > if (!s->hrecv) { > - fprintf(stderr, "Failed CreateEvent\n"); > + fprintf(stderr, "CreateEvent failed\n"); > goto fail; > } > > s->hcom = CreateFile(filename, GENERIC_READ|GENERIC_WRITE, 0, NULL, > OPEN_EXISTING, FILE_FLAG_OVERLAPPED, 0); > if (s->hcom == INVALID_HANDLE_VALUE) { > - fprintf(stderr, "Failed CreateFile (%lu)\n", GetLastError()); > + fprintf(stderr, "CreateFile (%lu) failed\n", GetLastError()); > s->hcom = NULL; > goto fail; > } > > if (!SetupComm(s->hcom, NRECVBUF, NSENDBUF)) { > - fprintf(stderr, "Failed SetupComm\n"); > + fprintf(stderr, "SetupComm failed\n"); > goto fail; > } > > @@ -1901,23 +1901,23 @@ static int win_chr_init(CharDriverState *chr, const > char *filename) > CommConfigDialog(filename, NULL, &comcfg); > > if (!SetCommState(s->hcom, &comcfg.dcb)) { > - fprintf(stderr, "Failed SetCommState\n"); > + fprintf(stderr, "SetCommState failed\n"); > goto fail; > } > > if (!SetCommMask(s->hcom, EV_ERR)) { > - fprintf(stderr, "Failed SetCommMask\n"); > + fprintf(stderr, "SetCommMask failed\n"); > goto fail; > } > > cto.ReadIntervalTimeout = MAXDWORD; > if (!SetCommTimeouts(s->hcom, &cto)) { > - fprintf(stderr, "Failed SetCommTimeouts\n"); > + fprintf(stderr, "SetCommTimeouts failed\n"); > goto fail; > } > > if (!ClearCommError(s->hcom, &err, &comstat)) { > - fprintf(stderr, "Failed ClearCommError\n"); > + fprintf(stderr, "ClearCommError failed\n"); > goto fail; > } > qemu_add_polling_cb(win_chr_poll, chr); > @@ -2069,12 +2069,12 @@ static int win_chr_pipe_init(CharDriverState *chr, > const char *filename) > > s->hsend = CreateEvent(NULL, TRUE, FALSE, NULL); > if (!s->hsend) { > - fprintf(stderr, "Failed CreateEvent\n"); > + fprintf(stderr, "CreateEvent failed\n"); > goto fail; > } > s->hrecv = CreateEvent(NULL, TRUE, FALSE, NULL); > if (!s->hrecv) { > - fprintf(stderr, "Failed CreateEvent\n"); > + fprintf(stderr, "CreateEvent failed\n"); > goto fail; > } > > @@ -2084,7 +2084,7 @@ static int win_chr_pipe_init(CharDriverState *chr, > const char *filename) > PIPE_WAIT, > MAXCONNECT, NSENDBUF, NRECVBUF, NTIMEOUT, > NULL); > if (s->hcom == INVALID_HANDLE_VALUE) { > - fprintf(stderr, "Failed CreateNamedPipe (%lu)\n", GetLastError()); > + fprintf(stderr, "CreateNamedPipe (%lu) failed\n", GetLastError()); > s->hcom = NULL; > goto fail; > } > @@ -2093,13 +2093,13 @@ static int win_chr_pipe_init(CharDriverState *chr, > const char *filename) > ov.hEvent = CreateEvent(NULL, TRUE, FALSE, NULL); > ret = ConnectNamedPipe(s->hcom, &ov); > if (ret) { > - fprintf(stderr, "Failed ConnectNamedPipe\n"); > + fprintf(stderr, "ConnectNamedPipe failed\n"); > goto fail; > } > > ret = GetOverlappedResult(s->hcom, &ov, &size, TRUE); > if (!ret) { > - fprintf(stderr, "Failed GetOverlappedResult\n"); > + fprintf(stderr, "GetOverlappedResult failed\n"); > if (ov.hEvent) { > CloseHandle(ov.hEvent); > ov.hEvent = NULL; -- Alex Bennée