summaryrefslogtreecommitdiff
path: root/src/locale_convert.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2019-06-12 16:08:25 +0100
committerCarl Hetherington <cth@carlh.net>2019-06-12 16:08:25 +0100
commit4fa8274be83aeaa0c9503a778b2b17f673570723 (patch)
tree658eb50fb5aa73614dfeb455d2cf39e43a699fd5 /src/locale_convert.cc
parentb7c7e14463d91608b080a5a63fcfb4d330ced863 (diff)
Add another type to raw/locale convert.
Diffstat (limited to 'src/locale_convert.cc')
-rw-r--r--src/locale_convert.cc13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/locale_convert.cc b/src/locale_convert.cc
index 5164f89f..46d5507f 100644
--- a/src/locale_convert.cc
+++ b/src/locale_convert.cc
@@ -243,6 +243,19 @@ dcp::locale_convert (string x, int, bool)
}
template<>
+unsigned long
+dcp::locale_convert (string x, int, bool)
+{
+ unsigned long y = 0;
+#ifdef LIBDCP_WINDOWS
+ __mingw_sscanf (x.c_str(), "%lud", &y);
+#else
+ sscanf (x.c_str(), "%lud", &y);
+#endif
+ return y;
+}
+
+template<>
long long
dcp::locale_convert (string x, int, bool)
{