提交 99b1aaf2 编写于 作者: R Richard Levitte

On some operating systems, MAX is defined. Call ours OSSL_MAX instead

上级 53400da7
...@@ -151,7 +151,7 @@ static void _dopr(char **sbuffer, char **buffer, ...@@ -151,7 +151,7 @@ static void _dopr(char **sbuffer, char **buffer,
/* some handy macros */ /* some handy macros */
#define char_to_int(p) (p - '0') #define char_to_int(p) (p - '0')
#define MAX(p,q) ((p >= q) ? p : q) #define OSSL_MAX(p,q) ((p >= q) ? p : q)
static void static void
_dopr( _dopr(
...@@ -502,13 +502,13 @@ fmtint( ...@@ -502,13 +502,13 @@ fmtint(
convert[place] = 0; convert[place] = 0;
zpadlen = max - place; zpadlen = max - place;
spadlen = min - MAX(max, place) - (signvalue ? 1 : 0); spadlen = min - OSSL_MAX(max, place) - (signvalue ? 1 : 0);
if (zpadlen < 0) if (zpadlen < 0)
zpadlen = 0; zpadlen = 0;
if (spadlen < 0) if (spadlen < 0)
spadlen = 0; spadlen = 0;
if (flags & DP_F_ZERO) { if (flags & DP_F_ZERO) {
zpadlen = MAX(zpadlen, spadlen); zpadlen = OSSL_MAX(zpadlen, spadlen);
spadlen = 0; spadlen = 0;
} }
if (flags & DP_F_MINUS) if (flags & DP_F_MINUS)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册