Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-ports-kde
Path: blob/main/emulators/aranym/files/patch-src_natfeat_hostfs.cpp
16461 views
1
- backport of patch to fix https://github.com/aranym/aranym/issues/77
2
3
--- src/natfeat/hostfs.cpp.orig 2019-04-14 14:11:29 UTC
4
+++ src/natfeat/hostfs.cpp
5
@@ -2872,7 +2872,22 @@ int32 HostFs::xfs_native_init( int16 devnum, memptr mo
6
* for drivers that are not running under mint,
7
* report our current timezone (in the filesys.res1 field)
8
*/
9
+#if defined(__FreeBSD__) || 1
10
+ /*
11
+ * FreeBSD does not have that global variable.
12
+ * Maybe others, too.
13
+ */
14
+ {
15
+ time_t t;
16
+ int32_t offset;
17
+
18
+ t = time(0);
19
+ offset = -gmtoff(t);
20
+ WriteInt32(filesys + 136, offset);
21
+ }
22
+#else
23
WriteInt32(filesys + 136, timezone);
24
+#endif
25
26
int16 dnum = -1;
27
size_t len = strlen( fmountPoint );
28
29