All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alex Bennée" <alex.bennee@linaro.org>
To: John Snow <jsnow@redhat.com>
Cc: peter.maydell@linaro.org, imammedo@redhat.com,
	qemu-devel@nongnu.org, pbonzini@redhat.com
Subject: Re: [Qemu-devel] [PATCH 2/2] glib: remove stale compat functions
Date: Fri, 22 May 2015 08:05:52 +0100	[thread overview]
Message-ID: <871ti9hz1r.fsf@linaro.org> (raw)
In-Reply-To: <1431469140-22208-3-git-send-email-jsnow@redhat.com>


John Snow <jsnow@redhat.com> writes:

> Since we're bumping the version to 2.22+,
> remove the now-stale compat functions.
>
> Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>

> ---
>  include/glib-compat.h | 35 -----------------------------------
>  1 file changed, 35 deletions(-)
>
> diff --git a/include/glib-compat.h b/include/glib-compat.h
> index 28d9f15..318e000 100644
> --- a/include/glib-compat.h
> +++ b/include/glib-compat.h
> @@ -23,14 +23,6 @@
>  #define G_TIME_SPAN_SECOND              (G_GINT64_CONSTANT(1000000))
>  #endif
>  
> -#if !GLIB_CHECK_VERSION(2, 14, 0)
> -static inline guint g_timeout_add_seconds(guint interval, GSourceFunc function,
> -                                          gpointer data)
> -{
> -    return g_timeout_add(interval * 1000, function, data);
> -}
> -#endif
> -
>  #if !GLIB_CHECK_VERSION(2, 28, 0)
>  static inline gint64 qemu_g_get_monotonic_time(void)
>  {
> @@ -47,23 +39,6 @@ static inline gint64 qemu_g_get_monotonic_time(void)
>  #define g_get_monotonic_time() qemu_g_get_monotonic_time()
>  #endif
>  
> -#if !GLIB_CHECK_VERSION(2, 16, 0)
> -static inline int g_strcmp0(const char *str1, const char *str2)
> -{
> -    int result;
> -
> -    if (!str1) {
> -        result = -(str1 != str2);
> -    } else if (!str2) {
> -        result = (str1 != str2);
> -    } else {
> -        result = strcmp(str1, str2);
> -    }
> -
> -    return result;
> -}
> -#endif
> -
>  #ifdef _WIN32
>  /*
>   * g_poll has a problem on Windows when using
> @@ -71,16 +46,6 @@ static inline int g_strcmp0(const char *str1, const char *str2)
>   */
>  #define g_poll(fds, nfds, timeout) g_poll_fixed(fds, nfds, timeout)
>  gint g_poll_fixed(GPollFD *fds, guint nfds, gint timeout);
> -#elif !GLIB_CHECK_VERSION(2, 20, 0)
> -/*
> - * Glib before 2.20.0 doesn't implement g_poll, so wrap it to compile properly
> - * on older systems.
> - */
> -static inline gint g_poll(GPollFD *fds, guint nfds, gint timeout)
> -{
> -    GMainContext *ctx = g_main_context_default();
> -    return g_main_context_get_poll_func(ctx)(fds, nfds, timeout);
> -}
>  #endif
>  
>  #if !GLIB_CHECK_VERSION(2, 31, 0)

-- 
Alex Bennée

  reply	other threads:[~2015-05-22  7:05 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-12 22:18 [Qemu-devel] [PATCH 0/2] configure: increase glib requirement to 2.22 John Snow
2015-05-12 22:18 ` [Qemu-devel] [PATCH 1/2] configure: require glib 2.22 John Snow
2015-05-22  7:04   ` Alex Bennée
2015-05-12 22:19 ` [Qemu-devel] [PATCH 2/2] glib: remove stale compat functions John Snow
2015-05-22  7:05   ` Alex Bennée [this message]
2015-05-13  7:18 ` [Qemu-devel] [PATCH 0/2] configure: increase glib requirement to 2.22 Markus Armbruster
2015-05-13  9:33 ` Paolo Bonzini
2015-05-21 18:17   ` John Snow

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=871ti9hz1r.fsf@linaro.org \
    --to=alex.bennee@linaro.org \
    --cc=imammedo@redhat.com \
    --cc=jsnow@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=peter.maydell@linaro.org \
    --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.