summaryrefslogtreecommitdiff
path: root/src/posix.h
diff options
context:
space:
mode:
authorAlbert Meltzer <kitbellew@users.noreply.github.com>2014-05-18 07:54:41 -0700
committerAlbert Meltzer <kitbellew@users.noreply.github.com>2014-05-19 17:37:29 -0700
commit62e562f92b45b6a9b124452f7de6b9e86a179224 (patch)
tree96562679577257795f9ab425faae8b953bf0c051 /src/posix.h
parent588a43af543f9a00345a6e464a61c51aebad88da (diff)
downloadlibgit2-62e562f92b45b6a9b124452f7de6b9e86a179224.tar.gz
Fix compiler warning (git_off_t cast to size_t).
Use size_t for page size, instead of long. Check result of sysconf. Use size_t for page offset so no cast to size_t (second arg to p_mmap). Use mod instead div/mult pair, so no cast to size_t is necessary.
Diffstat (limited to 'src/posix.h')
-rw-r--r--src/posix.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/posix.h b/src/posix.h
index 965cd98d5..0ef35ac31 100644
--- a/src/posix.h
+++ b/src/posix.h
@@ -66,6 +66,8 @@ extern int p_creat(const char *path, mode_t mode);
extern int p_getcwd(char *buffer_out, size_t size);
extern int p_rename(const char *from, const char *to);
+extern int git__page_size(size_t *page_size);
+
#ifndef GIT_WIN32
#define p_stat(p,b) stat(p, b)