ext/glib2/rbglib_utf16.c in glib2-3.3.2 vs ext/glib2/rbglib_utf16.c in glib2-3.3.3
- old
+ new
@@ -1,8 +1,8 @@
/* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
/*
- * Copyright (C) 2011 Ruby-GNOME2 Project Team
+ * Copyright (C) 2011-2019 Ruby-GNOME2 Project Team
* Copyright (C) 2006 Kouhei Sutou
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
@@ -31,11 +31,11 @@
gunichar *ucs4;
gunichar2 *utf16;
glong len, items_written;
GError *error = NULL;
- utf16 = (gunichar2 *)StringValueCStr(rb_utf16);
+ utf16 = (gunichar2 *)(void *)StringValueCStr(rb_utf16);
len = RSTRING_LEN(rb_utf16) / sizeof(*utf16);
ucs4 = g_utf16_to_ucs4(utf16, len, NULL, &items_written, &error);
if (error)
@@ -53,10 +53,10 @@
gchar *utf8;
gunichar2 *utf16;
glong len, items_written;
GError *error = NULL;
- utf16 = (gunichar2 *)StringValueCStr(rb_utf16);
+ utf16 = (gunichar2 *)(void *)StringValueCStr(rb_utf16);
len = RSTRING_LEN(rb_utf16) / sizeof(*utf16);
utf8 = g_utf16_to_utf8(utf16, len, NULL, &items_written, &error);
if (error)