Welcome! Log In Create A New Profile

Advanced

[njs] Fixed integer constant is too large compilation error by gcc 4.4.

Dmitry Volyntsev
March 03, 2020 11:02AM
details: https://hg.nginx.org/njs/rev/c5c6aab76bb4
branches:
changeset: 1348:c5c6aab76bb4
user: Dmitry Volyntsev <xeioex@nginx.com>
date: Tue Mar 03 19:00:54 2020 +0300
description:
Fixed integer constant is too large compilation error by gcc 4.4.

diffstat:

src/njs_number.c | 2 +-
src/njs_number.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)

diffs (24 lines):

diff -r ef30d99ea2be -r c5c6aab76bb4 src/njs_number.c
--- a/src/njs_number.c Tue Mar 03 18:57:15 2020 +0300
+++ b/src/njs_number.c Tue Mar 03 19:00:54 2020 +0300
@@ -236,7 +236,7 @@ njs_uint64_to_string(njs_vm_t *vm, njs_v
u_char *dst, *p;
u_char buf[128];

- if (njs_fast_path(u64 < 0x3fffffffffff)) {
+ if (njs_fast_path(u64 < 0x3fffffffffffULL)) {
/* Fits to short_string. */
dst = njs_string_short_start(value);

diff -r ef30d99ea2be -r c5c6aab76bb4 src/njs_number.h
--- a/src/njs_number.h Tue Mar 03 18:57:15 2020 +0300
+++ b/src/njs_number.h Tue Mar 03 19:00:54 2020 +0300
@@ -8,7 +8,7 @@
#define _NJS_NUMBER_H_INCLUDED_


-#define NJS_MAX_LENGTH (0x1fffffffffffff)
+#define NJS_MAX_LENGTH (0x1fffffffffffffULL)


double njs_key_to_index(const njs_value_t *value);
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[njs] Fixed integer constant is too large compilation error by gcc 4.4.

Dmitry Volyntsev 87 March 03, 2020 11:02AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 68
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready