mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-02 17:26:17 +01:00
fix a few warnings on non-Linux
mostly #ifdeffing functions that are only called by #ifdeffed code
This commit is contained in:
parent
afa82ae805
commit
749fa587bc
@ -23,6 +23,7 @@
|
||||
|
||||
#include <config.h>
|
||||
#include <glib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "gsocketaddress.h"
|
||||
#include "ginetaddress.h"
|
||||
|
@ -479,7 +479,9 @@ _xdg_mime_magic_parse_magic_line (FILE *magic_file,
|
||||
/* We clean up the matchlet, byte swapping if needed */
|
||||
if (matchlet->word_size > 1)
|
||||
{
|
||||
#if LITTLE_ENDIAN
|
||||
int i;
|
||||
#endif
|
||||
if (matchlet->value_length % matchlet->word_size != 0)
|
||||
{
|
||||
_xdg_mime_magic_matchlet_free (matchlet);
|
||||
|
@ -1014,7 +1014,10 @@ write_to_temp_file (const gchar *contents,
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef BTRFS_SUPER_MAGIC
|
||||
no_fsync:
|
||||
#endif
|
||||
|
||||
errno = 0;
|
||||
if (fclose (file) == EOF)
|
||||
|
@ -27,6 +27,7 @@
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef __linux
|
||||
static void
|
||||
test_platform_argv0 (void)
|
||||
{
|
||||
@ -45,6 +46,7 @@ test_platform_argv0 (void)
|
||||
g_assert (strcmp (g_get_prgname(), "option-argv0") == 0
|
||||
|| strcmp (g_get_prgname (), "lt-option-argv0") == 0);
|
||||
}
|
||||
#endif
|
||||
|
||||
int
|
||||
main (int argc,
|
||||
|
Loading…
Reference in New Issue
Block a user