From 4f192481eebcfb0c96285c9643fce31bde4a8c5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lukas=20W=C3=B6hrl?= Date: Thu, 17 Nov 2016 20:41:44 -0800 Subject: [PATCH] use size_t instead of unsigned long Summary: Use ```size_t```instead of ```unsinged long``` as this is the "offical" return type of ```strlen```. Is VS13 ```size_t``` is defined as ```unsigned long long``` which leads to a compiler warning. Closes https://github.com/facebook/css-layout/pull/254 Reviewed By: emilsjolander Differential Revision: D4199327 Pulled By: splhack fbshipit-source-id: 5e1a91f282bf776e4d9f5806e6467dfe36c7a633 --- CSSLayout/CSSLayout.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CSSLayout/CSSLayout.c b/CSSLayout/CSSLayout.c index 461bb78b..e656eeb7 100644 --- a/CSSLayout/CSSLayout.c +++ b/CSSLayout/CSSLayout.c @@ -2173,7 +2173,7 @@ bool gPrintSkips = false; static const char *spacer = " "; static const char *getSpacer(const unsigned long level) { - const unsigned long spacerLen = strlen(spacer); + const size_t spacerLen = strlen(spacer); if (level > spacerLen) { return &spacer[0]; } else {