Compile error in intl/uconv/native/nsNativeUConvService.cpp. Bug 372648, patch by Priit Laes <amd@store20.com> and timeless, r=smontagu
This commit is contained in:
Родитель
3ff4d6edae
Коммит
7e5ba34d6d
|
@ -47,6 +47,7 @@
|
|||
#include "nsICharRepresentable.h"
|
||||
|
||||
#include "nsNativeUConvService.h"
|
||||
#include "nsAutoPtr.h"
|
||||
|
||||
#include <nl_types.h> // CODESET
|
||||
#include <langinfo.h> // nl_langinfo
|
||||
|
@ -250,11 +251,11 @@ IConvAdaptor::SetOutputErrorBehavior(PRInt32 aBehavior,
|
|||
nsIUnicharEncoder * aEncoder,
|
||||
PRUnichar aChar)
|
||||
{
|
||||
if (aBehavior == kOnError_Signal) {
|
||||
if (aBehavior == nsIUnicodeEncoder::kOnError_Signal) {
|
||||
mReplaceOnError = PR_FALSE;
|
||||
return NS_OK;
|
||||
}
|
||||
else if (aBehavior != kOnError_Replace) {
|
||||
else if (aBehavior != nsIUnicodeEncoder::kOnError_Replace) {
|
||||
mReplaceOnError = PR_TRUE;
|
||||
mReplaceChar = aChar;
|
||||
return NS_OK;
|
||||
|
@ -375,11 +376,14 @@ NativeUConvService::GetNativeConverter(const char* from,
|
|||
{
|
||||
*aResult = nsnull;
|
||||
|
||||
nsRefPtr<IConvAdaptor> ucl = new IConvAdaptor();
|
||||
//nsRefPtr<IConvAdaptor> ucl = new IConvAdaptor();
|
||||
IConvAdaptor *adaptor=new IConvAdaptor();
|
||||
nsCOMPtr<nsISupports> ucl(NS_STATIC_CAST(nsIUnicodeDecoder*,adaptor));
|
||||
if (!ucl)
|
||||
return NS_ERROR_OUT_OF_MEMORY;
|
||||
|
||||
nsresult rv = ucl->Init(from, to);
|
||||
//nsresult rv = ucl->Init(from, to);
|
||||
nsresult rv=adaptor->Init(from,to);
|
||||
if (NS_SUCCEEDED(rv))
|
||||
NS_ADDREF(*aResult = ucl);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче