зеркало из https://github.com/mozilla/gecko-dev.git
Changes for qnx(photon) platform only. They should not affect building/runtime other platforms.
Fixed a null pointer crash ( check for mData ).
This commit is contained in:
Родитель
b7aedee852
Коммит
3382a6efbc
|
@ -155,8 +155,10 @@ NS_IMETHODIMP nsDragService::GetNumDropItems (PRUint32 * aNumItems)
|
|||
NS_IMETHODIMP nsDragService::GetData (nsITransferable * aTransferable, PRUint32 aItemIndex ) {
|
||||
nsresult rv = NS_ERROR_FAILURE;
|
||||
nsCOMPtr<nsISupports> genericDataWrapper;
|
||||
nsPrimitiveHelpers::CreatePrimitiveForData( mflavorStr, mData, mtmpDataLen, getter_AddRefs( genericDataWrapper ) );
|
||||
rv = aTransferable->SetTransferData( mflavorStr, genericDataWrapper, mtmpDataLen );
|
||||
if( mData ) {
|
||||
nsPrimitiveHelpers::CreatePrimitiveForData( mflavorStr, mData, mtmpDataLen, getter_AddRefs( genericDataWrapper ) );
|
||||
rv = aTransferable->SetTransferData( mflavorStr, genericDataWrapper, mtmpDataLen );
|
||||
}
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче