[haiku-commits] r36425 - haiku/trunk/src/system/kernel/vm

  • From: ingo_weinhold@xxxxxx
  • To: haiku-commits@xxxxxxxxxxxxx
  • Date: Fri, 23 Apr 2010 00:48:33 +0200 (CEST)

Author: bonefish
Date: 2010-04-23 00:48:33 +0200 (Fri, 23 Apr 2010)
New Revision: 36425
Changeset: http://dev.haiku-os.org/changeset/36425/haiku

Modified:
   haiku/trunk/src/system/kernel/vm/vm.cpp
Log:
get_memory_map_etc(): Setting the return value to B_BUFFER_OVERFLOW in the
loop causes the function to return before setting the _numEntries. The
overflow case is checked at the end of the function anyway, so we can just
break out.


Modified: haiku/trunk/src/system/kernel/vm/vm.cpp
===================================================================
--- haiku/trunk/src/system/kernel/vm/vm.cpp     2010-04-22 20:50:15 UTC (rev 
36424)
+++ haiku/trunk/src/system/kernel/vm/vm.cpp     2010-04-22 22:48:33 UTC (rev 
36425)
@@ -5337,7 +5337,6 @@
                                != physicalAddress - table[index].size) {
                        if ((uint32)++index + 1 > numEntries) {
                                // table to small
-                               status = B_BUFFER_OVERFLOW;
                                break;
                        }
                        table[index].address = (void*)physicalAddress;


Other related posts:

  • » [haiku-commits] r36425 - haiku/trunk/src/system/kernel/vm - ingo_weinhold