]> git.mxchange.org Git - simgear.git/log
simgear.git
10 years agoHTTPFileRequest: only save file if status == 200
Thomas Geymayer [Mon, 30 Dec 2013 00:31:47 +0000 (01:31 +0100)]
HTTPFileRequest: only save file if status == 200

10 years agoBugfix: remove SGSky minimum distance check.
James Turner [Thu, 19 Dec 2013 17:20:06 +0000 (17:20 +0000)]
Bugfix: remove SGSky minimum distance check.

Without this, various sky rendering modes exhibit artefacts in low-
visibility conditions. The cost of always rendering the dome is
negligible. (And Rembrandt already had to work this way)

10 years agoFix test failure on char-unsigned-by-default architectures (eg. ARM)
Rebecca Palmer [Wed, 27 Nov 2013 17:00:05 +0000 (17:00 +0000)]
Fix test failure on char-unsigned-by-default architectures (eg. ARM)

(from http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=722115 )

10 years agoFix buffer overflow CVE-2012-2091 (thanks to Saikrishna Arcot)
Rebecca Palmer [Tue, 17 Dec 2013 17:40:33 +0000 (17:40 +0000)]
Fix buffer overflow CVE-2012-2091 (thanks to Saikrishna Arcot)

https://bugs.launchpad.net/ubuntu/+source/simgear/+bug/1077624
(discussed in comments 65-78)
(This is already fixed in 2.12 but appears to have been forgotten in 2.99;
the other vulnerabilities described there are already fixed.)

10 years agoSecurity: fix 0777 directory permissions to 0755.
James Turner [Thu, 19 Dec 2013 14:56:23 +0000 (14:56 +0000)]
Security: fix 0777 directory permissions to 0755.

10 years agoFix a typo breaking Mac build.
James Turner [Sun, 15 Dec 2013 20:55:02 +0000 (20:55 +0000)]
Fix a typo breaking Mac build.

10 years agoReset: clear some property references.
James Turner [Sun, 15 Dec 2013 20:48:07 +0000 (20:48 +0000)]
Reset: clear some property references.

10 years agoSGPath: some tweaks/fixes/typo on permission checker.
Thomas Geymayer [Thu, 12 Dec 2013 20:25:13 +0000 (21:25 +0100)]
SGPath: some tweaks/fixes/typo on permission checker.

10 years agoSGPath: add support for custom PermissionChecker
Thomas Geymayer [Thu, 12 Dec 2013 20:03:24 +0000 (21:03 +0100)]
SGPath: add support for custom PermissionChecker

Allow to add permission checks (read/write-access) for
eg. limiting access based on IORules.

10 years agoReset: alternate property copying strategy.
James Turner [Tue, 10 Dec 2013 17:37:37 +0000 (17:37 +0000)]
Reset: alternate property copying strategy.

Search the tree for leaves / sub-trees with a particular attribute set.
This permits both sparse selection as well as selection by sub-tree.

(This is needed for PRESERVE attribute, and once new reset is switched
on, will enable 'normal' copyProperties to revert to ignoring
attributes completely)

10 years agoQuiet a message.
James Turner [Mon, 9 Dec 2013 23:28:40 +0000 (23:28 +0000)]
Quiet a message.

10 years agoCanvas: one global SystemAdapter is enough.
Thomas Geymayer [Mon, 9 Dec 2013 22:05:31 +0000 (23:05 +0100)]
Canvas: one global SystemAdapter is enough.

This also fixes elements requiring a SystemAdapter without
being assigned to a Canvas (eg. because they are desktop
elements).

10 years agoAdd ListDiff helper (for fast array differences).
Thomas Geymayer [Sun, 8 Dec 2013 17:48:19 +0000 (18:48 +0100)]
Add ListDiff helper (for fast array differences).

10 years agoFix some unused/uninitialized variables.
Thomas Geymayer [Sat, 7 Dec 2013 12:43:17 +0000 (13:43 +0100)]
Fix some unused/uninitialized variables.

10 years agoSGPropertyNode: add removeAllChildren() method
Thomas Geymayer [Sat, 7 Dec 2013 12:42:15 +0000 (13:42 +0100)]
SGPropertyNode: add removeAllChildren() method

10 years agoCanvas: ensure all canvasses are destroyed
Thomas Geymayer [Sat, 7 Dec 2013 12:40:22 +0000 (13:40 +0100)]
Canvas: ensure all canvasses are destroyed

 - For shutdown/reset make sure all properties describing a canvas
   are removed and also not restored after the reset.

10 years agoWork around apparent OSG 3.2.0 normal binding bug.
Stuart Buchanan [Fri, 6 Dec 2013 22:12:52 +0000 (22:12 +0000)]
Work around apparent OSG 3.2.0 normal binding bug.

10 years agoPagedLOD for random trees, buildings and objects.
Stuart Buchanan [Fri, 6 Dec 2013 20:20:46 +0000 (20:20 +0000)]
PagedLOD for random trees, buildings and objects.

10 years agoCanvas: clear elements in shutdown()
James Turner [Fri, 6 Dec 2013 18:14:48 +0000 (18:14 +0000)]
Canvas: clear elements in shutdown()

- without this change, elements aren't un-ref-ed and hence destroyed
until the actual dtor runs, which is too late (other systems may be
destroyed already)

10 years agoWork around a clang/libc++ issue.
James Turner [Fri, 6 Dec 2013 18:03:35 +0000 (18:03 +0000)]
Work around a clang/libc++ issue.

10 years agocppbind: don't leak nasal references for Ghost methods.
Thomas Geymayer [Wed, 4 Dec 2013 10:15:11 +0000 (11:15 +0100)]
cppbind: don't leak nasal references for Ghost methods.

10 years agoReset: hook to clear the effects cache.
James Turner [Wed, 4 Dec 2013 09:12:37 +0000 (09:12 +0000)]
Reset: hook to clear the effects cache.

10 years agoReset: don't leak EffectPropertyListener.
James Turner [Tue, 3 Dec 2013 21:34:23 +0000 (21:34 +0000)]
Reset: don't leak EffectPropertyListener.

Track and free listeners from effect expressions.

10 years agoImplement UTF-8 to Latin1 converter
Clément de l'Hamaide [Sun, 1 Dec 2013 17:47:49 +0000 (18:47 +0100)]
Implement UTF-8 to Latin1 converter

10 years agocppbind: Fix detecting derived Ghosts
Thomas Geymayer [Sun, 1 Dec 2013 11:34:26 +0000 (12:34 +0100)]
cppbind: Fix detecting derived Ghosts

10 years agocppbind: make ghost_type static to keep same pointer on reset.
Thomas Geymayer [Sun, 1 Dec 2013 00:18:13 +0000 (01:18 +0100)]
cppbind: make ghost_type static to keep same pointer on reset.

Using a static naGhostType ensures that always the same
address is used for the same ghost and prevents ghost_types
from getting invalid (eg. on reset).

11 years agoCanvas: allow removing placement factories.
Thomas Geymayer [Sun, 24 Nov 2013 14:37:36 +0000 (15:37 +0100)]
Canvas: allow removing placement factories.

11 years agoFixed a crash: the singleton needs to be instantiated the first time SGCommandMgr...
bcoconni [Sun, 24 Nov 2013 13:50:11 +0000 (14:50 +0100)]
Fixed a crash: the singleton needs to be instantiated the first time SGCommandMgr::instance() is called

11 years agoAdded more explicit error messages to the property lists parser.
bcoconni [Sun, 24 Nov 2013 11:20:26 +0000 (12:20 +0100)]
Added more explicit error messages to the property lists parser.
More specifically, each time an error or a warning is issued the location of the corresponding XML tag (file name an line number) is reported.

11 years agoReset: allow re-init of Nasal Ghosts.
James Turner [Sat, 23 Nov 2013 20:06:47 +0000 (20:06 +0000)]
Reset: allow re-init of Nasal Ghosts.

After discussion with Thomas, reset needs the scenario this assert
was designed to guard against, so removing it for now.

11 years agoAllow Command-manager singleton to be deleted.
James Turner [Sat, 23 Nov 2013 20:00:23 +0000 (20:00 +0000)]
Allow Command-manager singleton to be deleted.

(Shutdown can delete commands in an orderly way)

11 years agoFix another SVN crash on failure.
James Turner [Tue, 19 Nov 2013 21:33:14 +0000 (21:33 +0000)]
Fix another SVN crash on failure.

11 years agoRepository name preferred
Martin Spott [Sat, 16 Nov 2013 18:44:17 +0000 (10:44 -0800)]
Repository name preferred

11 years agoGive terrasync a custom HTTP UA.
James Turner [Sat, 16 Nov 2013 09:45:40 +0000 (09:45 +0000)]
Give terrasync a custom HTTP UA.

11 years agoFix some SVN errors/crashes.
James Turner [Sat, 9 Nov 2013 15:22:15 +0000 (07:22 -0800)]
Fix some SVN errors/crashes.

11 years agoRemoved the 'using::std' instructions from the headers as per James Turner request.
bcoconni [Mon, 11 Nov 2013 18:06:44 +0000 (19:06 +0100)]
Removed the 'using::std' instructions from the headers as per James Turner request.
Also took this opportunity to add a check in XMLVisitor::savePosition() against a null pointer.

11 years agoAdded the ability to access the file name and position (line, column) from which...
bcoconni [Sun, 10 Nov 2013 15:50:59 +0000 (16:50 +0100)]
Added the ability to access the file name and position (line, column) from which the XML visitor is getting its data

11 years agoapt_signs: lower the log level for apt.dat syntax errors. Nobody seems to care...
Christian Schmitt [Thu, 14 Nov 2013 17:40:14 +0000 (18:40 +0100)]
apt_signs: lower the log level for apt.dat syntax errors. Nobody seems to care...

11 years agoReset: use ref-counting to own subsystems.
James Turner [Tue, 5 Nov 2013 05:17:22 +0000 (05:17 +0000)]
Reset: use ref-counting to own subsystems.

Change the subsystem-group and manager code to use shared-ptr references
to subsystems, instead of holding a raw pointer. Hence the manager becomes
the owning ref to most subsystems.

11 years agoReset: Terrasync root can change, can be shutdown.
James Turner [Sun, 6 Oct 2013 17:08:33 +0000 (19:08 +0200)]
Reset: Terrasync root can change, can be shutdown.

11 years agoReset: clean event-manager shutdown
James Turner [Tue, 12 Nov 2013 22:20:21 +0000 (22:20 +0000)]
Reset: clean event-manager shutdown

11 years agoReset: DeletionManager can be uninstalled
James Turner [Mon, 11 Nov 2013 07:02:24 +0000 (23:02 -0800)]
Reset: DeletionManager can be uninstalled

11 years agoRemove exceptions on missing texture names
James Turner [Mon, 11 Nov 2013 07:02:10 +0000 (23:02 -0800)]
Remove exceptions on missing texture names

11 years agoString case conversion, UTF-8 conversion.
James Turner [Thu, 7 Nov 2013 18:36:12 +0000 (10:36 -0800)]
String case conversion, UTF-8 conversion.

11 years agoCanvasElement: ensure parent pointer can not become invalid.
Thomas Geymayer [Sun, 10 Nov 2013 16:12:50 +0000 (17:12 +0100)]
CanvasElement: ensure parent pointer can not become invalid.

11 years agotrack-to animation: fix "short" and "long" tracking.
Thomas Geymayer [Sun, 10 Nov 2013 10:14:50 +0000 (11:14 +0100)]
track-to animation: fix "short" and "long" tracking.

11 years agotrack-to animation: 2dof rotation for slave object.
Thomas Geymayer [Thu, 7 Nov 2013 23:45:24 +0000 (00:45 +0100)]
track-to animation: 2dof rotation for slave object.

Slave objects can now rotate around two axis to always track the
target - even when it is outside the plane perpendicular to the
lock-axis of the root object. This allows for example animating
levers with non-parallel axis of rotation connected with a rod.

11 years agoTweak HTTP code to always sleep.
James Turner [Wed, 6 Nov 2013 23:11:46 +0000 (15:11 -0800)]
Tweak HTTP code to always sleep.

Check explicitly for the 'no channels' case and
sleep instead, to avoid busy-waiting. (This is a work-
around, the underlying issue still be be traced)

11 years agoReset: pin ctor and dtor of event manager.
James Turner [Tue, 5 Nov 2013 05:16:50 +0000 (05:16 +0000)]
Reset: pin ctor and dtor of event manager.

11 years agoReset: commands can be removed
James Turner [Tue, 5 Nov 2013 05:17:05 +0000 (05:17 +0000)]
Reset: commands can be removed

11 years agoTerraSync: avoid assert on missing file
James Turner [Tue, 5 Nov 2013 05:17:46 +0000 (05:17 +0000)]
TerraSync: avoid assert on missing file

11 years agoMake new gcc happy (include cmath)
Thomas Geymayer [Mon, 4 Nov 2013 09:48:26 +0000 (10:48 +0100)]
Make new gcc happy (include cmath)

11 years agoCanvas: improved clipping and new property clip-frame.
Thomas Geymayer [Sun, 3 Nov 2013 19:12:45 +0000 (20:12 +0100)]
Canvas: improved clipping and new property clip-frame.

 - Update clipping rect if canvas view or texture size
   changes.
 - Add new property "clip-frame" to specify coordinate
   frame for "clip" coordinates. Coordinates can be
   global, relative to the parent or relative to the
   element itself.

11 years agoSGPropertyNode: extract enum value with getValue
Thomas Geymayer [Sun, 3 Nov 2013 19:11:06 +0000 (20:11 +0100)]
SGPropertyNode: extract enum value with getValue

11 years agoHTTP: finish core request before calling any callback.
Thomas Geymayer [Mon, 28 Oct 2013 19:34:11 +0000 (20:34 +0100)]
HTTP: finish core request before calling any callback.

11 years agoTerrasync: don't busy wait when no requests are running.
James Turner [Mon, 28 Oct 2013 14:51:36 +0000 (14:51 +0000)]
Terrasync: don't busy wait when no requests are running.

11 years agoHTTPFileRequest: create directory if it does not exist
Thomas Geymayer [Mon, 28 Oct 2013 11:38:39 +0000 (12:38 +0100)]
HTTPFileRequest: create directory if it does not exist

11 years agoHTTP: Rename urlretrieve/urlload to save/load.
Thomas Geymayer [Sun, 27 Oct 2013 22:38:46 +0000 (23:38 +0100)]
HTTP: Rename urlretrieve/urlload to save/load.

11 years agoio: refactor and improve HTTP modules.
Thomas Geymayer [Sun, 27 Oct 2013 17:40:14 +0000 (18:40 +0100)]
io: refactor and improve HTTP modules.

 - refactor code used multiple times spread over sg/fg into
   one single location.
 - allow aborting requests.
 - Provide two common request types:
  * FileRequest: Save response into file
  * MemoryRequest: Keep resonse in memory (std::string)
 - extend HTTP::Client interface:
  * urlretrieve: Save url to file (shortcut for making a
                 FileRequest)
  * urlload: Get respons into memory (shortcut for making
             a MemoryRequest)

11 years agoNew class simgear::Map extending std::map interface.
Thomas Geymayer [Sun, 27 Oct 2013 17:37:19 +0000 (18:37 +0100)]
New class simgear::Map extending std::map interface.

11 years agoWindows logging changes
James Turner [Sat, 26 Oct 2013 20:04:16 +0000 (21:04 +0100)]
Windows logging changes

- can log to the debugger (MSVC output window) via OutputDebugStr
- logging to the console is optional, triggered by new
  requestConsole hook()

11 years agoFix handling of SGPath::rename
James Turner [Sat, 26 Oct 2013 20:03:00 +0000 (21:03 +0100)]
Fix handling of SGPath::rename

Windows handling of ::rename differs from POSIX when the new name
exists. Check for this case on Windows and remove the file manually.
(This allows a work-around in SVNDirectory to be removed)

11 years agocppbind: automatic conversion of SGReferenced derived pointers.
Thomas Geymayer [Fri, 25 Oct 2013 22:40:52 +0000 (00:40 +0200)]
cppbind: automatic conversion of SGReferenced derived pointers.

11 years agoAdd total bytes downloaded tracking.
James Turner [Thu, 24 Oct 2013 22:35:34 +0000 (23:35 +0100)]
Add total bytes downloaded tracking.

11 years agocanvas::Element: add getter for parent element.
Thomas Geymayer [Wed, 23 Oct 2013 15:11:03 +0000 (17:11 +0200)]
canvas::Element: add getter for parent element.

11 years agoOoops, fix INSTALL rule.
James Turner [Wed, 23 Oct 2013 13:18:39 +0000 (14:18 +0100)]
Ooops, fix INSTALL rule.

We need the rule, just not the export, for now.

11 years agoComment out Cmake export experiments for now.
James Turner [Tue, 22 Oct 2013 12:42:59 +0000 (13:42 +0100)]
Comment out Cmake export experiments for now.

This is breaking CMake 2.6, so commenting out for the moment, until
I understand how to support this portably.

11 years agoFix GPS activation on Windows.
James Turner [Mon, 21 Oct 2013 23:42:31 +0000 (00:42 +0100)]
Fix GPS activation on Windows.

Bug 1190, fix route-manager -> GPS activation on Windows
(and probably a couple of unrelated issues).
SGPropertyChangeCallback was missing a suitable copy-constructor,
leading to incorrect behaviour on compilers where the operation
is not elided. Such as MSVC.

11 years agoFix Dir warnings on Windows.
James Turner [Mon, 21 Oct 2013 22:51:19 +0000 (23:51 +0100)]
Fix Dir warnings on Windows.

Test result of GetLastError so we don't log a warning in the
'nothing matched' case. Makes early startup logging much
more pleasant, especially when scanning aircraft dirs.

11 years agoSmoother download rate from HTTP
James Turner [Mon, 21 Oct 2013 22:08:55 +0000 (23:08 +0100)]
Smoother download rate from HTTP

Crude filtering (low pass) of the download rate, over a 400msec
time window.

11 years agoFail HTTP request with missing/illegal protocols.
James Turner [Sun, 20 Oct 2013 22:20:49 +0000 (23:20 +0100)]
Fail HTTP request with missing/illegal protocols.

Instead of throwing, run the failure handler for requests with
either a missing spec or something other than http:// (eg, https
or ftp)

11 years agoPlacement can contain multiple nodes.
James Turner [Sun, 20 Oct 2013 19:44:42 +0000 (20:44 +0100)]
Placement can contain multiple nodes.

- Allow placement to have multiple children added.
- Remove legacy position setting APIs, enforce use of SGGeod

11 years agoAdd SGPropertyNode::setValueReadOnly.
Thomas Geymayer [Sun, 20 Oct 2013 10:03:41 +0000 (12:03 +0200)]
Add SGPropertyNode::setValueReadOnly.

Helper to set value of relative node and mark
read only. Use eg. for exposing configuration
and build values to the property tree.

11 years agoAvoid a divide-by-zero on malformed BTG files.
James Turner [Thu, 17 Oct 2013 19:13:36 +0000 (20:13 +0100)]
Avoid a divide-by-zero on malformed BTG files.

Encountered while testing v850 airports; some airports
generate materials with no tris, and hence no indices.
This causes a divide-by-zero when computing the index stride.

Detect this, and convert the BTG reader to throw exceptions
in error conditions, and to catch this and report the
appropriate result code.

11 years agoFix float-int conversion bug caught by Clang
James Turner [Thu, 17 Oct 2013 19:05:34 +0000 (20:05 +0100)]
Fix float-int conversion bug caught by Clang

11 years agoFix unused-var warnings from Clang.
James Turner [Thu, 17 Oct 2013 19:05:16 +0000 (20:05 +0100)]
Fix unused-var warnings from Clang.

11 years agoTerraysnc: don't block requests when inactive.
James Turner [Thu, 17 Oct 2013 16:29:06 +0000 (17:29 +0100)]
Terraysnc: don't block requests when inactive.

Add the same check for data files so we don't block when terrasync is
disabled.

11 years agoRe-order install(EXPORT ) lines.
James Turner [Thu, 17 Oct 2013 16:12:02 +0000 (17:12 +0100)]
Re-order install(EXPORT ) lines.

Certain cmake builds/versions complain when a dependent target is
exported but dependencies are not. Export SimGearCore before
SimGearScene.

11 years agoInitial work on syncing non-scenery data.
James Turner [Thu, 3 Oct 2013 20:42:18 +0000 (21:42 +0100)]
Initial work on syncing non-scenery data.

This is some initial pieces to synchronise other pieces of base
data than scenery via the sync mechanism. An additional sync slot is
added to avoid scenery or other data blocking each other.

11 years agoRemove some iostream debugging.
James Turner [Thu, 17 Oct 2013 15:33:13 +0000 (16:33 +0100)]
Remove some iostream debugging.

Accidentally committed this debug stuff, remove it.

11 years agoExport SimGear config to cmake.
James Turner [Thu, 17 Oct 2013 15:10:18 +0000 (16:10 +0100)]
Export SimGear config to cmake.

Experimenting with this, should make FindSimGear module unecessary,
and avoid mis-matched SG/FG cmake settings in the future.

11 years agoKill off EMBEDDED_SIMGEAR
James Turner [Thu, 17 Oct 2013 15:09:39 +0000 (16:09 +0100)]
Kill off EMBEDDED_SIMGEAR

11 years agoAdd helper to get osg::Node path as string.
Thomas Geymayer [Thu, 17 Oct 2013 11:28:54 +0000 (13:28 +0200)]
Add helper to get osg::Node path as string.

11 years agoNasal: do not print invalid elements for error backtraces.
Thomas Geymayer [Wed, 16 Oct 2013 21:33:06 +0000 (23:33 +0200)]
Nasal: do not print invalid elements for error backtraces.

11 years agoCanvas: simplify code by using new nasal function conversion.
Thomas Geymayer [Tue, 15 Oct 2013 15:42:49 +0000 (17:42 +0200)]
Canvas: simplify code by using new nasal function conversion.

11 years agocppbind: convert Nasal functions to C++ boost::function.
Thomas Geymayer [Tue, 15 Oct 2013 15:37:57 +0000 (17:37 +0200)]
cppbind: convert Nasal functions to C++ boost::function.

11 years agocppbind: fix bad class hierarchy for bad_nasal_cast.
Thomas Geymayer [Tue, 15 Oct 2013 14:37:50 +0000 (16:37 +0200)]
cppbind: fix bad class hierarchy for bad_nasal_cast.

11 years agoNasal: use correct function pointer in naCall (with user data)
Thomas Geymayer [Tue, 15 Oct 2013 12:21:45 +0000 (14:21 +0200)]
Nasal: use correct function pointer in naCall (with user data)

11 years agoNasal: recursive method calling.
Thomas Geymayer [Tue, 15 Oct 2013 10:05:09 +0000 (12:05 +0200)]
Nasal: recursive method calling.

New functions naCallMethodCtx and naCallMethod to replace
NasalSystem::callMethod from FlightGear. This has just added an
unneeded level of indirection and fits better directly into Nasal.
naSetErrorHandler can be used to register an error handler/logging
function.

11 years agoCanvas: use new naGCSave/naGCRelease functions.
Thomas Geymayer [Mon, 14 Oct 2013 22:49:13 +0000 (00:49 +0200)]
Canvas: use new naGCSave/naGCRelease functions.

11 years agoNasal: add naGCSave/naGCRelease for preventing objects being garbage collected.
Thomas Geymayer [Mon, 14 Oct 2013 22:19:32 +0000 (00:19 +0200)]
Nasal: add naGCSave/naGCRelease for preventing objects being garbage collected.

These new functions are meant to replace the gcSave/gcRelease
methods of the NasalSystem class in FlightGear, as passing an
adapter to SimGear from FlightGear is quite a lot of useless work
just for being able to save objects.

11 years agocppbind: add to_nasal_helper for enums.
Thomas Geymayer [Mon, 14 Oct 2013 21:03:36 +0000 (23:03 +0200)]
cppbind: add to_nasal_helper for enums.

11 years agoHTTP: check url for scheme and report instead of failing with assert.
Thomas Geymayer [Sun, 13 Oct 2013 10:06:17 +0000 (12:06 +0200)]
HTTP: check url for scheme and report instead of failing with assert.

11 years agoDon't let exceptions escape from commands.
Thomas Geymayer [Sun, 13 Oct 2013 10:00:52 +0000 (12:00 +0200)]
Don't let exceptions escape from commands.

11 years agocppbind: Catch exceptions before reaching C code.
Thomas Geymayer [Sun, 13 Oct 2013 09:37:17 +0000 (11:37 +0200)]
cppbind: Catch exceptions before reaching C code.

11 years agoCanvas: allow also C++ callable entities as event callbacks.
Thomas Geymayer [Fri, 11 Oct 2013 22:27:52 +0000 (00:27 +0200)]
Canvas: allow also C++ callable entities as event callbacks.

11 years agoAnother attempt to make MSVC happy!
James Turner [Wed, 9 Oct 2013 10:26:29 +0000 (12:26 +0200)]
Another attempt to make MSVC happy!

C89 requires variable declarations upfront.

11 years agoLinux needs <cstring>
James Turner [Wed, 9 Oct 2013 09:58:51 +0000 (11:58 +0200)]
Linux needs <cstring>

11 years agoFix MSVC build, no C99 so no round().
James Turner [Wed, 9 Oct 2013 09:52:54 +0000 (11:52 +0200)]
Fix MSVC build, no C99 so no round().

(Doesn't use SGMisc<T>::round, since Nasal is pure C)

11 years agoAvoid a data copy decoding base64 data.
James Turner [Sun, 6 Oct 2013 16:43:36 +0000 (18:43 +0200)]
Avoid a data copy decoding base64 data.

Use an out parameter to avoid a buffer alloc/copy/free cycle
when returning base64-decoded data.