sizeof(B_PAGE_SIZE) != B_PAGE_SIZE. Fixed bug 1151. Sorry for the silly

typo. Also uses calloc() so that the direct_buffer_info struct is 
initialized to 0.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@20663 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Stefano Ceccherini 2007-04-12 13:15:06 +00:00
parent ba4918e74c
commit 22cf4a3be6

View File

@ -326,7 +326,7 @@ BGLView::DirectConnected(direct_buffer_info *info)
glviewDirectInfo->direct_connected = false;
break;
}
//direct_info_locker->Unlock();
//direct_info_locker->Unlock();
if (fRenderer)
fRenderer->DirectConnected(localInfo);
@ -502,7 +502,7 @@ const char * color_space_name(color_space space)
glview_direct_info::glview_direct_info()
{
// TODO: See direct_window_data() in app_server's ServerWindow.cpp
direct_info = (direct_buffer_info *)malloc(sizeof(B_PAGE_SIZE));
direct_info = (direct_buffer_info *)calloc(1, B_PAGE_SIZE);
direct_connected = false;
}