Skip to content

Commit 2b30167

Browse files
authored
Merge pull request #844 from Unity-Technologies/unity-master-sync-il2cpp-fixes
Sync IL2CPP fixes for older MSVC
2 parents 454c8f0 + 2a3eb56 commit 2b30167

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

mono/eglib/gdir-unity.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,14 @@ GDir *
6060
g_dir_open (const gchar *path, guint flags, GError **error)
6161
{
6262
GDir *dir;
63+
gboolean success;
6364

6465
g_return_val_if_fail (path != NULL, NULL);
6566
g_return_val_if_fail (error == NULL || *error == NULL, NULL);
6667

6768
dir = g_new0 (GDir, 1);
6869

69-
gboolean success = setup_dir_handle(dir, path, error);
70+
success = setup_dir_handle(dir, path, error);
7071
if (!success)
7172
return NULL;
7273

mono/eglib/glib.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,10 @@
1414
#endif
1515

1616
#include <stdint.h>
17+
18+
#ifndef _MSC_VER // inttypes.h doesn't exist on VS2010
1719
#include <inttypes.h>
20+
#endif
1821

1922
#include <eglib-config.h>
2023
#ifndef EGLIB_NO_REMAP
@@ -44,6 +47,10 @@
4447
#define G_END_DECLS
4548
#endif
4649

50+
#if defined(_MSC_VER) && _MSC_VER < 1900
51+
#define inline __inline
52+
#endif
53+
4754
G_BEGIN_DECLS
4855

4956
/*

0 commit comments

Comments
 (0)