]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Fix n-i-bz shmat of a segment > 4Gb does not work
authorPhilippe Waroquiers <philippe.waroquiers@skynet.be>
Thu, 16 Aug 2012 19:40:52 +0000 (19:40 +0000)
committerPhilippe Waroquiers <philippe.waroquiers@skynet.be>
Thu, 16 Aug 2012 19:40:52 +0000 (19:40 +0000)
Problem was created by get_shm_size returning an UInt rather
than a SizeT.

see http://sourceforge.net/mailarchive/message.php?msg_id=29682827

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12874

NEWS
coregrind/m_syswrap/syswrap-generic.c

diff --git a/NEWS b/NEWS
index 0e84baf14d2b483629b67922b5a717831f98b39b..850898dcf9bacbb8100473b34cc6b7c02f31151f 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,26 @@
+Release 3.9.0 (?? ?????? 201?)
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+* ================== PLATFORM CHANGES =================
+
+* ==================== TOOL CHANGES ====================
+
+* ==================== OTHER CHANGES ====================
+
+* ==================== FIXED BUGS ====================
+
+The following bugs have been fixed or resolved.  Note that "n-i-bz"
+stands for "not in bugzilla" -- that is, a bug that was reported to us
+but never got a bugzilla entry.  We encourage you to file bugs in
+bugzilla (https://bugs.kde.org/enter_bug.cgi?product=valgrind) rather
+than mailing the developers (or mailing lists) directly -- bugs that
+are not entered into bugzilla tend to get forgotten about or ignored.
+
+To see details of a given bug, visit
+  https://bugs.kde.org/show_bug.cgi?id=XXXXXX
+where XXXXXX is the bug number as listed below.
+
+n-i-bz shmat of a segment > 4Gb does not work 
 
 Release 3.8.0 (10 August 2012)
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
index 216c65e3b675d1a2b87f66222ed91cab514beef7..46d4531991b7c506d17e11deebe99370f82d76a2 100644 (file)
@@ -1700,7 +1700,7 @@ ML_(generic_POST_sys_semctl) ( ThreadId tid,
 /* ------ */
 
 static
-UInt get_shm_size ( Int shmid )
+SizeT get_shm_size ( Int shmid )
 {
 #ifdef __NR_shmctl
 #  ifdef VKI_IPC_64
@@ -1725,7 +1725,7 @@ UInt get_shm_size ( Int shmid )
    if (sr_isError(__res))
       return 0;
  
-   return buf.shm_segsz;
+   return (SizeT) buf.shm_segsz;
 }
 
 UWord
@@ -1733,7 +1733,7 @@ ML_(generic_PRE_sys_shmat) ( ThreadId tid,
                              UWord arg0, UWord arg1, UWord arg2 )
 {
    /* void *shmat(int shmid, const void *shmaddr, int shmflg); */
-   UInt  segmentSize = get_shm_size ( arg0 );
+   SizeT  segmentSize = get_shm_size ( arg0 );
    UWord tmp;
    Bool  ok;
    if (arg1 == 0) {
@@ -1768,7 +1768,7 @@ ML_(generic_POST_sys_shmat) ( ThreadId tid,
                               UWord res,
                               UWord arg0, UWord arg1, UWord arg2 )
 {
-   UInt segmentSize = VG_PGROUNDUP(get_shm_size(arg0));
+   SizeT segmentSize = VG_PGROUNDUP(get_shm_size(arg0));
    if ( segmentSize > 0 ) {
       UInt prot = VKI_PROT_READ|VKI_PROT_WRITE;
       Bool d;