All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stefan Weil <weil@mail.berlios.de>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: Blue Swirl <blauwirbel@gmail.com>, qemu-devel@nongnu.org
Subject: [Qemu-devel] Re: [PATCH] w32: Add missing functions qemu_mutex_destroy, qemu_cond_destroy
Date: Fri, 18 Mar 2011 23:39:50 +0100	[thread overview]
Message-ID: <4D83DF36.5020903@mail.berlios.de> (raw)
In-Reply-To: <1300039252-27156-1-git-send-email-weil@mail.berlios.de>

Am 13.03.2011 19:00, schrieb Stefan Weil:
> These functions were missing in commit
> 9257d46d55f1fe4e8209be9a6870e339ac3266fe.
>
> Both functions are needed for compilations with
> configuration --enable-vnc-thread.
>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Blue Swirl <blauwirbel@gmail.com>
> Signed-off-by: Stefan Weil <weil@mail.berlios.de>
> ---
> qemu-thread-win32.c | 21 +++++++++++++++++++++
> 1 files changed, 21 insertions(+), 0 deletions(-)
>
> diff --git a/qemu-thread-win32.c b/qemu-thread-win32.c
> index 2edcb1a..2d2d5ab 100644
> --- a/qemu-thread-win32.c
> +++ b/qemu-thread-win32.c
> @@ -33,6 +33,12 @@ void qemu_mutex_init(QemuMutex *mutex)
> InitializeCriticalSection(&mutex->lock);
> }
>
> +void qemu_mutex_destroy(QemuMutex *mutex)
> +{
> + assert(mutex->owner == 0);
> + DeleteCriticalSection(&mutex->lock);
> +}
> +
> void qemu_mutex_lock(QemuMutex *mutex)
> {
> EnterCriticalSection(&mutex->lock);
> @@ -80,6 +86,21 @@ void qemu_cond_init(QemuCond *cond)
> }
> }
>
> +void qemu_cond_destroy(QemuCond *cond)
> +{
> + BOOL result;
> + result = CloseHandle(cond->continue_event);
> + if (!result) {
> + error_exit(GetLastError(), __func__);
> + }
> + cond->continue_event = 0;
> + result = CloseHandle(cond->sema);
> + if (!result) {
> + error_exit(GetLastError(), __func__);
> + }
> + cond->sema = 0;
> +}
> +
> void qemu_cond_signal(QemuCond *cond)
> {
> DWORD result;

No comments? Why is is so difficult to get compilation problems fixed?

  reply	other threads:[~2011-03-18 22:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-13 18:00 [Qemu-devel] [PATCH] w32: Add missing functions qemu_mutex_destroy, qemu_cond_destroy Stefan Weil
2011-03-18 22:39 ` Stefan Weil [this message]
2011-03-19  8:38   ` [Qemu-devel] " Blue Swirl

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=4D83DF36.5020903@mail.berlios.de \
    --to=weil@mail.berlios.de \
    --cc=blauwirbel@gmail.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.