diff options
author | wtc%netscape.com <devnull@localhost> | 2000-05-11 23:54:04 +0000 |
---|---|---|
committer | wtc%netscape.com <devnull@localhost> | 2000-05-11 23:54:04 +0000 |
commit | 61ce2d5bb2a4bc43ab655366690cad302d1195f7 (patch) | |
tree | 7c5e62d540f39fac47ca9ffb7f9bdd43d8f5eed4 /pr/src/md | |
parent | bdd248d26b0eda034e358128002e81885b47d463 (diff) | |
download | nspr-hg-61ce2d5bb2a4bc43ab655366690cad302d1195f7.tar.gz |
Bugzilla bug #38996: added new function PR_GetMemMapAlignment().
Modified files: prio.h, _beos.h, _macos.h, _os2.h, _unixos.h, _win16.h,
_win95.h, _winnt.h, primpl.h, prmmap.c, bmmap.c, macio.c, os2misc.c,
ntmisc.c, w16fmem.c
Diffstat (limited to 'pr/src/md')
-rw-r--r-- | pr/src/md/beos/bmmap.c | 7 | ||||
-rw-r--r-- | pr/src/md/mac/macio.c | 7 | ||||
-rw-r--r-- | pr/src/md/os2/os2misc.c | 7 | ||||
-rw-r--r-- | pr/src/md/windows/ntmisc.c | 8 | ||||
-rw-r--r-- | pr/src/md/windows/w16fmem.c | 7 |
5 files changed, 36 insertions, 0 deletions
diff --git a/pr/src/md/beos/bmmap.c b/pr/src/md/beos/bmmap.c index 8f35e0dd..30b31f60 100644 --- a/pr/src/md/beos/bmmap.c +++ b/pr/src/md/beos/bmmap.c @@ -19,6 +19,13 @@ _PR_MD_CREATE_FILE_MAP(PRFileMap *fmap, PRInt64 size) return PR_FAILURE; } +PR_EXTERN(PRInt32) +_PR_MD_GET_MEM_MAP_ALIGNMENT(void) +{ + PR_SetError( PR_NOT_IMPLEMENTED_ERROR, 0 ); + return -1; +} + PR_EXTERN(void *) _PR_MD_MEM_MAP(PRFileMap *fmap, PRInt64 offset, PRUint32 len) { diff --git a/pr/src/md/mac/macio.c b/pr/src/md/mac/macio.c index 07aa4bc0..d062ce7a 100644 --- a/pr/src/md/mac/macio.c +++ b/pr/src/md/mac/macio.c @@ -1898,6 +1898,13 @@ PRStatus _MD_CreateFileMap(PRFileMap *fmap, PRInt64 size) return PR_FAILURE; } +PRInt32 _MD_GetMemMapAlignment(void) +{ + PR_ASSERT(!"Not implemented"); + PR_SetError(PR_NOT_IMPLEMENTED_ERROR, 0); + return -1; +} + void * _MD_MemMap( PRFileMap *fmap, PROffset64 offset, diff --git a/pr/src/md/os2/os2misc.c b/pr/src/md/os2/os2misc.c index 27277e68..fc1ada88 100644 --- a/pr/src/md/os2/os2misc.c +++ b/pr/src/md/os2/os2misc.c @@ -495,6 +495,13 @@ PRStatus _MD_CreateFileMap(PRFileMap *fmap, PRInt64 size) return PR_FAILURE; } +PRInt32 _MD_GetMemMapAlignment(void) +{ + PR_ASSERT(!"Not implemented"); + PR_SetError(PR_NOT_IMPLEMENTED_ERROR, 0); + return -1; +} + void * _MD_MemMap( PRFileMap *fmap, PROffset64 offset, diff --git a/pr/src/md/windows/ntmisc.c b/pr/src/md/windows/ntmisc.c index f03a9ef6..e1042b26 100644 --- a/pr/src/md/windows/ntmisc.c +++ b/pr/src/md/windows/ntmisc.c @@ -665,6 +665,14 @@ PRStatus _MD_CreateFileMap(PRFileMap *fmap, PRInt64 size) } return PR_SUCCESS; } + +PRInt32 _MD_GetMemMapAlignment(void) +{ + SYSTEM_INFO info; + GetSystemInfo(&info); + return info.dwAllocationGranularity; +} + #include "prlog.h" extern PRLogModuleInfo *_pr_shma_lm; void * _MD_MemMap( diff --git a/pr/src/md/windows/w16fmem.c b/pr/src/md/windows/w16fmem.c index 9a9a72d4..e544522c 100644 --- a/pr/src/md/windows/w16fmem.c +++ b/pr/src/md/windows/w16fmem.c @@ -33,6 +33,13 @@ PRStatus _MD_CreateFileMap(PRFileMap *fmap, PRInt64 size) return PR_FAILURE; } +PRInt32 _MD_GetMemMapAlignment(void) +{ + PR_ASSERT(!"Not implemented"); + PR_SetError(PR_NOT_IMPLEMENTED_ERROR, 0); + return -1; +} + void * _MD_MemMap( PRFileMap *fmap, PRInt64 offset, |