[IOT-1561] Improve vs12_snprintf
authorDan Mihai <Daniel.Mihai@microsoft.com>
Tue, 15 Nov 2016 08:23:04 +0000 (00:23 -0800)
committerDan Mihai <Daniel.Mihai@microsoft.com>
Thu, 24 Nov 2016 00:20:02 +0000 (00:20 +0000)
commit8125364b517a6b3f74d88fa1386bdeda9e8ab70e
treed80b31ac4246cfc14e6b53d970d12af18006c9e0
parent096373ae4a589f5f12951afdbd3d8004ae549f9f
[IOT-1561] Improve vs12_snprintf

Improve the snprintf surrogate used to build for Windows using Visual
Studio 2013 or older.

Also remove the dependency on cmake for building gtest for Windows, to
fix a build break for the new snprintf_test.cpp.

This is a cherry-pick of commit b2a398e from the 1.2-rel branch.

Change-Id: I70c9d0766a9a316a19cbd283671137e61ab88dbf
Signed-off-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/14387
Reviewed-by: Kevin Kane <kkane@microsoft.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Dave Thaler <dthaler@microsoft.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/14627
resource/c_common/windows/src/snprintf.c
resource/c_common/windows/test/SConscript [new file with mode: 0644]
resource/c_common/windows/test/snprintf_test.cpp [new file with mode: 0644]
resource/unit_tests.scons