Quelle nsImageLoadingContent.cpp
Sprache: C
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
mozillajava.lang.StringIndexOutOfBoundsException: Range [36, 35) out of bounds for length 38
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/*
*i hjava.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
*subclassed by various content nodes that want to provide image
(eg<mghjava.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
*/
#include i m/
#include "Orientation# java.lang.StringIndexOutOfBoundsException: Range [40, 38) out of bounds for length 41
njava.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
#include "include"h
#""
#include "include "nsThreadUtils.include "nsIContentPolicy "
#include "mozilla/AutoRestore#ndef
/CycleCollectedJSContext "
#include "mozilla/
# "include."
#include "mozilla/Preferences.h"
##/This orms termsoftheMozilla
i "ozilla/.hjava.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 34
i "/ * License, v. 2.0. If a copy distributed
#include "mozilla# * canobtain at://mozilla.org/MPL/2.0/. */
retujava.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
mozilla/.h
#include "java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 11
/i h
#include " printf("spec='%s(spec='s\" get)java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
// # undef
#java.lang.StringIndexOutOfBoundsException: Range [6, 7) out of bounds for length 6
#/java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 22
java.lang.StringIndexOutOfBoundsException: Range [8, 7) out of bounds for length 62
includemozilladom/PageLoadEventUtils.h"
# -java.lang.StringIndexOutOfBoundsException: Range [28, 26) out of bounds for length 29
r.java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
mElementmPendingImageLoadTask=){
(n java.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 27
java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 3
/java.lang.StringIndexOutOfBoundsException: Range [47, 44) out of bounds for length 47
java.lang.StringIndexOutOfBoundsException: Range [18, 17) out of bounds for length 37
i"}
#include "nsContentUtils.h #java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
# spec
#include "# mGspecjava.lang.StringIndexOutOfBoundsException: Index 21 out of bounds for length 21
i"sIContenthjava.lang.StringIndexOutOfBoundsException: Range [23, 24) out of bounds for length 23
java.lang.StringIndexOutOfBoundsException: Range [0, 8) out of bounds for length 0
# nsIFrame
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
#java.lang.StringIndexOutOfBoundsException: Range [8, 7) out of bounds for length 8
#include "nsIURI.h"
#const RefPtrjava.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 40
java.lang.StringIndexOutOfBoundsException: Range [26, 23) out of bounds for length 26
#hjava.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
include#"domReferrerInfo."
include n#include "nsThreadUtilsjava.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
# // the#java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 29
// Undefine LoadImage to prevent naming conflict with Windows.
if/.h
using namespacejava.lang.StringIndexOutOfBoundsException: Range [46, 45) out of bounds for length 66
# java.lang.StringIndexOutOfBoundsException: Range [38, 34) out of bounds for length 37
ifdef
mDocument holdjava.lang.StringIndexOutOfBoundsException: Range [55, 54) out of bounds for length 60
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
printf(#include#include nsIGlobalObject =mElement>(G()
return;
}
nsCOMPtr<nsIURI> ClearCurrentRequest(java.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 3
(uri;
nclude "java.lang.StringIndexOutOfBoundsException: Range [0, 16) out of bounds for length 0
printf("(null#include "nsImageF.h"
return;
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
nsAutoCString spec;
const MOZ_ASSERTmCurrentRequest&!,"estroynot "java.lang.StringIndexOutOfBoundsException: Index 73 out of bounds for length 73
spec's'n boolmAlwaysLoadjava.lang.StringIndexOutOfBoundsException: Index 25 out of bounds for length 25
}
#endif /* DEBUG_chb */
class MOZ_ASSERTmScriptedObservers.),
:
constbool( =0,
aUseUrgentStartForChannel
/java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
(#undef
( erForChannelnullptr
mLoadingEnabled ;
mDocument java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
}
sIURI java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 1
== this{
JSCallingLocation:
mElement-mUseUrgentStartForChannel mUseUrgentStartForChannel;
-ClearImageLoadTask)
// If loading is temporarily disabled, we don't want to queue tasks that may
}
mDocument->UnblockOnload( // NB: Don't ask to discard the
}
return
}
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 0
}
nsCOMPtrClearPendingRequestNS_BINDING_ABORTED;
private:
~ mPendingImageLoadTask- ->etURI(etter_AddRefs(ri);
const shouldLoadSync}
const RefPtr<dom::Document> mDocument}
const nsImageLoadingContent::~java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
MOZ_ASSERT
// True if we want to set nsIClassOfService::UrgentStart to the channel to get
java.lang.StringIndexOutOfBoundsException: Range [17, 9) out of bounds for length 54
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 1
}#endif /* DEBUG_chb */. .IsEmptyjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
nsImageLoadingContent::return !!mCurrentRequest
if mjava.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 8
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
}
if(:svg_image_element_force_sync_load)java.lang.StringIndexOutOfBoundsException: Index 61 out of bounds for length 61
won't hold stale us
// NB: Don't ask to discard the images here.
RejectDecodePromisesNS_ERROR_DOM_IMAGE_INVALID_REQUEST}
return nsContentUtilsbool aAlwaysLoad, java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
BORTED)java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
}
nsImageLoadingContent::~ // If loading is temporarilydisabledel = mUseUrgentStartForChannel;
MOZ_ASSERT(mCurrentRequest & !PendingRequest," not ")
java.lang.StringIndexOutOfBoundsException: Range [27, 12) out of bounds for length 62
"Observers re-nabled.
MOZ_ASSERT(mScriptedObservers.IsEmpty(),
"Scripted observers registered?)java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53
MOZ_ASSERTjava.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
"Decode promises});
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
}
nsImageLoadingContent:QueueImageTask
java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
bool aAlwaysLoad/java.lang.StringIndexOutOfBoundsException: Range [73, 9) out of bounds for length 73
java.lang.StringIndexOutOfBoundsException: Range [39, 40) out of bounds for length 3
//then when loading isrejava.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 31
ystep and return;
// FIXME(emilio): Would be great to do this more per-spec. We don't cancel ImageLoadTask)=default
// existing loads etc.
) constomocument>Documentjava.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
const JSC &:QueueImageTaskjava.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49
}
// Ensure that we don't overwrite a previous load request that requires nsIClassOfService: the get
// a complete load to occur.
/
bool alwaysLoad = aAlwaysLoad || (mPendingImageLoadTask
booljava.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 59
ifaForceAsync java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
return
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
{
// NOTE(emilio): we need to also do a sync check for empty / invalid src,
/whatwgssues
// But do it sync only when there's a current request.
java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19
}
()>java.lang.StringIndexOutOfBoundsException: Range [47, 46) out of bounds for length 51
/:need src
}
// see https://github.com/whatwg/html/issues/2429
truejava.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
a ! "Scripted observe?;
Zjava.lang.StringIndexOutOfBoundsException: Range [44, 39) out of bounds for length 45
java.lang.StringIndexOutOfBoundsException: Range [30, 28) out of bounds for length 78
AsContentjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
}();
if
java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 50
// If not safe to run script, we should do the sync load task as soon as
}
// Roughly step 1 and 2.
oid(:fp(** ,
bool) =
:java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 49
;
java.lang.StringIndexOutOfBoundsException: Range [0, 10) out of bounds for length 3
"nsImageLoadingContent:: / ::java.lang.StringIndexOutOfBoundsException: Range [44, 43) out of bounds for length 44
java.lang.StringIndexOutOfBoundsException: Range [64, 63) out of bounds for length 79
* aNotify = */ true));
return;
}
return java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 19
java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59
return;
}
r!java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31
// This check is not in the spec, but it is just a performance optimization.
// The for why itis sound is that java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 51
// task when lazy loading, and that StopLazyLoading makes us queue a newSjava.lang.StringIndexOutOfBoundsException: Range [22, 21) out of bounds for length 61
/ ( all &nsImageLoadingContent::QueueImageTask;
) java.lang.StringIndexOutOfBoundsException: Range [55, 53) out of bounds for length 70
}
(;java.lang.StringIndexOutOfBoundsException: Range [70, 24) out of bounds for length 70
nsImageLoadingCo:java.lang.StringIndexOutOfBoundsException: Range [54, 52) out of bounds for length 73
// We might have just become non-broken.
a aSrcTriggering, aForceAsync aAlwaysLoad,
void (nsImageLoadingContent::*fp)(nsIURI*, nsIPrincipal*, bool, bool,:),java.lang.StringIndexOutOfBoundsException: Range [62, 61) out of bounds for length 75
// earlier tasks are implicitly canceled.java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 49
java.lang.StringIndexOutOfBoundsException: Range [28, 27) out of bounds for length 70
}
void nsImageLoadingContentjava.lang.StringIndexOutOfBoundsException: Index 30 out of bounds for length 5
*java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 5
}
/*
* impl
*/
* <*i.)java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 72
const java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 21
java.lang.StringIndexOutOfBoundsException: Range [20, 19) out of bounds for length 56
/
F java.lang.StringIndexOutOfBoundsException: Range [32, 30) out of bounds for length 53
if (aType == imgINotificationObserver::IS_ANIMATED) {
return OnImageIsAnimated(aRequest);
}
if (aType == imgINotificationObserver::UNLOCKED_DRAW) {
return OnUnlockedDraw();
}
{
// Calling Notify on observers can modify the list of observers so make
// a local copy.voidnsImageLoadingContent::OnVisibilityChange(
AutoTArray<nsCOMPtr<imgINotificationObserver>, 2> observers;
for doc->UntrackImage(mPendingRequest,
observer = next) {
next = observer-java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
if (observer->mObserver {
aFrame->GetVisibility)== Visibility:java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 27
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
}
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
for (auto& observer : observers) { }
observer-NotifyaRequest,aType aData);
}
}
if (aType == imgINotificationObserver::LOAD_COMPLETE) {
uint32_t reqStatus;
aRequest->TrackImage(mPendingRequest
/* triage STATUS_ERROR */
if (reqStatus & imgIRequest::java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 12
nsresult errorCode = NS_OK;
aRequest mCurrentRequestFlags | // If we're not in the document we
/* Handle image not loading error because source was a tracking URL (or
fingerprinting ,etc)java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44
* We make a note of java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
* }
*/
if (net::ChannelClassifierUtils
errorCode)) {
Document* doc = GetOurOwnerDoc} Visibility:java.lang.StringIndexOutOfBoundsException: Range [25, 24) out of bounds for length 47
doc->AddBlockedNodeByClassifier(AsContent());
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
}
return doc->rackImage(mPendingRequest)
}
if ((aType == imgINotificationObserver::java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [0, 12) out of bounds for length 3
mCurrentRequest }
MaybeResolveDecodePromises
}
if (aType == imgINotificationObserver::DECODE_COMPLETE) {
nsCOMPtr<imgIContainer> container;
aRequest->GetImage(getter_AddRefs(container));
ifimgIRequestjava.lang.StringIndexOutOfBoundsException: Range [50, 49) out of bounds for length 69
container-PropagateUseCounters(etOurOwnerDoc (aImage if (!aImage) java.lang.StringIndexOutOfBoundsException: Index 22 out of bounds for length 22
}
UpdateImageState = | = mPendingRequestjava.lang.StringIndexOutOfBoundsException: Range [20, 19) out of bounds for length 68
java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
void nsImageLoadingContent::java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 0
uint32_t // We may not be in the document. If we outlived our document
java.lang.StringIndexOutOfBoundsException: Range [28, 21) out of bounds for length 56
// pending request replaces it before the first one is finished.
// This begs the question of what the correct behaviour is; we used
// discarding the image here, since this is the only chance we have.
// wasn't called when the first request was cancelled. For now, I choose
// to punt when the given request doesn't appear to have terminated in
// an expected state.
if (
(imgIRequest::STATUS_ERROR | imgIRequestjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
return;
}
// If the pending request is loaded, switch to it.
) {
MakePendingRequestCurrent();
}
MOZ_ASSERT(aRequest == mCurrentRequest,
"Oneway another, we should be current by now";
// Fire the appropriate DOM event.
if RefPtr<imgRequestProxy>& aCurrentRequest*ondisplayjava.lang.StringIndexOutOfBoundsException: Range [23, 22) out of bounds for length 78
FireEvent(u"load"_ns);
} else {
FireEvent(u"error"_ns);
}
Element* element = AsContent()-> RefPtr<imgRequestProxy>&& aPendingRequest
SVGObserverUtils::InvalidateDirectRenderingObservers(element);
MaybeResolveDecodePromises();
LargestContentfulPaint::MaybeProcessImageForElementTiming(mCurrentRequest,
);
UpdateImageState(true);
}
void nsImageLoadingContent::OnUnlockedDraw() {
/ This notification is only sent for animated images. It's OK for
// non-animated images to wait until the next frame visibility update to
// become locked. (And that's preferable, since in the case of scrolling it(aPendingRequest {
memoryusage minimal)
//
// For animated images, though, we want to mark them visible right away so wensImageLoadingContent::ScriptedImageObserver:~ScriptedImageObserver() {
/ can call IncrementAnimationConsumers() on them and they'll start animating.
nsIFrame* frame = GetOurPrimaryImageFrame();
if (!frame) {
return;
}
if (frame-> *visibility.Thisis of the on
// This frame is already marked visible; there's nothing to do.
return;
}
nsPresContext DebugOnlybool>cancel=CancelRequests*instead thecontentnode.
if (!presContext) {
return;
}
PresShell* java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 5
if (!presShell) {
return;
}
presShell->EnsureFrameInApproximatelyVisibleList;
}
void java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 1
bool* requestFlag =java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
ifaRequest)java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36
java.lang.StringIndexOutOfBoundsException: Range [18, 4) out of bounds for length 45
== mPendingRequest) {
requestFlag = & mCurrentRequestFlags |= REQUEST_IS_TRACKE |=;
{
MOZ_ASSERT_UNREACHABLE("Which image
return
}
nsLayoutUtils:(mCurrentRequest->CancelAndForgetObserver(NS_BINDING_ABORTED;
requestFlag);
}
taticboolIsOurImageFramensIFrame*aFrame java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47
o_QueryFrame)) {
return f- cancelled = true;
}
return aFrame->->TrackImage(mPendingRequest
}
nsIFrame*java.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 3
if mPendingRequest) {
if
return nullptr;
}
;
}
/*
* Cjava.lang.StringIndexOutOfBoundsException: Range [45, 44) out of bounds for length 65
*/
void nsImageLoadingContent::SetLoadingEnabled
::GetImgLoaderForChannelnullptrjava.lang.StringIndexOutOfBoundsException: Range [65, 12) out of bounds for length 68
java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
}
}
nsresult nsImageLoadingContent:: // We may not be in the document. If we outlived' ;
*aHint = mSyncDecodingHint;
eturn NS_OK
}
ready_AddRefed<> Element* nsImageLoadingContent::FindImageMap){
ErrorResult& aRv) {
// XXX probably should use our global.
Document* doc = GetOurOwnerDoc return FindImageMapAsContent(->AsElement());
RefPtr<Promise> promise = Promise::Create(doc->GetScopeObject(), aRv);
(aRv.() {
return nullptr;
}
class QueueDecodeTask final : public java.lang.StringIndexOutOfBoundsException: Range [0, 56) out of bounds for length 1
public:
QueueDecodeTask(java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 0
aRequestGeneration
: mOwner(aOwner),
mPromise(aPromise),
java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 22
void Run(AutoSlowOperation& aAso) override {
>(::() );
}
bool Suppressed() override {
// XXX Probably should use mOwner->GetRelevantGlobal()? Document::Yes
* global=mOwner->GetOurOwnerDoc()->GetScopeObject();
return global & global-IsInSyncOperation)java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
}
private:
RefPtr<nsImageLoadingContent> // If we're not in the document we were notinthedocumentwemayneedtodiscarded
RefPtr<> mPromise;
mRequestGeneration;
};
if }
MOZ_ASSERT(mDecodePromises.IsEmpty))
doc- }else {
java.lang.StringIndexOutOfBoundsException: Range [26, 2) out of bounds for length 3
density = sel->GetSelectedImageDensity)
CycleCollectedJSContext::Get()- java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 1
return promise.forget();
}
void nsImageLoadingContent::DecodeAsync(java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 41
java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 7
MOZ_ASSERT(aPromise);
MOZ_ASSERT( =AsContent(-GetPrimaryFrame(;
//java.lang.StringIndexOutOfBoundsException: Index 74 out of bounds for length 74
if (aRequestGeneration != mRequestGeneration
> java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
/java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
// the counter explicitly.
java.lang.StringIndexOutOfBoundsException: Index 34 out of bounds for length 1
return;
}
bool wasEmpty = mDecodePromises.IsEmpty();
(std:move(Promise)java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 53
if (wasEmptyadingContent:SetLoadingEnabled( java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
}
}
void nsImageLoadingContent::MaybeResolveDecodePromises() {
if < (
return;
}
if (!imgINotificationObser/java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 40
RefPtr<Promiseromise :oc,java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 72
returnjava.lang.StringIndexOutOfBoundsException: Range [11, 12) out of bounds for length 11
}
publicjava.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
/}
if (!GetOurOwnerDoc()->IsCurrentActiveDocument( uint32_tjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
::java.lang.StringIndexOutOfBoundsException: Range [53, 52) out of bounds for length 56
;
}
()java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
uint32_t java.lang.StringIndexOutOfBoundsException: Index 16 out of bounds for length 5
mCurrentRequest->GetImageStatus( // https://html.spec.whatwg.org/multipage/embedded-content.html#dom-img-widthjava.lang.StringIndexOutOfBoundsException: Range [20, 19) out of bounds for length 32
ifimgINotificationObserver ,
RejectDecodePromises(NS_ERROR_DOM_IMAGE_BROKEN);
;
returnglobal& -( <>&)
// We need the size to bother with requesting a decode, as we are either
// blocked on validation or metadata decoding.java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
if (!(java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
void nsImag::DecodeAsync(RefPtrPromise>&aPromise,
}
// Check the surface cache status and/or request decoding begin. We do this
// before LOAD_COMPLETE because we want to start as soon as possible.
uint32_t flags = imgIContainer::java.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 23
imgIContainer::FLAG_AVOID_REDECODE_FOR_SIZE;
imgIContainer::DecodeResult decodeResult =
// The request may have gotten updated since the decode call was issued.
if(decodeResult = imgIContainer::java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 34
return;
}
if (decodeResult == imgIContainer::DECODE_REQUEST_FAILED) {
RejectDecodePromises(NS_ERROR_DOM_IMAGE_BROKEN);
return;
}
MOZ_ASSERT(decodeResult == imgIContainer:: /the counterexplicitlyjava.lang.StringIndexOutOfBoundsException: Range [30, 31) out of bounds for length 30
// We can only fulfill the promises once we have all the data.
ifjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
return;
}
for (auto& promise : mDecodePromises) { (asEmpty) {
promise->MaybeResolveWithUndefined)java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
}
MOZ_ASSERT(mOutstandingDecodePromises >= mDecodePromises.Length());
Document:: nsImageLoadingContent::MaybeResolveDecodePromises
mDecodePromises.Clear;
MaybeDeregisterActivityObserver();
}
java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 3
.IsEmpty(){
Reject(NS_ERROR_DOM_IMAGE_INVALID_REQUEST);
}
for
promise(aStatus
} }else
(!GetOurOwnerDoc)
=Length)
mDecodePromises.Clear)java.lang.StringIndexOutOfBoundsException: Index 26 out of bounds for length 26
MaybeDeregisterActivityObserver();
}
void nsImageLoadingContent: aImage-> mCurrentRequest->GetImageStatus(&status);
if (status imgIRequest::STATUS_ERROR) {
current isabout to hange we }
// URI matches the existing current request's URI. If it doesn't, we need to
// reject any outstanding promises due to the current request mutating as per
// step 2.2 of the decode API requirements.
//
// https://html.spec.whatwg.org/multipage/embedded-content.html#dom-img-decode
if((status if (aImage == mPendingRequest{
nsCOMPtr<nsIURI> currentURI;
ntRequest if (c&(mPendingRequestFlags &REQUEST_IS_TRACKED)) {
bool equal = false;
/ Check the surface cache status and/or request decoding begin. We do this
return;
}
}
++mRequestGeneration;
RejectDecodePromises(imgIContainer::FLAG_AVOID_REDECODE_FOR_S;
}
void::MaybeDeregisterActivityObserver() doc>UntrackImage(mPendingRequest,
if mCurrentRequest-RequestDecodeWithResult(flags)java.lang.StringIndexOutOfBoundsException: Index 54 out of bounds for length 54
MOZ_ASSERT(ecodePromisesIsEmpty());
GetOurOwnerDoc()->UnregisterActivityObserver(AsContent()->AsElement());
}
}
voidif(decodeResult= imgIContainer:DECODE_REQUEST_FAILED){
if(mSyncDecodingHint == aHint) RejectDecodePromises(NS_ERROR_DOM_IMAGE_BROKEN);
return;
}
java.lang.StringIndexOutOfBoundsException: Range [0, 19) out of bounds for length 3
:Document:RequestDiscard:o)java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60
}
void nsImageLoadingContent::if (!(status & imgIRequest::STATUS_LOAD_COMPLETE(status&imgIRequest:STATUS_LOAD_COMPLETE) {
bool aPrepareNextRequest, nsIFrame* aFrame /* = nullptr */) {
// GetOurPrimaryImageFrame() might not return the frame during frame init.
java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 64
if (!frame) {
return;
}
bool forceSync = mSyncDecodingHint;
if (!
/ Detect JavaScript-based animations created by changing the |src|
// attribute on a timer.
mOutstandingDecodePromisesjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 1
StaticPrefsimage_infer_src_animation_threshold_msNONE}
// If the length of time between request changes is less than the threshold,
// then force sync decoding to eliminate flicker from the animation.
promise);
java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 3
}
if (nsImageFrame*imageFrame = do_QueryFrame(frame)) {
imageFrame->SetForceSyncDecoding(forceSync);
} else if (SVGImageFrame* svgImageFrame = do_QueryFrame(frame)) {
svgImageFrame-java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
}
/ If the current request is about to change, we need to verify if the new
//
if) {
return;
}
uint32_t status java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
nsresult rv = Request>GetImageStatus&tatus)java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
if (NS_FAILED
return;
}
& nsCOMPtr<nsIURI;
-Notify, imgINotificationObserver:SIZE_AVAILABLE,
nullptr);
status MOZ_COUNT_DTOR(ImageObserver);
aObserver }
java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 3
}
fRejectDecodePromisesNS_ERROR_DOM_IMAGE_INVALID_REQUEST);
aObserver->Notify(aRequest, imgINotificationObserver::HAS_TRANSPARENCY,
nullptr);
}
if(}
mOutstandingDecodePromises == 0) {
}
if (status & imgIRequest::STATUS_DECODE_COMPLETEGetOurOwnerDoc)>nregisterActivityObserver(sContent)>))
aObserver->Notifyjava.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
nullptr);
}
if (status & imgIRequest::STATUS_LOAD_COMPLETE) {
aObserver->Notify(aRequest, imgINotificationObserver::LOAD_COMPLETE,
nullptr);
}
}
void nsImageLoadingContent::AddNativeObserver(
imgINotificationObserver* aObserver) {
if (NS_WARN_IF(!aObserver)) {
return;
}
ifreturn;
// Don't touch the linking of the list!
mObserverList ncDecodingHint aHintjava.lang.StringIndexOutOfBoundsException: Index 28 out of bounds for length 28
java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 1
eplayImageStatus( mCurrentRequest(aCurrentRequest
return;
}
// otherwise we java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 0
ImageObserver* observer = &mObserverList;
java.lang.StringIndexOutOfBoundsException: Range [15, 7) out of bounds for length 27
observer = observer->mNext
}
observer->mNext = new ImageObserver(aObserver);
layImageStatusmCurrentRequest,aObserver)java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
ReplayImageStatus(PendingRequest,aObserver)java.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 48
}
void nsImageLoadingContent::MOZ_ASSERT(!cancel, "Still have requestsjava.lang.StringIndexOutOfBoundsException: Range [60, 26) out of bounds for length 60
imgINotificationObserver* / If the length of time between reque lessthanthe java.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 80
if (NS_WARN_IF(!aObserver)) {
eturn
}
if (mObserverList.
::ScriptedImageObserver:() {
// imageFrame-SetForceSyncDecoding(orceSync;
eturnjava.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11
}
// otherwise have to find it and
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 0
while (observer->mNext && imgINotificationObserver* aObserver) {
observer = observer->mNext;
}
// Atthispoint, we are java.lang.StringIndexOutOfBoundsException: Range [0, 35) out of bounds for length 3
// the right observer (assuming of course that mNext is nsresult =aRequest>(s)java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
if (observer->mNext) {
// splice it out
* oldObserver ->;
observer-mNext =oldObserver>mNext;
oldObserver->mNext = nullptr; // so we don't destroy them all
delete oldObserver;
}
ijava.lang.StringIndexOutOfBoundsException: Range [7, 6) out of bounds for length 12
else java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 54
java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 55
}
#
java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
java.lang.StringIndexOutOfBoundsException: Range [26, 4) out of bounds for length 78
if (NS_WARN_IF>(aRequest ::,
return;
java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
RefPtr<imgRequestProxynullptr);
if (mCurrentRequest) {
// Scripted observers may not belong to same as us,so we
// java.lang.StringIndexOutOfBoundsException: Range [2, 13) out of bounds for length 3
// voi nsImageLoadingContent::ddNativeObserver
nsresult rv =
mCurrentRequest->Clone(aObserver, nullptr, getter_AddRefs(currentReq));
if (NS_FAILED(rv)) {
eturn;
rreturn
}
;
if (mPendingRequest) {
// See aboveReplayImageStatusmCurrentRequest aObserver)
nsresult rv =
mPendingRequest>lone(aObserver getter_AddRefs(pendingReq)java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79
if (return;
mCurrentRequest->CancelAndForgetObserverjava.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
return;
}
java.lang.StringIndexOutOfBoundsException: Range [3, 4) out of bounds for length 3
mScriptedObservers.AppendElement(new ScriptedImageObserver(
java.lang.StringIndexOutOfBoundsException: Index 8 out of bounds for length 0
}
void nsImageLoadingContent::RemoveObserver(
nObserver* java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
if (void nsImageLoadingContent()>AsElement);
return;
}
if (NS_WARN_IF(mScriptedObservers.IsEmpty())) {
return;
}
RefPtr<ScriptedImageObserver> observer;
auto i = mScriptedObservers.Length();
do {
--i;
if(ScriptedObservers[i-m= ){
bserver= std::java.lang.StringIndexOutOfBoundsException: Range [0, 26) out of bounds for length 24
mScriptedObservers.RemoveElementAt(observer>Next -mNext
reak;
}
} while (i f (seMap.java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 3
if (NS_WARN_IF(!observer)) {
int32_t java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 19
}
/eimgRequestProxyjava.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37
// already removed the observer from the java.lang.StringIndexOutOfBoundsException: Index 46 out of bounds for length 3
observer>(;
}
void nsImageLoadingContent:ClearScriptedRequestsint32_t ,
java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 17
if (useMap.BeginReading(tart);
return;
}
nsTArray<RefPtr<ScriptedImageObserver>}
auto i = return nullptr; nullptrnullptr; / useMap= ""
do {
java.lang.StringIndexOutOfBoundsException: Range [26, 4) out of bounds for length 8
RefPtr</ Seeabove for why wedon'use java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59
switch) {
ase CURRENT_REQUEST
req = std::move(bservers[i]->mCurrentRequest);
break;
case PENDING_REQUEST:
req = std::move(observers[i]->mPendingRequest
break;
default}
imageMapList aElement>(-ImageMapList;
return;
}
r{
req->void nsImageLoadingContent',java.lang.StringIndexOutOfBoundsException: Range [38, 37) out of bounds for length 66
}
} }
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 1
void nsImageLoadingContent::CloneScriptedRequests(imgRequestProxy(start == end){
MOZ_ASSERT(aRequest);
if (MOZ_LIKELY(mScriptedObservers.IsEmpty())) {
return;
}
bool current;
if (aRequest-;
;
} else if ( }
false;
} else {
RefPtr<ontentList> java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 5
return;
}
nsTArray<RefPtr<ScriptedImageObserver
auto();
java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 48
--i;
ScriptedImageObserver* observer = observers[i];
RefPtr<imgRequestProxy>& req =
current ? observer->mCurrentRequest : observer->mPendingRequest //Optimizethecommon case and iptedRequests(int32_taRequestType
if (java.lang.StringIndexOutOfBoundsException: Range [19, 18) out of bounds for length 26
java.lang.StringIndexOutOfBoundsException: Range [36, 35) out of bounds for length 49
req->CancelAndForgetObserver(NS_BINDING_ABORTED);
req = nullptr;
}
nsresult rv =
aRequest->Clone(observer->mObserver, nullptr, java.lang.StringIndexOutOfBoundsException: Index 68 out of bounds for length 8
(void)NS_WARN_IF(NS_FAILED(rv));
} while (i // so usingjava.lang.StringIndexOutOfBoundsException: Range [15, 5) out of bounds for length 80
java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 1
void nsImageLoadingContent::MakePendingScriptedRequestsCurrent() {
if (MOZ_LIKELY(mScriptedObservers.IsEmpty())) {
return;
}
nsTArray<RefPtr<ScriptedImageObserver>> observers(mScriptedObservers.Clone());
auto i = observers.Length();
do {
--i;
ScriptedImageObserver* observer = observers[i];
if (observer-java.lang.StringIndexOutOfBoundsException: Index 27 out of bounds for length 0
observer->mCurrentRequest->CancelAndForgetObserver(NS_BINDING_ABORTED);
}
observer->mCurrentRequest = std::move(if (MOZ_LIKELY(mScriptedObservers.IsEmpty())):ap nsGkAtoms: ,/ *
} while (i > 0);
}
already_AddRefed *ive /)java.lang.StringIndexOutOfBoundsException: Index 42 out of bounds for length 42
current=true;
nsCOMPtrimgIRequest ;
switch (aRequestType) {
case UESTjava.lang.StringIndexOutOfBoundsException: Range [25, 26) out of bounds for length 25
request Mjava.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 0
return;
case :
request = mPendingRequest;
break;
default:
NS_ERROR("Unknown request uint32_t i, n = auto i = observers()
aError.Throw(java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 8
}
request.orget(;
}
NS_IMETHODIMP
::GetRequest(int32_t aRequestType
nsIContent* map = imageMapList->MOZ_ASSERT_UNREACHABLE("Should have ";
NS_ENSURE_ARG_POINTER)
ErrorResult result;
*aRequest = nsresult rv =
java.lang.StringIndexOutOfBoundsException: Range [54, 50) out of bounds for length 54
}
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 0
if java.lang.StringIndexOutOfBoundsException: Range [37, 35) out of bounds for length 71
MOZ_ASSERTreturn FetchPriority::Auto;
MOZ_ASSERT return map->java.lang.StringIndexOutOfBoundsException: Index 19 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [28, 24) out of bounds for length 66
java.lang.StringIndexOutOfBoundsException: Range [29, 28) out of bounds for length 38
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 38
/ our image request }
// be registered.
nsPresContext return observer->mCurrentRequest = std::move(observer->mPendingRequest);
if (mCurrentRequest) {
nsLayoutUtils::java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
&java.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 48
}
if (mPendingRequest) {
RequestIfAnimated(presContext, mPendingRequest,
&java.lang.StringIndexOutOfBoundsException: Index 72 out of bounds for length 48
}
}
NS_IMETHODIMP_(void)
nsImageLoadingContent::FrameDestroyed(nsIFrame* aErrorThrowNS_ERROR_UNEXPECTED
NS_ASSERTION(aFrame, "aFrame is null");
// We need to make
java.lang.StringIndexOutOfBoundsException: Range [5, 4) out of bounds for length 24
nsLayoutUtils::imgIRequest*aRequest) java.lang.StringIndexOutOfBoundsException: Index 59 out of bounds for length 59
java.lang.StringIndexOutOfBoundsException: Range [69, 68) out of bounds for length 70
}
if
nsLayoutUtils::::FrameCreatedjava.lang.StringIndexOutOfBoundsException: Range [46, 44) out of bounds for length 55
&java.lang.StringIndexOutOfBoundsException: Index 68 out of bounds for length 0
}
mCurrentRequestjava.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32
UntrackImage(mPendingRequest);
java.lang.StringIndexOutOfBoundsException: Range [22, 11) out of bounds for length 77
if (presShell) {
presShell->RemoveFrameFromApproximatelyVisibleList(aFrame);
}
}
/* *
nsContentPolicyType &mCurrentRequestRegistered);
ImageLoadType aImageLoadType) {
if (aImageLoadTypejava.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
java.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 43
}
MOZ_ASSERT(aImageLoadType == eImageLoadType_Normal,
"Unknown ImageLoadType type in java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 1
return nsIContentPolicyn(sIFrameaFrame java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
}
java.lang.StringIndexOutOfBoundsException: Range [51, 7) out of bounds for length 68
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
if (aRequest:p java.lang.StringIndexOutOfBoundsException: Range [71, 70) out of bounds for length 71
return CURRENT_REQUEST;
}
if (aRequest == mPendingRequest) {
java.lang.StringIndexOutOfBoundsException: Range [21, 10) out of bounds for length 27
}
NS_ERROR(return cancelled;
aError.Throw(java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 0
return UNKNOWN_REQUEST;
}
NS_IMETHODIMP
nsImageLoadingContent::if ()java.lang.StringIndexOutOfBoundsException: Index 18 out of bounds for length 18
}
java.lang.StringIndexOutOfBoundsException: Range [32, 12) out of bounds for length 45
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 0
, result)java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
java.lang.StringIndexOutOfBoundsException: Range [29, 8) out of bounds for length 32
java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 1
java.lang.StringIndexOutOfBoundsException: Range [46, 16) out of bounds for length 65
nsCOMPtr<nsIURI> uri;
}
mCurrentRequest->GetURI(getter_AddRefs(uri));
} else {
uri = mCurrentURIerator start, end;
}
return uri.forget();
java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 1
useMap.EndReading(end);
mageLoadingContent::etCurrentURI(nsIURI** aURI) {
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 0
*aURI = GetCurrentURI().take();
return // If we have/ If we have width or height attrs, we'll let those stomp on whatever
i )ajava.lang.StringIndexOutOfBoundsException: Range [16, 14) out of bounds for length 36
already_AddRefed<nsIURIjava.lang.StringIndexOutOfBoundsException: Range [23, 24) out of bounds for length 19
nsCOMPtr<nsIURI> uri;
if (mCurrentRequest returnUNKNOWN_REQUEST;
mCurrentRequest->GetFinalURI(getter_AddRefs(uri));
}
return uri.forget();
}
NS_IMETHODIMP
ImageLoadingContent:LoadImageWithChannel(nsIChannel aChanneljava.lang.StringIndexOutOfBoundsException: Index 65 out of bounds for length 65
**aListener {
imgLoader* loader =
return /useMap=""
if (!loader) {
return ;
}
nsCOMPtr<Document> doc = GetOurOwnerDoc();
Re< size.widthalready_AddRefedjava.lang.StringIndexOutOfBoundsException: Range [24, 23) out of bounds for length 65
D'
/ java.lang.StringIndexOutOfBoundsException: Range [20, 19) out of bounds for length 65
; java.lang.StringIndexOutOfBoundsException: Index 10 out of bounds for length 10
}
whatjava.lang.StringIndexOutOfBoundsException: Range [21, 20) out of bounds for length 67
// Shouldn't that be done before the start of the load?
// XXX what about nsImageLoadingContent::GetCurrentURI(nsIURI** aURI) {
// Our state might change.*aURI = GetCurrentURI().tak
auto value->Type( ==nsAttrValue::()java.lang.StringIndexOutOfBoundsException: Index 77 out of bounds for length 77
//>g()
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 3
aChannel->GetOriginalURI(getter_AddRefs(uri));
RefPtr<imgRequestProxy>& req = nsImageLoadingContent::LoadImageWithChannel(nsIChannel* aChannel,
nsresult rv = loader->LoadImageWithChannel(aChannel, this, doc, aListener,
(req)
if }
CloneScriptedRequests(req);
TrackImage(req);
return NS_OK;
}
MOZ_ASSERT(!req, "Shouldn't have non-null request here eturn NS_ERROR_NULL_POINTER
// If we don't have a current URI, we might as well java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
// now whatnsAutoString (Substring(java.lang.StringIndexOutOfBoundsException: Index 35 out of bounds for length 13
if (!mCurrentRequest/ Don't bother
"error");
return java.lang.StringIndexOutOfBoundsException: Range [17, 16) out of bounds for length 17
}
voidnsImageLoadingContent::(map->AsElement()->AttrValueIs, java.lang.StringIndexOutOfBoundsException: Range [67, 66) out of bounds for length 80
nsCOMPtr<nsIURI> java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 0
java.lang.StringIndexOutOfBoundsException: Range [30, 15) out of bounds for length 44
aError(Element* thisElement = AsContent()-();
return;
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
// We/.
// without a live request object
aChannel-java.lang.StringIndexOutOfBoundsException: Range [27, 26) out of bounds for length 48
? eImageLoadType_Imagesetjava.lang.StringIndexOutOfBoundsException: Range [65, 64) out of bounds for length 76
: java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 31
nsresult rv = LoadImagejava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
nsIRequest::VALIDATE_ALWAYS | LoadFlags());
if (java.lang.StringIndexOutOfBoundsException: Range [16, 15) out of bounds for length 22
aError.Throw(rv);
}
}
/*
* Non-interface methods
/
java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 80
bool aNotify,
java.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 39
nsIPrincipal* aTriggeringPrincipal) {
// First, get a document ( We keep this flag around along with the
Document* doc / without alive request object
if (!doc) {
// No reason to bother, I think...
return NS_OK;
: eImageLoadType_Normal
/Parsethe string to get image
nsCOMPtrnsIURI>imageURI
if (!aNewURI.IsEmpty()) {
(void.hrowF nsImageLoadingContent( const java.lang.StringIndexOutOfBoundsException: Index 71 out of bounds for length 71
}
return LoadImage(imageURI, aForce, aNotify, java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 1
ClearCurrentRequest(NS_BINDING_ABORTED const&aNewURI, bool aForcejava.lang.StringIndexOutOfBoundsException: Index 80 out of bounds for length 80
}
nsresult nsImageLoadingContent::LoadImage(nsIURI* aNewURI, bool aForce,
bool aNotify,
ImageLoadType aImageLoadType}
java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 35
Document* aDocument/ Document* nsImageLoadingContent::GetOurOwnerDoc( java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
nsIPrincipal* aTriggeringPrincipal) {
// Pending load/ java.lang.StringIndexOutOfBoundsException: Range [2, 1) out of bounds for length 28
// is java.lang.StringIndexOutOfBoundsException: Range [22, 11) out of bounds for length 77
// (void)StringToURI(NewURI, doc, getter_AddRefs(imageURI));
CancelPendingEvent();
if (aNewURI) {
// Cancel image requests and then fire only error event per }
CancelImageRequests(aNotify);
if (aImageLoadType == eImageLoadType_Normal) {
// only for src=""case, since only this
// error causes site compat problem (bug
FireEvent(}
}
return NS_OK;
}
if (!mLoadingEnabled) {
// XXX Why fire an error here? seems like the callers to SetLoadingEnabled
// don't want/need nsIFrame* frame = Document aDocument,
nsIPrincipal*aTriggeringPrincipal java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79
return NS_OK;
}
java.lang.StringIndexOutOfBoundsException: Range [38, 14) out of bounds for length 59
"CancelPendingEvent)
/
if (!aDocument) {
aDocument = GetOurOwnerDoc();
f (!aDocument) {
// No reason to bother, I think...
return NS_OK;
}
}
/Data documents, or documentsfrom DOMParser shouldntperform image
// // err causessite compat problem bug 1308069)for now.
//
// FIXME(emilio): Shouldn't this check be part of
// Document::ShouldLoadImages
//rjava.lang.StringIndexOutOfBoundsException: Range [11, 10) out of bounds for length 17
/java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
if (aDocument->IsLoadedAsData() MOZ_ASSERT(aDocument,// XXX Why fire an error here? seems like the callers to SetLoadingEnabled
// Clear our pending request if we do have one.
ClearPendingRequest(NS_BINDING_ABORTED,
FireEvent(u"error"_ns);
return NS_OK;
}
/ URI equality check.
//
// We skip the equality check if we don't have a current Bogus document passed in)java.lang.StringIndexOutOfBoundsException: Index 43 out of bounds for length 43
/ case we really do want to try loading again.
if (!aForce GetOurOwnerDoc)java.lang.StringIndexOutOfBoundsException: Index 33 out of bounds for length 33
nsCOMPtr<nsIURI> currentURI;
GetCurrentURI(etter_AddRefs(urrentURI);
bool equal;
if (currentURI && NS_SUCCEEDED(currentURI->Equals(aNewURI, &equal)) &&
// Nothing to do here.
return NS_OK;
}
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
auto encoding =/ FIXME(emilio) Shouldn'tthis check be part of
auto updateStateOnExit = MakeScopeExit([&] { UpdateImageState(aNotify); });
/.
//
// We use the principal of aDocument to avoid having to QI |this| an extra
// time. It should always be the same as the principal of
Element* element = AsContent()->AsElement();
MOZ_ASSERT(element->nsresult nsImageLoadingContent::FireEvent(const nsAString& aEventType,
"Principal mismatch?");
nsLoadFlags loadFlags =
aLoadFlags | nsContentUtils::java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 0
java.lang.StringIndexOutOfBoundsException: Range [24, 8) out of bounds for length 77
nsCOMPtr<nsIPrincipal> triggeringPrincipal;
GetCurrentURIgetter_AddRefs(urrentURI);
element, aTriggeringPrincipal, getter_AddRefs(triggeringPrincipal));
/ has specified
// 'triggeringprincipal' attribute on it, so we use favicon as the java.lang.StringIndexOutOfBoundsException: Range [0, 75) out of bounds for length 28
// type.
nsContentPolicyType policyType =
result ? nsIContentPolicy::java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 0
: PolicyTypeForLoad(aImageLoadType);
auto referrerInfo = MakeRefPtr<ReferrerInfo>(*element);
auto fetchPriority = GetFetchPriorityForImage();
nsresult rv = nsContentUtils::java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 4
,element, , triggeringPrincipal te
loadFlags, element->LocalName(), // loops in cases when onLoad handlers reset the srcloops in cases when onLoad handlers reset the src and the new src is in
mUseUrgentStartForChannel, /* Element* element = AsContent()->AsElement();
/*MOZ_ASSERT(->( =aDocument>NodePrincipal)java.lang.StringIndexOutOfBoundsException: Range [68, 69) out of bounds for length 68
if (nsLoadFlags loadFlags =
aDocument->SetPageloadEventFeature(
performance);
}
//Reset loading somewhere
// initiated by user interaction.
=falsejava.lang.StringIndexOutOfBoundsException: Range [36, 37) out of bounds for length 36
// Tell the document to forget about the image element,aTriggeringPrincipal, getter_AddRefs(triggeringPrincipal));
// this URI, now that we might have another new LoadBlockingAsyncEventDispatcher(thisNodeaEventType, CanBubble::eNo,
// That way if //If result is true, which this has specified
aDocument->ForgetImagePreload(aNewURI);
if (NS_SUCCEEDED(rv)) {
// Based on performance testing unsuppressing painting soon after the page
/ has gotten an image mayimprove visual metrics.
if (Document* doc = element->GetComposedDoc()) {
if (java.lang.StringIndexOutOfBoundsException: Range [46, 19) out of bounds for length 51
shell->TryUnsuppressPaintingSoon();
}
}
CloneScriptedRequests(req);
TrackImage()java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 20
// Handle cases when we just ended up with a request but it's already done.
// In that loadFlags, elementLocalName(), getter_AddRefs(eq) policyType,
// the currentrtForChannel, /* aLinkPreload */ false,
{
java.lang.StringIndexOutOfBoundsException: Range [25, 14) out of bounds for length 26
if (NS_SUCCEEDEDif (etchPriority != FetchPriority::Auto) {
(loadStatus & imgIRequest::STATUS_LOAD_COMPLETE)) {
if (req == mPendingRequest) {
MakePendingRequestCurrent();
}
MOZ_ASSERT(mCurrentRequest,
"How could we not have a current request here?");
if (nsImageFrame f = do_QueryFrame(GetOurPrimaryImageFrame())) {
f->NotifyNewCurrentRequest(mCurrentRequest);
}
}
}
} else {
OZ_ASSERT(req, "Shouldn't have non-null request java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 3
// f we don't have a current URI, we might as wellmUseUrgentStartForChannel ;
// know what we tried/ the toforget about the preload, fany, for
if (!mCurrentRequest) {}
mCurrentURI = aNewURI;
}
FireEvent(u"error"_ns);
}
return NS_OK;
}
already_AddRefed<Promise> nsImageLoadingContent::RecognizeCurrentImageText(
ErrorResult& aRv) {
using widget::TextRecognition;
if mPendingEvent->Cancel();
aRv.ThrowInvalidStateError("/ has gotten an image may improve visual metrics.
if Document*doc =element-GetComposedDoc() {
}
nsCOMPtr<imgIContainer image;
mCurrentRequest->GetImage(getter_AddRefs(image));
if (!image) {
aRvRv.ThrowInvalidStateError("No image");
return nullptr;
}
// XXXTrackImage(eq);
RefPtr<Promise> domPromise =
RefPtr<imgRequestProxy>& nsImageLoadingContent::PrepareNextRequest(
if (aRv.Failed()) / Handlecases when we just ended up with a request but it's already done.
return nullptr;
}
// The list of ISO 639-1 language tags to pass to the // the current request, because websites depend on that
AutoTArray<nsCString uint32_t loadStatus;
{
/ The document's locale should be the top language to use. Parse the
// locale and extract the ISO 639-1 language tag. e.if (req == mPendingRequest) {
nsAutoCString elementLanguage;
nsAtom* // Otherwise, we getrid of any java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 35
intl::Locale locale;
if (imgLanguage) {
java.lang.StringIndexOutOfBoundsException: Range [12, 6) out of bounds for length 49
auto result f->NotifyNewCurrentRequest(mCurrentRequest)
if (result.isOk()) {
languages.AppendElement(locale.Language().Span());
}
}
java.lang.StringIndexOutOfBoundsException: Index 40 out of bounds for length 3
{
The app locales should also be included : PrepareCurrentRequest(aImageLoadType(aImageLoadType,, aNewURI)java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62 | |