]> granicus.if.org Git - vim/commitdiff
patch 8.0.1629: Mac: getpagesize() is deprecated v8.0.1629
authorBram Moolenaar <Bram@vim.org>
Thu, 22 Mar 2018 20:44:07 +0000 (21:44 +0100)
committerBram Moolenaar <Bram@vim.org>
Thu, 22 Mar 2018 20:44:07 +0000 (21:44 +0100)
Problem:    Mac: getpagesize() is deprecated.
Solution:   Use sysconf() instead. (Ozaki Kiichi, closes #2741)

src/os_unix.c
src/version.c

index e0bc3de218a49a58c151bbba6d1253866c26cef1..b811ac3f4b812adb33a2bbe5fa56b6444b50ffa0 100644 (file)
@@ -603,7 +603,7 @@ mch_total_mem(int special UNUSED)
 #  ifdef MAC_OS_X_VERSION_10_9
                                            + vm_stat.compressor_page_count
 #  endif
-                                           ) * getpagesize();
+                                           ) * sysconf(_SC_PAGESIZE);
        mach_port_deallocate(mach_task_self(), host);
     }
 # endif
index dc76b4a34a884dd5f2ed8480a96a676dbb41a48e..ce1ed2053c1de0eb34265b74644470f0220e6274 100644 (file)
@@ -766,6 +766,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1629,
 /**/
     1628,
 /**/