[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gnome
Subject:    Newbie Question - File Mapping.
From:       <sasank.kuntimaddi () wipro ! com>
Date:       2009-02-10 12:36:10
Message-ID: 107A57BFD3C21C4AB6EE147035A25DC70185E13C () PNE-HJN-MBX01 ! wipro ! com
[Download RAW message or body]

--===============2118565913==
Content-class: urn:content-classes:message
Content-Type: multipart/alternative;
	boundary="----_=_NextPart_001_01C98B7A.7A37F57F"

This is a multi-part message in MIME format.


Hi,
 
I have an application that uses the following Windows APIs.
 
LPVOID WINAPI MapViewOfFile(
  __in  HANDLE hFileMappingObject,
  __in  DWORD dwDesiredAccess,
  __in  DWORD dwFileOffsetHigh,
  __in  DWORD dwFileOffsetLow,
  __in  SIZE_T dwNumberOfBytesToMap
);
 
HANDLE CreateFileMapping(
  HANDLE hFile,
  LPSECURITY_ATTRIBUTES lpFileMappingAttributes,
  DWORD flProtect,
  DWORD dwMaximumSizeHigh,
  DWORD dwMaximumSizeLow,
  LPCTSTR lpName 
);
 
I need to reprogram this application to run on Linux. Is mmap function a
good replacement for the above two API calls. If not please suggest an
alternative method.
 
Thanks and Regards
Sasank K 

[Attachment #3 (text/html)]

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.3492" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=064481912-10022009><FONT face=Arial 
size=2>Hi,</FONT></SPAN></DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial size=2>I have an 
application that uses the following Windows APIs.</FONT></SPAN></DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial size=2>LPVOID WINAPI 
MapViewOfFile(<BR>&nbsp; __in&nbsp; HANDLE hFileMappingObject,<BR>&nbsp; 
__in&nbsp; DWORD dwDesiredAccess,<BR>&nbsp; __in&nbsp; DWORD 
dwFileOffsetHigh,<BR>&nbsp; __in&nbsp; DWORD dwFileOffsetLow,<BR>&nbsp; 
__in&nbsp; SIZE_T dwNumberOfBytesToMap<BR>);</FONT></SPAN></DIV>
<DIV>&nbsp;</DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial size=2>HANDLE 
CreateFileMapping(<BR>&nbsp; HANDLE hFile,<BR>&nbsp; LPSECURITY_ATTRIBUTES 
lpFileMappingAttributes,<BR>&nbsp; DWORD flProtect,<BR>&nbsp; DWORD 
dwMaximumSizeHigh,<BR>&nbsp; DWORD dwMaximumSizeLow,<BR>&nbsp; LPCTSTR lpName 
<BR>);</FONT></SPAN></DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial size=2>I need to reprogram 
this application to run on Linux. Is mmap function&nbsp;a good replacement for 
the above two API calls. If not please suggest&nbsp;an alternative 
method.</FONT></SPAN></DIV>
<DIV><SPAN class=064481912-10022009></SPAN>&nbsp;</DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial size=2>Thanks and 
Regards</FONT></SPAN></DIV>
<DIV><SPAN class=064481912-10022009><FONT face=Arial 
size=2>Sasank&nbsp;K</FONT>&nbsp;</SPAN></DIV></BODY></HTML>


_______________________________________________
gnome-list mailing list
gnome-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gnome-list

--===============2118565913==--

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic