Commit Graph

4592 Commits

Author SHA1 Message Date
James Turner
19df18fefb Use wide-string APIs on Windows.
SGPath and simgear::Dir use ‘w’ versions of POSIX APIs on Windows,
and convert UTF-8 SGPath to wide-strings as part of this.

Includes improved unit-tests for this code, with some very basic
tests of creating and iterating files with Unicode characters in
their names.

No user-visible changes should result from this, on any platform; in
particular wide-string support is still incomplete so FlightGear will
not yet work with arbitrary Unicode paths on Windows.
2016-07-15 09:50:44 +01:00
James Turner
a5a4bf6d41 Another HLA/SGPath fix 2016-07-04 09:31:34 +01:00
James Turner
9812315d96 realpath returns a path, not a string. 2016-07-04 09:04:46 +01:00
James Turner
c40044feeb Fix HLAFederate for readXML API change 2016-07-04 07:20:23 +01:00
James Turner
a636da6959 SGPath in easyXML API 2016-07-03 23:41:07 +01:00
James Turner
ca84d2046a Fix sg_gzofstream path type (now SGPath) 2016-07-03 23:05:42 +01:00
James Turner
c037a0e461 Windows string conversion for SGPath 2016-07-03 22:56:04 +01:00
Bertrand Coconnier
5ab595b401 The Shlwapi library is now needed for the Windows build (required in simgear/misc/sg_dir.cxx which calls to PathIsDirectoryEmpty) 2016-07-03 14:36:22 +02:00
Bertrand Coconnier
7e06e5382a One (last?) fix for compilation errors with MSVC++ 2016-07-03 12:38:56 +02:00
Bertrand Coconnier
d3c5c45262 Fixed compilation errors with MSVC++ 2016-07-03 11:53:23 +02:00
Erik Hofman
efa1292b2d Fix a compiler wrning 2016-07-03 09:44:04 +02:00
Erik Hofman
98de216878 No need to count all 150 or so entries, 3 is enough 2016-07-03 09:39:52 +02:00
Erik Hofman
82a9491de4 Much shorter version of Dir::isEmpty() 2016-07-03 09:35:03 +02:00
Erik Hofman
b23e9a3424 Detect the actual number of wchars required for the buffer and allocate it properly 2016-07-03 09:34:19 +02:00
Erik Hofman
0e62c11fd0 AeonWave based sound manager 2016-07-03 09:03:37 +02:00
Erik Hofman
5b54481555 Merge branch 'next' of ssh://git.code.sf.net/p/flightgear/simgear into next 2016-07-02 11:07:11 +02:00
Erik Hofman
f4344c5c6a Fix directory creation: 'ds' remains the same while 'dir' gets updated so use 'dir' instead 2016-07-02 11:06:36 +02:00
Erik Hofman
372dead21a Convert _filename to an SGPath 2016-07-02 11:03:32 +02:00
James Turner
cf18d4eaaf SGPath can convert to std::wstring 2016-07-02 09:34:27 +01:00
James Turner
32735428bb More SGPath APIs 2016-07-01 17:14:34 +01:00
James Turner
b862cf7e54 Fix repository test. 2016-07-01 09:02:52 +01:00
James Turner
f21eac8473 Building with clean SGPath API 2016-06-30 16:17:52 +01:00
James Turner
38c8931950 Fix debug runtime assert 2016-06-29 16:26:42 +01:00
James Turner
cfe1c0933f Further SG stream APIs 2016-06-27 12:29:23 -05:00
Erik Hofman
a8d8158fac Properly et frequency, format and buffer size 2016-06-27 13:19:37 +02:00
Erik Hofman
2321d9783d Move the isNaN function to soundmgr_openal_private.hxx to make it avaiable for the soundmanager too 2016-06-27 12:35:58 +02:00
James Turner
a3b3280123 iostream overloads taking an SGPath 2016-06-25 16:30:24 +01:00
James Turner
8cfe5a2e08 Native SGPath API on SGInterpTable
- string-based version will be removed in the future.
2016-06-23 15:21:26 +01:00
James Turner
bd896096cc Changing SGPath APIs, using SGPath in more places.
Change most places we control (i.e not helper libs) to use SGPath
to represent a path, instead of using std::string. Extend SGPath
API to explicitly expose the path in either UTF-8 or the
system 8-bit encoding.
2016-06-22 17:15:32 +01:00
James Turner
855ff5a8b0 Fix Linux compilation of untar.hxx 2016-06-16 04:46:37 -05:00
James Turner
e695505e62 Tests for un-tar code. 2016-06-15 22:27:01 +01:00
James Turner
f824cf85a4 Fix Untar namespacing. 2016-06-14 15:13:58 +01:00
James Turner
fb8b60b6fe Export untar header
Needed for scenery installation helper.
2016-06-14 15:12:20 +01:00
James Turner
516d76d41b VS215 tweaks, warning fixes 2016-06-09 20:38:01 +01:00
Jasin Colegrove
d0e31c5cf5 Use STD_ERROR_HANDLE since SG_LOG uses stderr stream
Fixed spacing, cleaned up uneccessary #ifdef's
2016-06-09 14:27:56 -04:00
James Turner
daa10503e6 Fixes to Windows console interaction.
Thanks To Jasin Colegrove for helping me understand the issues here!
2016-06-09 15:11:44 +01:00
Thomas Geymayer
1c25d343a0 Fix missing throw. 2016-06-09 13:03:40 +02:00
James Turner
c762dbe864 Fix dependency on ‘version’ file. 2016-06-09 11:03:35 +01:00
James Turner
37c551bae7 Fix for HTTP/curl waiting on update
This improves responsiveness of TerraSync with small files and general
throughout dramatically.
2016-06-08 15:43:59 +01:00
James Turner
0ccf3e1629 Threadsafe terrasync state updates/reading. 2016-06-08 15:27:47 +01:00
Erik Hofman
da1aeece14 Merge branch 'next' of ssh://git.code.sf.net/p/flightgear/simgear into next 2016-06-07 21:51:21 +02:00
Erik Hofman
c722f90848 Only throw an expection if buf == NULL.. 2016-06-07 12:59:16 +02:00
James Turner
5ba9004853 More repository test tweaks for Jenkins. 2016-06-07 11:24:01 +01:00
Erik Hofman
dc1696dfd5 Throw an exception when the current working directory can not be retrieved 2016-06-07 11:51:28 +02:00
James Turner
cb80af0ebe Improving channel lifetime in HTTP-based tests.
Previously, closed channels were not cleaned up, which looks to be
the caused of the test failures on Jenkins.
2016-06-06 17:26:50 +01:00
James Turner
1492de4391 Fix a leak / potential crash 2016-06-06 11:36:47 +01:00
James Turner
fad905e7e0 Increase test timeout value.
- investigating failing tests on Jenkins
2016-06-03 15:26:48 +01:00
James Turner
fb1b1b9c5e Fix uninitialized var 2016-06-03 08:44:25 -05:00
James Turner
b7b304ecfb Fix a warning with GCC 2016-06-03 08:40:55 -05:00
James Turner
8690e4617f CMake tweaks for MSVC detection 2016-06-03 12:19:21 +01:00