Bug 537195 - nsISound.play without esound installed should throw NS_ERROR_NOT_AVAILABLE. r=roc

This commit is contained in:
Saint Wesonga 2010-01-02 13:13:27 +01:00
parent 1b5e231ed3
commit f49d728632
2 changed files with 3 additions and 3 deletions

View File

@ -430,7 +430,7 @@ NS_METHOD nsSound::Play(nsIURL *aURL)
Init();
if (!elib)
return NS_ERROR_FAILURE;
return NS_ERROR_NOT_AVAILABLE;
nsCOMPtr<nsIStreamLoader> loader;
rv = NS_NewStreamLoader(getter_AddRefs(loader), aURL, this);

View File

@ -124,7 +124,7 @@ nsSound::Init()
EsdOpenSoundType EsdOpenSound;
elib = PR_LoadLibrary("libesd.so.0");
if (!elib) return NS_ERROR_FAILURE;
if (!elib) return NS_ERROR_NOT_AVAILABLE;
EsdOpenSound = (EsdOpenSoundType) PR_FindFunctionSymbol(elib, "esd_open_sound");
@ -368,7 +368,7 @@ NS_METHOD nsSound::Play(nsIURL *aURL)
Init();
if (!elib)
return NS_ERROR_FAILURE;
return NS_ERROR_NOT_AVAILABLE;
nsCOMPtr<nsIStreamLoader> loader;
rv = NS_NewStreamLoader(getter_AddRefs(loader), aURL, this);