X-Git-Url: https://arthur.barton.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=libatalk%2Fadouble%2Fad_mmap.c;h=a93ab5a502dfa64a7f826160457b4fa61d93b304;hb=refs%2Fheads%2Fv3.1.6-alex;hp=ef2a6824d16cf1945f9d5152bd46fe73f49a77fa;hpb=458fcac4e6aee7eb54ba744f57169f70cce12505;p=netatalk.git diff --git a/libatalk/adouble/ad_mmap.c b/libatalk/adouble/ad_mmap.c index ef2a6824..a93ab5a5 100644 --- a/libatalk/adouble/ad_mmap.c +++ b/libatalk/adouble/ad_mmap.c @@ -1,4 +1,5 @@ -/* ad_mmap provides interfaces to memory mapped files. as this is the +/* + * ad_mmap provides interfaces to memory mapped files. as this is the * case, we don't have to deal w/ temporary buffers such as * ad_data. the ad_mmap routines are designed to not interact w/ the * ad_read/ad_write routines to avoid confusion. @@ -6,20 +7,17 @@ #ifdef HAVE_CONFIG_H #include "config.h" -#endif +#endif /* HAVE_CONFIG_H */ +#ifdef USE_MMAPPED_HEADERS #include -#include -#include -#include -#include -#include #include +#include -#include "ad_private.h" +#include "ad_lock.h" -static __inline__ void *ad_mmap(const size_t length, const int prot, +static void *ad_mmap(const size_t length, const int prot, const int flags, const int fd, const off_t offset) { @@ -106,3 +104,5 @@ void *ad_mmapwrite(struct adouble *ad, const u_int32_t eid, return ad_mmap(buflen, PROT_READ | PROT_WRITE, MAP_SHARED, ad->ad_hf.adf_fd, off); } + +#endif