From: Carl Hetherington Date: Mon, 12 Sep 2016 10:13:40 +0000 (+0100) Subject: Try to normalise use of int64/long int across raw/locale convert. X-Git-Tag: v1.4.0~22 X-Git-Url: https://git.carlh.net/gitweb/?a=commitdiff_plain;h=141ab2fa29b5816c1b9eef46b85e146f73178b1b;p=libdcp.git Try to normalise use of int64/long int across raw/locale convert. --- diff --git a/src/locale_convert.cc b/src/locale_convert.cc index fc156244..129ee50f 100644 --- a/src/locale_convert.cc +++ b/src/locale_convert.cc @@ -185,11 +185,11 @@ dcp::locale_convert (string x, int, bool) } template<> -int64_t +long int dcp::locale_convert (string x, int, bool) { - int64_t y = 0; - sscanf (x.c_str(), "%" PRId64, &y); + long int y = 0; + sscanf (x.c_str(), "%ld", &y); return y; } diff --git a/src/locale_convert.h b/src/locale_convert.h index 760e1068..05728409 100644 --- a/src/locale_convert.h +++ b/src/locale_convert.h @@ -112,7 +112,7 @@ int locale_convert (std::string x, int, bool); template <> -int64_t +long int locale_convert (std::string x, int, bool); template <>