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.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36425 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold 2010-04-22 22:48:33 +00:00
parent f2d5f97a0c
commit ccb3f07a14

View File

@ -5337,7 +5337,6 @@ get_memory_map_etc(team_id team, const void* address, size_t numBytes,
!= physicalAddress - table[index].size) {
if ((uint32)++index + 1 > numEntries) {
// table to small
status = B_BUFFER_OVERFLOW;
break;
}
table[index].address = (void*)physicalAddress;