URGENT : MMAP Problem on solaris 10
Problem : When trying to create a memory mapped file the application is dumping core.
OS : Solaris 10
Analysis: When the memory mapped file size is an exact multiple of the page size, the application is dumping core. It looks like mmap() is having the problem
when handling files that of size exactly 8K, 16K, 24K (16+8), 32K, 48K(32+16), 64K, 128K etc. [ file size is exactly a multiple of the page size ]
If the file has one byte more or one byte less, this problem does not occur.
mmap() is used as -->
g_mmaddr = mmap(0, fileStat.st_size, PROT_READ | PROT_WRITE, MAP_SHARED, fp, 0)) == (caddr_t)-1)
The mmap would contain the structures SIRSAuditFieldProperty which is defined as :
typedef struct
{
int fieldNbr;
int fieldOffset;
int fieldLen;
char hllrthFlag;
short prcsnNbr;
SIRSBalAuditor::BalBucketInd addToBalBucket;
} SIRSAuditFieldProperty;
Please suggest a solution / work around for this problem.

