diff options
author | Lee Roberts <lee.roberts@hpe.com> | 2018-03-24 22:46:19 -0600 |
---|---|---|
committer | Damjan Marion <dmarion.lists@gmail.com> | 2018-03-26 11:23:26 +0000 |
commit | 1b8e8252b074e1981d09a53c1a5da19dc35541c9 (patch) | |
tree | d5c6be8144e6aae8455570c4f4533857e4402310 /src/vppinfra | |
parent | 487f5474fea738174e1cfe68fe70a2eaf58c5ce2 (diff) |
Correct address calculation for VPP-1168
Use (u64) cast to ensure proper address calculations.
Change-Id: Ifbbe66072eb94bfe33ac04eaa4416abceeb7245e
Signed-off-by: Lee Roberts <lee.roberts@hpe.com>
Diffstat (limited to 'src/vppinfra')
-rw-r--r-- | src/vppinfra/linux/mem.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/vppinfra/linux/mem.c b/src/vppinfra/linux/mem.c index 0bc08787baa..c47dd57d0e8 100644 --- a/src/vppinfra/linux/mem.c +++ b/src/vppinfra/linux/mem.c @@ -167,7 +167,7 @@ clib_mem_vm_ext_alloc (clib_mem_vm_alloc_t * a) } if (fd != -1) - if ((ftruncate (fd, n_pages * (1 << log2_page_size))) == -1) + if ((ftruncate (fd, (u64) n_pages * (1 << log2_page_size))) == -1) { err = clib_error_return_unix (0, "ftruncate"); goto error; |