File: | var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp |
Warning: | line 20061, column 39 Moved-from object 'previousKey' is moved |
Press '?' to see keyboard shortcuts
Keyboard shortcuts:
1 | /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
2 | /* vim: set ts=8 sts=2 et sw=2 tw=80: */ |
3 | /* This Source Code Form is subject to the terms of the Mozilla Public |
4 | * License, v. 2.0. If a copy of the MPL was not distributed with this file, |
5 | * You can obtain one at http://mozilla.org/MPL/2.0/. */ |
6 | |
7 | #include "ActorsParent.h" |
8 | |
9 | #include <inttypes.h> |
10 | #include <math.h> |
11 | #include <stdlib.h> |
12 | #include <string.h> |
13 | #include <algorithm> |
14 | #include <cstdint> |
15 | #include <functional> |
16 | #include <iterator> |
17 | #include <new> |
18 | #include <numeric> |
19 | #include <tuple> |
20 | #include <type_traits> |
21 | #include <utility> |
22 | #include "ActorsParentCommon.h" |
23 | #include "CrashAnnotations.h" |
24 | #include "DatabaseFileInfo.h" |
25 | #include "DatabaseFileManager.h" |
26 | #include "DatabaseFileManagerImpl.h" |
27 | #include "DBSchema.h" |
28 | #include "ErrorList.h" |
29 | #include "IDBCursorType.h" |
30 | #include "IDBObjectStore.h" |
31 | #include "IDBTransaction.h" |
32 | #include "IndexedDBCommon.h" |
33 | #include "IndexedDatabaseInlines.h" |
34 | #include "IndexedDatabaseManager.h" |
35 | #include "IndexedDBCipherKeyManager.h" |
36 | #include "KeyPath.h" |
37 | #include "MainThreadUtils.h" |
38 | #include "ProfilerHelpers.h" |
39 | #include "ReportInternalError.h" |
40 | #include "SafeRefPtr.h" |
41 | #include "SchemaUpgrades.h" |
42 | #include "chrome/common/ipc_channel.h" |
43 | #include "ipc/IPCMessageUtils.h" |
44 | #include "js/RootingAPI.h" |
45 | #include "js/StructuredClone.h" |
46 | #include "js/Value.h" |
47 | #include "jsapi.h" |
48 | #include "mozIStorageAsyncConnection.h" |
49 | #include "mozIStorageConnection.h" |
50 | #include "mozIStorageFunction.h" |
51 | #include "mozIStorageProgressHandler.h" |
52 | #include "mozIStorageService.h" |
53 | #include "mozIStorageStatement.h" |
54 | #include "mozIStorageValueArray.h" |
55 | #include "mozStorageCID.h" |
56 | #include "mozStorageHelper.h" |
57 | #include "mozilla/Algorithm.h" |
58 | #include "mozilla/ArrayAlgorithm.h" |
59 | #include "mozilla/ArrayIterator.h" |
60 | #include "mozilla/Assertions.h" |
61 | #include "mozilla/Atomics.h" |
62 | #include "mozilla/Attributes.h" |
63 | #include "mozilla/Casting.h" |
64 | #include "mozilla/CondVar.h" |
65 | #include "mozilla/DebugOnly.h" |
66 | #include "mozilla/EndianUtils.h" |
67 | #include "mozilla/ErrorNames.h" |
68 | #include "mozilla/ErrorResult.h" |
69 | #include "mozilla/InitializedOnce.h" |
70 | #include "mozilla/Logging.h" |
71 | #include "mozilla/MacroForEach.h" |
72 | #include "mozilla/Maybe.h" |
73 | #include "mozilla/Monitor.h" |
74 | #include "mozilla/Mutex.h" |
75 | #include "mozilla/NotNull.h" |
76 | #include "mozilla/Preferences.h" |
77 | #include "mozilla/ProfilerLabels.h" |
78 | #include "mozilla/RefCountType.h" |
79 | #include "mozilla/RefCounted.h" |
80 | #include "mozilla/RemoteLazyInputStreamParent.h" |
81 | #include "mozilla/RemoteLazyInputStreamStorage.h" |
82 | #include "mozilla/Result.h" |
83 | #include "mozilla/ResultExtensions.h" |
84 | #include "mozilla/SchedulerGroup.h" |
85 | #include "mozilla/SnappyCompressOutputStream.h" |
86 | #include "mozilla/SpinEventLoopUntil.h" |
87 | #include "mozilla/StaticPtr.h" |
88 | #include "mozilla/TimeStamp.h" |
89 | #include "mozilla/UniquePtr.h" |
90 | #include "mozilla/Unused.h" |
91 | #include "mozilla/Variant.h" |
92 | #include "mozilla/dom/BlobImpl.h" |
93 | #include "mozilla/dom/ContentParent.h" |
94 | #include "mozilla/dom/FileBlobImpl.h" |
95 | #include "mozilla/dom/FlippedOnce.h" |
96 | #include "mozilla/dom/IDBCursorBinding.h" |
97 | #include "mozilla/dom/IDBFactory.h" |
98 | #include "mozilla/dom/IPCBlob.h" |
99 | #include "mozilla/dom/IPCBlobUtils.h" |
100 | #include "mozilla/dom/IndexedDatabase.h" |
101 | #include "mozilla/dom/Nullable.h" |
102 | #include "mozilla/dom/PContentParent.h" |
103 | #include "mozilla/dom/ScriptSettings.h" |
104 | #include "mozilla/dom/indexedDB/IDBResult.h" |
105 | #include "mozilla/dom/indexedDB/Key.h" |
106 | #include "mozilla/dom/indexedDB/PBackgroundIDBCursor.h" |
107 | #include "mozilla/dom/indexedDB/PBackgroundIDBCursorParent.h" |
108 | #include "mozilla/dom/indexedDB/PBackgroundIDBDatabase.h" |
109 | #include "mozilla/dom/indexedDB/PBackgroundIDBDatabaseFileParent.h" |
110 | #include "mozilla/dom/indexedDB/PBackgroundIDBDatabaseParent.h" |
111 | #include "mozilla/dom/indexedDB/PBackgroundIDBFactory.h" |
112 | #include "mozilla/dom/indexedDB/PBackgroundIDBFactoryParent.h" |
113 | #include "mozilla/dom/indexedDB/PBackgroundIDBFactoryRequestParent.h" |
114 | #include "mozilla/dom/indexedDB/PBackgroundIDBRequest.h" |
115 | #include "mozilla/dom/indexedDB/PBackgroundIDBRequestParent.h" |
116 | #include "mozilla/dom/indexedDB/PBackgroundIDBSharedTypes.h" |
117 | #include "mozilla/dom/indexedDB/PBackgroundIDBTransactionParent.h" |
118 | #include "mozilla/dom/indexedDB/PBackgroundIDBVersionChangeTransactionParent.h" |
119 | #include "mozilla/dom/indexedDB/PBackgroundIndexedDBUtilsParent.h" |
120 | #include "mozilla/dom/ipc/IdType.h" |
121 | #include "mozilla/dom/quota/Assertions.h" |
122 | #include "mozilla/dom/quota/CachingDatabaseConnection.h" |
123 | #include "mozilla/dom/quota/CheckedUnsafePtr.h" |
124 | #include "mozilla/dom/quota/Client.h" |
125 | #include "mozilla/dom/quota/ClientDirectoryLock.h" |
126 | #include "mozilla/dom/quota/ClientImpl.h" |
127 | #include "mozilla/dom/quota/DebugOnlyMacro.h" |
128 | #include "mozilla/dom/quota/DirectoryLock.h" |
129 | #include "mozilla/dom/quota/DirectoryLockInlines.h" |
130 | #include "mozilla/dom/quota/DecryptingInputStream_impl.h" |
131 | #include "mozilla/dom/quota/EncryptingOutputStream_impl.h" |
132 | #include "mozilla/dom/quota/ErrorHandling.h" |
133 | #include "mozilla/dom/quota/FileStreams.h" |
134 | #include "mozilla/dom/quota/OriginScope.h" |
135 | #include "mozilla/dom/quota/PersistenceScope.h" |
136 | #include "mozilla/dom/quota/PersistenceType.h" |
137 | #include "mozilla/dom/quota/PrincipalUtils.h" |
138 | #include "mozilla/dom/quota/QuotaCommon.h" |
139 | #include "mozilla/dom/quota/QuotaManager.h" |
140 | #include "mozilla/dom/quota/QuotaObject.h" |
141 | #include "mozilla/dom/quota/ResultExtensions.h" |
142 | #include "mozilla/dom/quota/ThreadUtils.h" |
143 | #include "mozilla/dom/quota/UniversalDirectoryLock.h" |
144 | #include "mozilla/dom/quota/UsageInfo.h" |
145 | #include "mozilla/fallible.h" |
146 | #include "mozilla/ipc/BackgroundParent.h" |
147 | #include "mozilla/ipc/BackgroundUtils.h" |
148 | #include "mozilla/ipc/InputStreamParams.h" |
149 | #include "mozilla/ipc/PBackgroundParent.h" |
150 | #include "mozilla/ipc/PBackgroundSharedTypes.h" |
151 | #include "mozilla/ipc/ProtocolUtils.h" |
152 | #include "mozilla/mozalloc.h" |
153 | #include "mozilla/storage/Variant.h" |
154 | #include "NotifyUtils.h" |
155 | #include "nsBaseHashtable.h" |
156 | #include "nsCOMPtr.h" |
157 | #include "nsClassHashtable.h" |
158 | #include "nsContentUtils.h" |
159 | #include "nsTHashMap.h" |
160 | #include "nsDebug.h" |
161 | #include "nsError.h" |
162 | #include "nsEscape.h" |
163 | #include "nsHashKeys.h" |
164 | #include "nsIAsyncInputStream.h" |
165 | #include "nsID.h" |
166 | #include "nsIDUtils.h" |
167 | #include "nsIDirectoryEnumerator.h" |
168 | #include "nsIEventTarget.h" |
169 | #include "nsIFile.h" |
170 | #include "nsIFileProtocolHandler.h" |
171 | #include "nsIFileStreams.h" |
172 | #include "nsIFileURL.h" |
173 | #include "nsIInputStream.h" |
174 | #include "nsIOutputStream.h" |
175 | #include "nsIProtocolHandler.h" |
176 | #include "nsIRunnable.h" |
177 | #include "nsISupports.h" |
178 | #include "nsISupportsPriority.h" |
179 | #include "nsISupportsUtils.h" |
180 | #include "nsIThread.h" |
181 | #include "nsIThreadInternal.h" |
182 | #include "nsITimer.h" |
183 | #include "nsIURIMutator.h" |
184 | #include "nsIVariant.h" |
185 | #include "nsLiteralString.h" |
186 | #include "nsNetCID.h" |
187 | #include "nsPrintfCString.h" |
188 | #include "nsProxyRelease.h" |
189 | #include "nsServiceManagerUtils.h" |
190 | #include "nsStreamUtils.h" |
191 | #include "nsString.h" |
192 | #include "nsStringFlags.h" |
193 | #include "nsStringFwd.h" |
194 | #include "nsTArray.h" |
195 | #include "nsTHashSet.h" |
196 | #include "nsTHashtable.h" |
197 | #include "nsTLiteralString.h" |
198 | #include "nsTStringRepr.h" |
199 | #include "nsThreadPool.h" |
200 | #include "nsThreadUtils.h" |
201 | #include "nscore.h" |
202 | #include "prinrval.h" |
203 | #include "prio.h" |
204 | #include "prsystem.h" |
205 | #include "prthread.h" |
206 | #include "prtime.h" |
207 | #include "prtypes.h" |
208 | #include "snappy/snappy.h" |
209 | |
210 | struct JSContext; |
211 | class JSObject; |
212 | template <class T> |
213 | class nsPtrHashKey; |
214 | |
215 | #define IDB_DEBUG_LOG(_args) \ |
216 | MOZ_LOG(IndexedDatabaseManager::GetLoggingModule(), LogLevel::Debug, _args)do { const ::mozilla::LogModule* moz_real_module = IndexedDatabaseManager ::GetLoggingModule(); if ((__builtin_expect(!!(mozilla::detail ::log_test(moz_real_module, LogLevel::Debug)), 0))) { mozilla ::detail::log_print(moz_real_module, LogLevel::Debug, MOZ_LOG_EXPAND_ARGS _args); } } while (0) |
217 | |
218 | #if defined(MOZ_WIDGET_ANDROID) |
219 | # define IDB_MOBILE |
220 | #endif |
221 | |
222 | // Helper macros to reduce assertion verbosity |
223 | // AUUF == ASSERT_UNREACHABLE_UNLESS_FUZZING |
224 | #ifdef DEBUG1 |
225 | # ifdef FUZZING |
226 | # define NS_AUUF_OR_WARN(...)do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" ... ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 226); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" ... ")"); do { *((volatile int*)__null) = 226; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false) NS_WARNING(__VA_ARGS__)NS_DebugBreak(NS_DEBUG_WARNING, __VA_ARGS__, nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 226) |
227 | # else |
228 | # define NS_AUUF_OR_WARN(...)do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" ... ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 228); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" ... ")"); do { *((volatile int*)__null) = 228; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false) MOZ_ASSERT(false, __VA_ARGS__)do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" __VA_ARGS__ ")" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 228); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" __VA_ARGS__ ")"); do { *((volatile int*)__null) = 228; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false) |
229 | # endif |
230 | # define NS_AUUF_OR_WARN_IF(cond)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "cond" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 230); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "cond" ")"); do { *((volatile int*)__null) = 230; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((cond)) \ |
231 | [](bool aCond) { \ |
232 | if (MOZ_UNLIKELY(aCond)(__builtin_expect(!!(aCond), 0))) { \ |
233 | NS_AUUF_OR_WARN(#cond)do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" #cond ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 233); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" #cond ")"); do { *((volatile int*)__null) = 233; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false); \ |
234 | } \ |
235 | return aCond; \ |
236 | }((cond)) |
237 | #else |
238 | # define NS_AUUF_OR_WARN(...)do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" ... ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 238); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" ... ")"); do { *((volatile int*)__null) = 238; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false) \ |
239 | do { \ |
240 | } while (false) |
241 | # define NS_AUUF_OR_WARN_IF(cond)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "cond" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 241); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "cond" ")"); do { *((volatile int*)__null) = 241; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((cond)) static_cast<bool>(cond) |
242 | #endif |
243 | |
244 | namespace mozilla { |
245 | |
246 | namespace dom::indexedDB { |
247 | |
248 | using namespace mozilla::dom::quota; |
249 | using namespace mozilla::ipc; |
250 | using mozilla::dom::quota::Client; |
251 | |
252 | namespace { |
253 | |
254 | class ConnectionPool; |
255 | class Database; |
256 | struct DatabaseActorInfo; |
257 | class DatabaseFile; |
258 | class DatabaseLoggingInfo; |
259 | class DatabaseMaintenance; |
260 | class Factory; |
261 | class Maintenance; |
262 | class OpenDatabaseOp; |
263 | class TransactionBase; |
264 | class TransactionDatabaseOperationBase; |
265 | class VersionChangeTransaction; |
266 | template <bool StatementHasIndexKeyBindings> |
267 | struct ValuePopulateResponseHelper; |
268 | |
269 | /******************************************************************************* |
270 | * Constants |
271 | ******************************************************************************/ |
272 | |
273 | const int32_t kStorageProgressGranularity = 1000; |
274 | |
275 | // Changing the value here will override the page size of new databases only. |
276 | // A journal mode change and VACUUM are needed to change existing databases, so |
277 | // the best way to do that is to use the schema version upgrade mechanism. |
278 | const uint32_t kSQLitePageSizeOverride = |
279 | #ifdef IDB_MOBILE |
280 | 2048; |
281 | #else |
282 | 4096; |
283 | #endif |
284 | |
285 | static_assert(kSQLitePageSizeOverride == /* mozStorage default */ 0 || |
286 | (kSQLitePageSizeOverride % 2 == 0 && |
287 | kSQLitePageSizeOverride >= 512 && |
288 | kSQLitePageSizeOverride <= 65536), |
289 | "Must be 0 (disabled) or a power of 2 between 512 and 65536!"); |
290 | |
291 | // Set to -1 to use SQLite's default, 0 to disable, or some positive number to |
292 | // enforce a custom limit. |
293 | const int32_t kMaxWALPages = 5000; // 20MB on desktop, 10MB on mobile. |
294 | |
295 | // Set to some multiple of the page size to grow the database in larger chunks. |
296 | const uint32_t kSQLiteGrowthIncrement = kSQLitePageSizeOverride * 2; |
297 | |
298 | static_assert(kSQLiteGrowthIncrement >= 0 && |
299 | kSQLiteGrowthIncrement % kSQLitePageSizeOverride == 0 && |
300 | kSQLiteGrowthIncrement < uint32_t(INT32_MAX(2147483647)), |
301 | "Must be 0 (disabled) or a positive multiple of the page size!"); |
302 | |
303 | // The maximum number of threads that can be used for database activity at a |
304 | // single time. Please keep in sync with the constants in |
305 | // test_connection_idle_maintenance*.js tests |
306 | const uint32_t kMaxConnectionThreadCount = 20; |
307 | |
308 | static_assert(kMaxConnectionThreadCount, "Must have at least one thread!"); |
309 | |
310 | // The maximum number of threads to keep when idle. Until we switch to the STS |
311 | // pool, we can reduce the number of idle threads kept around thanks to the |
312 | // grace timeout. |
313 | const uint32_t kMaxIdleConnectionThreadCount = 1; |
314 | |
315 | static_assert(kMaxConnectionThreadCount >= kMaxIdleConnectionThreadCount, |
316 | "Idle thread limit must be less than total thread limit!"); |
317 | |
318 | // The length of time that wanted idle threads will stay alive before being shut |
319 | // down. |
320 | const uint32_t kConnectionThreadMaxIdleMS = 30 * 1000; // 30 seconds |
321 | |
322 | // The length of time that excess idle threads will stay alive before being shut |
323 | // down. |
324 | const uint32_t kConnectionThreadGraceIdleMS = 500; // 0.5 seconds |
325 | |
326 | // The length of time that database connections will be held open after all |
327 | // transactions have completed before doing idle maintenance. Please keep in |
328 | // sync with the timeouts in test_connection_idle_maintenance*.js tests |
329 | const uint32_t kConnectionIdleMaintenanceMS = 2 * 1000; // 2 seconds |
330 | |
331 | // The length of time that database connections will be held open after all |
332 | // transactions and maintenance have completed. |
333 | const uint32_t kConnectionIdleCloseMS = 10 * 1000; // 10 seconds |
334 | |
335 | #define SAVEPOINT_CLAUSE"SAVEPOINT sp;"_ns "SAVEPOINT sp;"_ns |
336 | |
337 | // For efficiency reasons, kEncryptedStreamBlockSize must be a multiple of large |
338 | // 4k disk sectors. |
339 | static_assert(kEncryptedStreamBlockSize % 4096 == 0); |
340 | // Similarly, the file copy buffer size must be a multiple of the encrypted |
341 | // block size. |
342 | static_assert(kFileCopyBufferSize % kEncryptedStreamBlockSize == 0); |
343 | |
344 | constexpr auto kFileManagerDirectoryNameSuffix = u".files"_ns; |
345 | constexpr auto kSQLiteSuffix = u".sqlite"_ns; |
346 | constexpr auto kSQLiteJournalSuffix = u".sqlite-journal"_ns; |
347 | constexpr auto kSQLiteSHMSuffix = u".sqlite-shm"_ns; |
348 | constexpr auto kSQLiteWALSuffix = u".sqlite-wal"_ns; |
349 | |
350 | // The following constants define all names of binding parameters in statements, |
351 | // where they are bound by name. This should include all parameter names which |
352 | // are bound by name. Binding may be done by index when the statement definition |
353 | // and binding are done in the same local scope, and no other reasons prevent |
354 | // using the indexes (e.g. multiple statement variants with differing number or |
355 | // order of parameters). Neither the styles of specifying parameter names |
356 | // (literally vs. via these constants) nor the binding styles (by index vs. by |
357 | // name) should not be mixed for the same statement. The decision must be made |
358 | // for each statement based on the proximity of statement and binding calls. |
359 | constexpr auto kStmtParamNameCurrentKey = "current_key"_ns; |
360 | constexpr auto kStmtParamNameRangeBound = "range_bound"_ns; |
361 | constexpr auto kStmtParamNameObjectStorePosition = "object_store_position"_ns; |
362 | constexpr auto kStmtParamNameLowerKey = "lower_key"_ns; |
363 | constexpr auto kStmtParamNameUpperKey = "upper_key"_ns; |
364 | constexpr auto kStmtParamNameKey = "key"_ns; |
365 | constexpr auto kStmtParamNameObjectStoreId = "object_store_id"_ns; |
366 | constexpr auto kStmtParamNameIndexId = "index_id"_ns; |
367 | // TODO: Maybe the uses of kStmtParamNameId should be replaced by more |
368 | // specific constants such as kStmtParamNameObjectStoreId. |
369 | constexpr auto kStmtParamNameId = "id"_ns; |
370 | constexpr auto kStmtParamNameValue = "value"_ns; |
371 | constexpr auto kStmtParamNameObjectDataKey = "object_data_key"_ns; |
372 | constexpr auto kStmtParamNameIndexDataValues = "index_data_values"_ns; |
373 | constexpr auto kStmtParamNameData = "data"_ns; |
374 | constexpr auto kStmtParamNameFileIds = "file_ids"_ns; |
375 | constexpr auto kStmtParamNameValueLocale = "value_locale"_ns; |
376 | constexpr auto kStmtParamNameLimit = "limit"_ns; |
377 | |
378 | // The following constants define some names of columns in tables, which are |
379 | // referred to in remote locations, e.g. in calls to |
380 | // GetBindingClauseForKeyRange. |
381 | constexpr auto kColumnNameKey = "key"_ns; |
382 | constexpr auto kColumnNameValue = "value"_ns; |
383 | constexpr auto kColumnNameAliasSortKey = "sort_column"_ns; |
384 | |
385 | // SQL fragments used at multiple locations. |
386 | constexpr auto kOpenLimit = " LIMIT "_ns; |
387 | |
388 | // The deletion marker file is created before RemoveDatabaseFilesAndDirectory |
389 | // begins deleting a database. It is removed as the last step of deletion. If a |
390 | // deletion marker file is found when initializing the origin, the deletion |
391 | // routine is run again to ensure that the database and all of its related files |
392 | // are removed. The primary goal of this mechanism is to avoid situations where |
393 | // a database has been partially deleted, leading to inconsistent state for the |
394 | // origin. |
395 | constexpr auto kIdbDeletionMarkerFilePrefix = u"idb-deleting-"_ns; |
396 | |
397 | const uint32_t kDeleteTimeoutMs = 1000; |
398 | |
399 | #ifdef DEBUG1 |
400 | |
401 | const int32_t kDEBUGThreadPriority = nsISupportsPriority::PRIORITY_NORMAL; |
402 | const uint32_t kDEBUGThreadSleepMS = 0; |
403 | |
404 | // Set to a non-zero number to enable debugging of transaction event targets. |
405 | // It will cause sleeping after every transaction runnable! |
406 | // |
407 | // This can be useful for discovering race conditions related to switching to |
408 | // another thread. Such races are usually avoided by using MozPromise or |
409 | // RunAfterProcessingCurrentEvent. Chaos mode doesn't always help with |
410 | // uncovering these issues, and only a precisely targeted sleep call can |
411 | // simulate the problem. |
412 | const uint32_t kDEBUGTransactionThreadSleepMS = 0; |
413 | |
414 | // Make sure that we notice if we ever accidentally check in a non-zero value. |
415 | # ifdef MOZILLA_OFFICIAL |
416 | static_assert(kDEBUGTransactionThreadSleepMS == 0); |
417 | # endif |
418 | |
419 | #endif |
420 | |
421 | /******************************************************************************* |
422 | * Metadata classes |
423 | ******************************************************************************/ |
424 | |
425 | // Can be instantiated either on the QuotaManager IO thread or on a |
426 | // versionchange transaction thread. These threads can never race so this is |
427 | // totally safe. |
428 | struct FullIndexMetadata { |
429 | IndexMetadata mCommonMetadata = {0, nsString(), KeyPath(0), nsCString(), |
430 | false, false, false}; |
431 | |
432 | FlippedOnce<false> mDeleted; |
433 | |
434 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(FullIndexMetadata)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<FullIndexMetadata>, "Reference-counted class " "FullIndexMetadata" " should not have a public destructor. " "Make this class's destructor non-public"); do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 434); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 434; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("FullIndexMetadata"), (uint32_t)(sizeof(*this))) ; return (nsrefcnt)count; } MozExternalRefCountType Release(void ) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 434); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 434 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("FullIndexMetadata")); if (count == 0) { delete (this ); return 0; } return count; } using HasThreadSafeRefCnt = std ::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt ; public: |
435 | |
436 | private: |
437 | ~FullIndexMetadata() = default; |
438 | }; |
439 | |
440 | using IndexTable = nsTHashMap<nsUint64HashKey, SafeRefPtr<FullIndexMetadata>>; |
441 | |
442 | // Can be instantiated either on the QuotaManager IO thread or on a |
443 | // versionchange transaction thread. These threads can never race so this is |
444 | // totally safe. |
445 | struct FullObjectStoreMetadata { |
446 | ObjectStoreMetadata mCommonMetadata; |
447 | IndexTable mIndexes; |
448 | |
449 | // The auto increment ids are touched on both the background thread and the |
450 | // transaction I/O thread, and they must be kept in sync, so we need a mutex |
451 | // to protect them. |
452 | struct AutoIncrementIds { |
453 | int64_t next; |
454 | int64_t committed; |
455 | }; |
456 | DataMutex<AutoIncrementIds> mAutoIncrementIds; |
457 | |
458 | FlippedOnce<false> mDeleted; |
459 | |
460 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(FullObjectStoreMetadata)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<FullObjectStoreMetadata>, "Reference-counted class " "FullObjectStoreMetadata" " should not have a public destructor. " "Make this class's destructor non-public"); do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 460); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 460; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("FullObjectStoreMetadata"), (uint32_t)(sizeof(*this ))); return (nsrefcnt)count; } MozExternalRefCountType Release (void) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 460); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 460 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("FullObjectStoreMetadata")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public:; |
461 | |
462 | bool HasLiveIndexes() const; |
463 | |
464 | FullObjectStoreMetadata(ObjectStoreMetadata aCommonMetadata, |
465 | const AutoIncrementIds& aAutoIncrementIds) |
466 | : mCommonMetadata{std::move(aCommonMetadata)}, |
467 | mAutoIncrementIds{AutoIncrementIds{aAutoIncrementIds}, |
468 | "FullObjectStoreMetadata"} {} |
469 | |
470 | private: |
471 | ~FullObjectStoreMetadata() = default; |
472 | }; |
473 | |
474 | using ObjectStoreTable = |
475 | nsTHashMap<nsUint64HashKey, SafeRefPtr<FullObjectStoreMetadata>>; |
476 | |
477 | static_assert( |
478 | std::is_same_v<IndexOrObjectStoreId, |
479 | std::remove_cv_t<std::remove_reference_t< |
480 | decltype(std::declval<const ObjectStoreGetParams&>() |
481 | .objectStoreId())>>>); |
482 | static_assert( |
483 | std::is_same_v< |
484 | IndexOrObjectStoreId, |
485 | std::remove_cv_t<std::remove_reference_t< |
486 | decltype(std::declval<const IndexGetParams&>().objectStoreId())>>>); |
487 | |
488 | struct FullDatabaseMetadata final : AtomicSafeRefCounted<FullDatabaseMetadata> { |
489 | DatabaseMetadata mCommonMetadata; |
490 | nsCString mDatabaseId; |
491 | nsString mFilePath; |
492 | ObjectStoreTable mObjectStores; |
493 | |
494 | IndexOrObjectStoreId mNextObjectStoreId = 0; |
495 | IndexOrObjectStoreId mNextIndexId = 0; |
496 | |
497 | public: |
498 | explicit FullDatabaseMetadata(const DatabaseMetadata& aCommonMetadata) |
499 | : mCommonMetadata(aCommonMetadata) { |
500 | AssertIsOnBackgroundThread(); |
501 | } |
502 | |
503 | [[nodiscard]] SafeRefPtr<FullDatabaseMetadata> Duplicate() const; |
504 | |
505 | MOZ_DECLARE_REFCOUNTED_TYPENAME(FullDatabaseMetadata)const char* typeName() const { return "FullDatabaseMetadata"; } size_t typeSize() const { return sizeof(*this); } |
506 | }; |
507 | |
508 | template <class Enumerable> |
509 | auto MatchMetadataNameOrId(const Enumerable& aEnumerable, |
510 | IndexOrObjectStoreId aId, |
511 | Maybe<const nsAString&> aName = Nothing()) { |
512 | AssertIsOnBackgroundThread(); |
513 | MOZ_ASSERT(aId)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aId)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aId))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("aId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 513); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aId" ")"); do { *((volatile int*)__null) = 513; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); |
514 | |
515 | const auto it = std::find_if( |
516 | aEnumerable.cbegin(), aEnumerable.cend(), |
517 | [aId, aName](const auto& entry) { |
518 | MOZ_ASSERT(entry.GetKey() != 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(entry.GetKey() != 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(entry.GetKey() != 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("entry.GetKey() != 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 518); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey() != 0" ")"); do { *((volatile int*)__null) = 518; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
519 | |
520 | const auto& value = entry.GetData(); |
521 | MOZ_ASSERT(value)do { static_assert( mozilla::detail::AssertionConditionType< decltype(value)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(value))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("value", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 521); AnnotateMozCrashReason("MOZ_ASSERT" "(" "value" ")"); do { *((volatile int*)__null) = 521; __attribute__((nomerge) ) ::abort(); } while (false); } } while (false); |
522 | |
523 | return !value->mDeleted && |
524 | (aId == value->mCommonMetadata.id() || |
525 | (aName && *aName == value->mCommonMetadata.name())); |
526 | }); |
527 | |
528 | return ToMaybeRef(it != aEnumerable.cend() ? it->GetData().unsafeGetRawPtr() |
529 | : nullptr); |
530 | } |
531 | |
532 | /******************************************************************************* |
533 | * SQLite functions |
534 | ******************************************************************************/ |
535 | |
536 | // WARNING: the hash function used for the database name must not change. |
537 | // That's why this function exists separately from mozilla::HashString(), even |
538 | // though it is (at the time of writing) equivalent. See bug 780408 and bug |
539 | // 940315 for details. |
540 | uint32_t HashName(const nsAString& aName) { |
541 | struct Helper { |
542 | static uint32_t RotateBitsLeft32(uint32_t aValue, uint8_t aBits) { |
543 | MOZ_ASSERT(aBits < 32)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aBits < 32)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aBits < 32))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aBits < 32", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 543); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aBits < 32" ")"); do { *((volatile int*)__null) = 543; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
544 | return (aValue << aBits) | (aValue >> (32 - aBits)); |
545 | } |
546 | }; |
547 | |
548 | static const uint32_t kGoldenRatioU32 = 0x9e3779b9u; |
549 | |
550 | return std::accumulate(aName.BeginReading(), aName.EndReading(), uint32_t(0), |
551 | [](uint32_t hash, char16_t ch) { |
552 | return kGoldenRatioU32 * |
553 | (Helper::RotateBitsLeft32(hash, 5) ^ ch); |
554 | }); |
555 | } |
556 | |
557 | nsresult ClampResultCode(nsresult aResultCode) { |
558 | if (NS_SUCCEEDED(aResultCode)((bool)(__builtin_expect(!!(!NS_FAILED_impl(aResultCode)), 1) )) || |
559 | NS_ERROR_GET_MODULE(aResultCode) == NS_ERROR_MODULE_DOM_INDEXEDDB33) { |
560 | return aResultCode; |
561 | } |
562 | |
563 | switch (aResultCode) { |
564 | case NS_ERROR_FILE_NO_DEVICE_SPACE: |
565 | return NS_ERROR_DOM_INDEXEDDB_QUOTA_ERR; |
566 | case NS_ERROR_STORAGE_CONSTRAINT: |
567 | return NS_ERROR_DOM_INDEXEDDB_CONSTRAINT_ERR; |
568 | default: |
569 | #ifdef DEBUG1 |
570 | nsPrintfCString message("Converting non-IndexedDB error code (0x%" PRIX32"X" |
571 | ") to " |
572 | "NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR", |
573 | static_cast<uint32_t>(aResultCode)); |
574 | NS_WARNING(message.get())NS_DebugBreak(NS_DEBUG_WARNING, message.get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 574); |
575 | #else |
576 | ; |
577 | #endif |
578 | } |
579 | |
580 | IDB_REPORT_INTERNAL_ERR()mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 580, "UnknownErr"); |
581 | return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; |
582 | } |
583 | |
584 | Result<nsCOMPtr<nsIFileURL>, nsresult> GetDatabaseFileURL( |
585 | nsIFile& aDatabaseFile, const int64_t aDirectoryLockId, |
586 | const Maybe<CipherKey>& aMaybeKey) { |
587 | MOZ_ASSERT(aDirectoryLockId >= -1)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectoryLockId >= -1)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectoryLockId >= -1))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectoryLockId >= -1" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 587); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectoryLockId >= -1" ")"); do { *((volatile int*)__null) = 587; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
588 | |
589 | QM_TRY_INSPECT(auto tryResult782 = (::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/network/protocol;1?name=" "file")); if ((__builtin_expect (!!(tryResult782.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/network/protocol;1?name=\" \"file\")" , tryResult782.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 593, mozilla::dom::quota::Severity::Error); return tryResult782 .propagateErr(); } const auto& protocolHandler = tryResult782 .inspect(); |
590 | const auto& protocolHandler,auto tryResult782 = (::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/network/protocol;1?name=" "file")); if ((__builtin_expect (!!(tryResult782.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/network/protocol;1?name=\" \"file\")" , tryResult782.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 593, mozilla::dom::quota::Severity::Error); return tryResult782 .propagateErr(); } const auto& protocolHandler = tryResult782 .inspect(); |
591 | MOZ_TO_RESULT_GET_TYPED(nsCOMPtr<nsIProtocolHandler>,auto tryResult782 = (::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/network/protocol;1?name=" "file")); if ((__builtin_expect (!!(tryResult782.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/network/protocol;1?name=\" \"file\")" , tryResult782.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 593, mozilla::dom::quota::Severity::Error); return tryResult782 .propagateErr(); } const auto& protocolHandler = tryResult782 .inspect(); |
592 | MOZ_SELECT_OVERLOAD(do_GetService),auto tryResult782 = (::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/network/protocol;1?name=" "file")); if ((__builtin_expect (!!(tryResult782.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/network/protocol;1?name=\" \"file\")" , tryResult782.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 593, mozilla::dom::quota::Severity::Error); return tryResult782 .propagateErr(); } const auto& protocolHandler = tryResult782 .inspect(); |
593 | NS_NETWORK_PROTOCOL_CONTRACTID_PREFIX "file"))auto tryResult782 = (::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/network/protocol;1?name=" "file")); if ((__builtin_expect (!!(tryResult782.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<nsIProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/network/protocol;1?name=\" \"file\")" , tryResult782.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 593, mozilla::dom::quota::Severity::Error); return tryResult782 .propagateErr(); } const auto& protocolHandler = tryResult782 .inspect();; |
594 | |
595 | QM_TRY_INSPECT(const auto& fileHandler,auto tryResult783 = (::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs) ...); }, protocolHandler)); if ((__builtin_expect(!!(tryResult783 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs)...); }, protocolHandler)" , tryResult783.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 598, mozilla::dom::quota::Severity::Error); return tryResult783 .propagateErr(); } const auto& fileHandler = tryResult783 .inspect(); |
596 | MOZ_TO_RESULT_GET_TYPED(nsCOMPtr<nsIFileProtocolHandler>,auto tryResult783 = (::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs) ...); }, protocolHandler)); if ((__builtin_expect(!!(tryResult783 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs)...); }, protocolHandler)" , tryResult783.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 598, mozilla::dom::quota::Severity::Error); return tryResult783 .propagateErr(); } const auto& fileHandler = tryResult783 .inspect(); |
597 | MOZ_SELECT_OVERLOAD(do_QueryInterface),auto tryResult783 = (::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs) ...); }, protocolHandler)); if ((__builtin_expect(!!(tryResult783 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs)...); }, protocolHandler)" , tryResult783.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 598, mozilla::dom::quota::Severity::Error); return tryResult783 .propagateErr(); } const auto& fileHandler = tryResult783 .inspect(); |
598 | protocolHandler))auto tryResult783 = (::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler > >([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs) ...); }, protocolHandler)); if ((__builtin_expect(!!(tryResult783 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultGet< nsCOMPtr<nsIFileProtocolHandler>>([](auto&&... aArgs) -> decltype(auto) { return do_QueryInterface(std::forward<decltype(aArgs)>(aArgs)...); }, protocolHandler)" , tryResult783.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 598, mozilla::dom::quota::Severity::Error); return tryResult783 .propagateErr(); } const auto& fileHandler = tryResult783 .inspect();; |
599 | |
600 | QM_TRY_INSPECT(const auto& mutator, MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult784 = (::mozilla::ToResultInvoke< nsCOMPtr< nsIURIMutator> >( ::std::mem_fn( &::mozilla::detail ::DerefedType<decltype(fileHandler)>::NewFileURIMutator ), (fileHandler), &aDatabaseFile)); if ((__builtin_expect (!!(tryResult784.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<nsIURIMutator>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(fileHandler)>::NewFileURIMutator), (fileHandler), &aDatabaseFile)" , tryResult784.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 602, mozilla::dom::quota::Severity::Error); return tryResult784 .propagateErr(); } const auto& mutator = tryResult784.inspect (); |
601 | nsCOMPtr<nsIURIMutator>, fileHandler,auto tryResult784 = (::mozilla::ToResultInvoke< nsCOMPtr< nsIURIMutator> >( ::std::mem_fn( &::mozilla::detail ::DerefedType<decltype(fileHandler)>::NewFileURIMutator ), (fileHandler), &aDatabaseFile)); if ((__builtin_expect (!!(tryResult784.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<nsIURIMutator>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(fileHandler)>::NewFileURIMutator), (fileHandler), &aDatabaseFile)" , tryResult784.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 602, mozilla::dom::quota::Severity::Error); return tryResult784 .propagateErr(); } const auto& mutator = tryResult784.inspect (); |
602 | NewFileURIMutator, &aDatabaseFile))auto tryResult784 = (::mozilla::ToResultInvoke< nsCOMPtr< nsIURIMutator> >( ::std::mem_fn( &::mozilla::detail ::DerefedType<decltype(fileHandler)>::NewFileURIMutator ), (fileHandler), &aDatabaseFile)); if ((__builtin_expect (!!(tryResult784.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<nsIURIMutator>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(fileHandler)>::NewFileURIMutator), (fileHandler), &aDatabaseFile)" , tryResult784.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 602, mozilla::dom::quota::Severity::Error); return tryResult784 .propagateErr(); } const auto& mutator = tryResult784.inspect ();; |
603 | |
604 | // aDirectoryLockId should only be -1 when we are called |
605 | // - from DatabaseFileManager::InitDirectory when the temporary storage |
606 | // hasn't been initialized yet. At that time, the in-memory objects (e.g. |
607 | // OriginInfo) are only being created so it doesn't make sense to tunnel |
608 | // quota information to QuotaVFS to get corresponding QuotaObject instances |
609 | // for SQLite files. |
610 | // - from DeleteDatabaseOp::LoadPreviousVersion, since this might require |
611 | // temporarily exceeding the quota limit before the database can be |
612 | // deleted. |
613 | const nsCString directoryLockIdClause = |
614 | "&directoryLockId="_ns + IntToCString(aDirectoryLockId); |
615 | |
616 | const auto keyClause = [&aMaybeKey] { |
617 | nsAutoCString keyClause; |
618 | if (aMaybeKey) { |
619 | keyClause.AssignLiteral("&key="); |
620 | for (uint8_t byte : IndexedDBCipherStrategy::SerializeKey(*aMaybeKey)) { |
621 | keyClause.AppendPrintf("%02x", byte); |
622 | } |
623 | } |
624 | return keyClause; |
625 | }(); |
626 | |
627 | QM_TRY_UNWRAP(auto result, ([&mutator, &directoryLockIdClause, &keyClause] {auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
628 | nsCOMPtr<nsIFileURL> result;auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
629 | nsresult rv = NS_MutateURI(mutator)auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
630 | .SetQuery("cache=private"_ns +auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
631 | directoryLockIdClause + keyClause)auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
632 | .Finalize(result);auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
633 | return NS_SUCCEEDED(rv)auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
634 | ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result}auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
635 | : Err(rv);auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap(); |
636 | }()))auto tryResult785 = (([&mutator, &directoryLockIdClause , &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery("cache=private"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect (!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL >, nsresult>{result} : Err(rv); }())); if ((__builtin_expect (!!(tryResult785.isErr()), 0))) { mozilla::dom::quota::HandleError ("([&mutator, &directoryLockIdClause, &keyClause] { nsCOMPtr<nsIFileURL> result; nsresult rv = NS_MutateURI(mutator) .SetQuery(\"cache=private\"_ns + directoryLockIdClause + keyClause) .Finalize(result); return ((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1))) ? Result<nsCOMPtr<nsIFileURL>, nsresult>{result} : Err(rv); }())" , tryResult785.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 636, mozilla::dom::quota::Severity::Error); return tryResult785 .propagateErr(); } auto result = tryResult785.unwrap();; |
637 | |
638 | return result; |
639 | } |
640 | |
641 | nsLiteralCString GetDefaultSynchronousMode() { |
642 | return IndexedDatabaseManager::FullSynchronous() ? "FULL"_ns : "NORMAL"_ns; |
643 | } |
644 | |
645 | nsresult SetDefaultPragmas(mozIStorageConnection& aConnection) { |
646 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 646); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 646; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
647 | |
648 | static constexpr auto kBuiltInPragmas = |
649 | // We use foreign keys in DEBUG builds only because there is a performance |
650 | // cost to using them. |
651 | "PRAGMA foreign_keys = " |
652 | #ifdef DEBUG1 |
653 | "ON" |
654 | #else |
655 | "OFF" |
656 | #endif |
657 | ";" |
658 | |
659 | // The "INSERT OR REPLACE" statement doesn't fire the update trigger, |
660 | // instead it fires only the insert trigger. This confuses the update |
661 | // refcount function. This behavior changes with enabled recursive |
662 | // triggers, so the statement fires the delete trigger first and then the |
663 | // insert trigger. |
664 | "PRAGMA recursive_triggers = ON;" |
665 | |
666 | // We aggressively truncate the database file when idle so don't bother |
667 | // overwriting the WAL with 0 during active periods. |
668 | "PRAGMA secure_delete = OFF;"_ns; |
669 | |
670 | QM_TRY(MOZ_TO_RESULT(aConnection.ExecuteSimpleSQL(kBuiltInPragmas))){auto tryResult786 = (ToResult(aConnection.ExecuteSimpleSQL(kBuiltInPragmas ))); static_assert(std::is_empty_v<typename decltype(tryResult786 )::ok_type>); if ((__builtin_expect(!!(tryResult786.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(aConnection.ExecuteSimpleSQL(kBuiltInPragmas))" , tryResult786.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 670, mozilla::dom::quota::Severity::Error); return tryResult786 .propagateErr(); }}; |
671 | |
672 | QM_TRY(MOZ_TO_RESULT(aConnection.ExecuteSimpleSQL(nsAutoCString{{auto tryResult787 = (ToResult(aConnection.ExecuteSimpleSQL(nsAutoCString { "PRAGMA synchronous = "_ns + GetDefaultSynchronousMode() + ";"_ns }))); static_assert(std::is_empty_v<typename decltype(tryResult787 )::ok_type>); if ((__builtin_expect(!!(tryResult787.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(aConnection.ExecuteSimpleSQL(nsAutoCString{ \"PRAGMA synchronous = \"_ns + GetDefaultSynchronousMode() + \";\"_ns}))" , tryResult787.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 673, mozilla::dom::quota::Severity::Error); return tryResult787 .propagateErr(); }} |
673 | "PRAGMA synchronous = "_ns + GetDefaultSynchronousMode() + ";"_ns}))){auto tryResult787 = (ToResult(aConnection.ExecuteSimpleSQL(nsAutoCString { "PRAGMA synchronous = "_ns + GetDefaultSynchronousMode() + ";"_ns }))); static_assert(std::is_empty_v<typename decltype(tryResult787 )::ok_type>); if ((__builtin_expect(!!(tryResult787.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(aConnection.ExecuteSimpleSQL(nsAutoCString{ \"PRAGMA synchronous = \"_ns + GetDefaultSynchronousMode() + \";\"_ns}))" , tryResult787.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 673, mozilla::dom::quota::Severity::Error); return tryResult787 .propagateErr(); }}; |
674 | |
675 | #ifndef IDB_MOBILE |
676 | if (kSQLiteGrowthIncrement) { |
677 | // This is just an optimization so ignore the failure if the disk is |
678 | // currently too full. |
679 | QM_TRY(QM_OR_ELSE_WARN_IF({auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
680 | // Expression.{auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
681 | MOZ_TO_RESULT({auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
682 | aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns)),{auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
683 | // Predicate.{auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
684 | IsSpecificError<NS_ERROR_FILE_TOO_BIG>,{auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
685 | // Fallback.{auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }} |
686 | ErrToDefaultOk<>)){auto tryResult788 = (mozilla::dom::quota::OrElseIf( (ToResult (aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, ""_ns ))), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota:: HandleError("\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\"\\\"_ns))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult788)::ok_type>); if ((__builtin_expect(!!(tryResult788 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \"\"_ns))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_TOO_BIG>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aConnection.SetGrowthIncrement(kSQLiteGrowthIncrement, \\\\\\\"\\\\\\\"_ns))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 686, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult788.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 686, mozilla::dom::quota::Severity::Error); return tryResult788 .propagateErr(); }}; |
687 | } |
688 | #endif // IDB_MOBILE |
689 | |
690 | return NS_OK; |
691 | } |
692 | |
693 | nsresult SetJournalMode(mozIStorageConnection& aConnection) { |
694 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 694); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 694; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
695 | |
696 | // Try enabling WAL mode. This can fail in various circumstances so we have to |
697 | // check the results here. |
698 | constexpr auto journalModeQueryStart = "PRAGMA journal_mode = "_ns; |
699 | constexpr auto journalModeWAL = "wal"_ns; |
700 | |
701 | QM_TRY_INSPECT(const auto& stmt,auto tryResult789 = (CreateAndExecuteSingleStepStatement( aConnection , journalModeQueryStart + journalModeWAL)); if ((__builtin_expect (!!(tryResult789.isErr()), 0))) { mozilla::dom::quota::HandleError ("CreateAndExecuteSingleStepStatement( aConnection, journalModeQueryStart + journalModeWAL)" , tryResult789.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 703, mozilla::dom::quota::Severity::Error); return tryResult789 .propagateErr(); } const auto& stmt = tryResult789.inspect (); |
702 | CreateAndExecuteSingleStepStatement(auto tryResult789 = (CreateAndExecuteSingleStepStatement( aConnection , journalModeQueryStart + journalModeWAL)); if ((__builtin_expect (!!(tryResult789.isErr()), 0))) { mozilla::dom::quota::HandleError ("CreateAndExecuteSingleStepStatement( aConnection, journalModeQueryStart + journalModeWAL)" , tryResult789.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 703, mozilla::dom::quota::Severity::Error); return tryResult789 .propagateErr(); } const auto& stmt = tryResult789.inspect (); |
703 | aConnection, journalModeQueryStart + journalModeWAL))auto tryResult789 = (CreateAndExecuteSingleStepStatement( aConnection , journalModeQueryStart + journalModeWAL)); if ((__builtin_expect (!!(tryResult789.isErr()), 0))) { mozilla::dom::quota::HandleError ("CreateAndExecuteSingleStepStatement( aConnection, journalModeQueryStart + journalModeWAL)" , tryResult789.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 703, mozilla::dom::quota::Severity::Error); return tryResult789 .propagateErr(); } const auto& stmt = tryResult789.inspect ();; |
704 | |
705 | QM_TRY_INSPECT(auto tryResult790 = (::mozilla::ToResultInvoke< nsCString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (*stmt)>::GetUTF8String), (*stmt), 0)); if ((__builtin_expect (!!(tryResult790.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*stmt)>::GetUTF8String), (*stmt), 0)" , tryResult790.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 707, mozilla::dom::quota::Severity::Error); return tryResult790 .propagateErr(); } const auto& journalMode = tryResult790 .inspect(); |
706 | const auto& journalMode,auto tryResult790 = (::mozilla::ToResultInvoke< nsCString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (*stmt)>::GetUTF8String), (*stmt), 0)); if ((__builtin_expect (!!(tryResult790.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*stmt)>::GetUTF8String), (*stmt), 0)" , tryResult790.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 707, mozilla::dom::quota::Severity::Error); return tryResult790 .propagateErr(); } const auto& journalMode = tryResult790 .inspect(); |
707 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(nsCString, *stmt, GetUTF8String, 0))auto tryResult790 = (::mozilla::ToResultInvoke< nsCString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (*stmt)>::GetUTF8String), (*stmt), 0)); if ((__builtin_expect (!!(tryResult790.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*stmt)>::GetUTF8String), (*stmt), 0)" , tryResult790.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 707, mozilla::dom::quota::Severity::Error); return tryResult790 .propagateErr(); } const auto& journalMode = tryResult790 .inspect();; |
708 | |
709 | if (journalMode.Equals(journalModeWAL)) { |
710 | // WAL mode successfully enabled. Maybe set limits on its size here. |
711 | if (kMaxWALPages >= 0) { |
712 | QM_TRY(MOZ_TO_RESULT(aConnection.ExecuteSimpleSQL({auto tryResult791 = (ToResult(aConnection.ExecuteSimpleSQL( "PRAGMA wal_autocheckpoint = "_ns + IntToCString(kMaxWALPages)))); static_assert(std::is_empty_v <typename decltype(tryResult791)::ok_type>); if ((__builtin_expect (!!(tryResult791.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aConnection.ExecuteSimpleSQL( \"PRAGMA wal_autocheckpoint = \"_ns + IntToCString(kMaxWALPages)))" , tryResult791.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 713, mozilla::dom::quota::Severity::Error); return tryResult791 .propagateErr(); }} |
713 | "PRAGMA wal_autocheckpoint = "_ns + IntToCString(kMaxWALPages)))){auto tryResult791 = (ToResult(aConnection.ExecuteSimpleSQL( "PRAGMA wal_autocheckpoint = "_ns + IntToCString(kMaxWALPages)))); static_assert(std::is_empty_v <typename decltype(tryResult791)::ok_type>); if ((__builtin_expect (!!(tryResult791.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aConnection.ExecuteSimpleSQL( \"PRAGMA wal_autocheckpoint = \"_ns + IntToCString(kMaxWALPages)))" , tryResult791.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 713, mozilla::dom::quota::Severity::Error); return tryResult791 .propagateErr(); }}; |
714 | } |
715 | } else { |
716 | NS_WARNING("Failed to set WAL mode, falling back to normal journal mode.")NS_DebugBreak(NS_DEBUG_WARNING, "Failed to set WAL mode, falling back to normal journal mode." , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 716); |
717 | #ifdef IDB_MOBILE |
718 | QM_TRY(MOZ_TO_RESULT({auto tryResult792 = (ToResult(aConnection.ExecuteSimpleSQL(journalModeQueryStart + "truncate"_ns))); static_assert(std::is_empty_v<typename decltype(tryResult792)::ok_type>); if ((__builtin_expect( !!(tryResult792.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aConnection.ExecuteSimpleSQL(journalModeQueryStart + \"truncate\"_ns))" , tryResult792.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 719, mozilla::dom::quota::Severity::Error); return tryResult792 .propagateErr(); }} |
719 | aConnection.ExecuteSimpleSQL(journalModeQueryStart + "truncate"_ns))){auto tryResult792 = (ToResult(aConnection.ExecuteSimpleSQL(journalModeQueryStart + "truncate"_ns))); static_assert(std::is_empty_v<typename decltype(tryResult792)::ok_type>); if ((__builtin_expect( !!(tryResult792.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aConnection.ExecuteSimpleSQL(journalModeQueryStart + \"truncate\"_ns))" , tryResult792.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 719, mozilla::dom::quota::Severity::Error); return tryResult792 .propagateErr(); }}; |
720 | #endif |
721 | } |
722 | |
723 | return NS_OK; |
724 | } |
725 | |
726 | Result<MovingNotNull<nsCOMPtr<mozIStorageConnection>>, nsresult> OpenDatabase( |
727 | mozIStorageService& aStorageService, nsIFileURL& aFileURL, |
728 | const uint32_t aTelemetryId = 0) { |
729 | const nsAutoCString telemetryFilename = |
730 | aTelemetryId ? "indexedDB-"_ns + IntToCString(aTelemetryId) + |
731 | NS_ConvertUTF16toUTF8(kSQLiteSuffix) |
732 | : nsAutoCString(); |
733 | |
734 | QM_TRY_UNWRAP(auto connection,auto tryResult793 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageConnection> >( ::std::mem_fn( &::mozilla ::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL ), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService ::CONNECTION_INTERRUPTIBLE)); if ((__builtin_expect(!!(tryResult793 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageConnection>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService::CONNECTION_INTERRUPTIBLE)" , tryResult793.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 738, mozilla::dom::quota::Severity::Error); return tryResult793 .propagateErr(); } auto connection = tryResult793.unwrap(); |
735 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult793 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageConnection> >( ::std::mem_fn( &::mozilla ::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL ), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService ::CONNECTION_INTERRUPTIBLE)); if ((__builtin_expect(!!(tryResult793 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageConnection>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService::CONNECTION_INTERRUPTIBLE)" , tryResult793.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 738, mozilla::dom::quota::Severity::Error); return tryResult793 .propagateErr(); } auto connection = tryResult793.unwrap(); |
736 | nsCOMPtr<mozIStorageConnection>, aStorageService,auto tryResult793 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageConnection> >( ::std::mem_fn( &::mozilla ::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL ), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService ::CONNECTION_INTERRUPTIBLE)); if ((__builtin_expect(!!(tryResult793 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageConnection>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService::CONNECTION_INTERRUPTIBLE)" , tryResult793.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 738, mozilla::dom::quota::Severity::Error); return tryResult793 .propagateErr(); } auto connection = tryResult793.unwrap(); |
737 | OpenDatabaseWithFileURL, &aFileURL, telemetryFilename,auto tryResult793 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageConnection> >( ::std::mem_fn( &::mozilla ::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL ), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService ::CONNECTION_INTERRUPTIBLE)); if ((__builtin_expect(!!(tryResult793 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageConnection>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService::CONNECTION_INTERRUPTIBLE)" , tryResult793.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 738, mozilla::dom::quota::Severity::Error); return tryResult793 .propagateErr(); } auto connection = tryResult793.unwrap(); |
738 | mozIStorageService::CONNECTION_INTERRUPTIBLE))auto tryResult793 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageConnection> >( ::std::mem_fn( &::mozilla ::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL ), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService ::CONNECTION_INTERRUPTIBLE)); if ((__builtin_expect(!!(tryResult793 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageConnection>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aStorageService)>::OpenDatabaseWithFileURL), (aStorageService), &aFileURL, telemetryFilename, mozIStorageService::CONNECTION_INTERRUPTIBLE)" , tryResult793.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 738, mozilla::dom::quota::Severity::Error); return tryResult793 .propagateErr(); } auto connection = tryResult793.unwrap();; |
739 | |
740 | return WrapMovingNotNull(std::move(connection)); |
741 | } |
742 | |
743 | Result<MovingNotNull<nsCOMPtr<mozIStorageConnection>>, nsresult> |
744 | OpenDatabaseAndHandleBusy(mozIStorageService& aStorageService, |
745 | nsIFileURL& aFileURL, |
746 | const uint32_t aTelemetryId = 0) { |
747 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 747); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 747; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
748 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 748); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 748; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
749 | |
750 | using ConnectionType = Maybe<MovingNotNull<nsCOMPtr<mozIStorageConnection>>>; |
751 | |
752 | QM_TRY_UNWRAP(auto connection,auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
753 | QM_OR_ELSE_WARN_IF(auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
754 | // Expressionauto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
755 | OpenDatabase(aStorageService, aFileURL, aTelemetryId)auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
756 | .map([](auto connection) -> ConnectionType {auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
757 | return Some(std::move(connection));auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
758 | }),auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
759 | // Predicate.auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
760 | IsSpecificError<NS_ERROR_STORAGE_BUSY>,auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
761 | // Fallback.auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap(); |
762 | ErrToDefaultOk<ConnectionType>))auto tryResult794 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = IsSpecificError <NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota:: HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult794 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 762, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult794.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 762, mozilla::dom::quota::Severity::Error); return tryResult794 .propagateErr(); } auto connection = tryResult794.unwrap();; |
763 | |
764 | if (connection.isNothing()) { |
765 | #ifdef DEBUG1 |
766 | { |
767 | nsCString path; |
768 | MOZ_ALWAYS_SUCCEEDS(aFileURL.GetFileName(path))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aFileURL.GetFileName(path))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aFileURL.GetFileName(path))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 768); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aFileURL.GetFileName(path))" ")"); do { *((volatile int*)__null) = 768; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
769 | |
770 | nsPrintfCString message( |
771 | "Received NS_ERROR_STORAGE_BUSY when attempting to open database " |
772 | "'%s', retrying for up to 10 seconds", |
773 | path.get()); |
774 | NS_WARNING(message.get())NS_DebugBreak(NS_DEBUG_WARNING, message.get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 774); |
775 | } |
776 | #endif |
777 | |
778 | // Another thread must be checkpointing the WAL. Wait up to 10 seconds for |
779 | // that to complete. |
780 | const TimeStamp start = TimeStamp::NowLoRes(); |
781 | |
782 | do { |
783 | PR_Sleep(PR_MillisecondsToInterval(100)); |
784 | |
785 | QM_TRY_UNWRAP(connection,auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
786 | QM_OR_ELSE_WARN_IF(auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
787 | // Expression.auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
788 | OpenDatabase(aStorageService, aFileURL, aTelemetryId)auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
789 | .map([](auto connection) -> ConnectionType {auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
790 | return Some(std::move(connection));auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
791 | }),auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
792 | // Predicate.auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
793 | ([&start](nsresult aValue) {auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
794 | return aValue == NS_ERROR_STORAGE_BUSY &&auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
795 | TimeStamp::NowLoRes() - start <=auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
796 | TimeDuration::FromSeconds(10);auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
797 | }),auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
798 | // Fallback.auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap(); |
799 | ErrToDefaultOk<ConnectionType>))auto tryResult795 = (mozilla::dom::quota::OrElseIf( (OpenDatabase (aStorageService, aFileURL, aTelemetryId) .map([](auto connection ) -> ConnectionType { return Some(std::move(connection)); } )), [&](const auto& firstRes) { bool res = ([&start ](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds (10); })(firstRes); mozilla::dom::quota::HandleError("\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <ConnectionType>)); if ((__builtin_expect(!!(tryResult795 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })), [&](const auto& firstRes) { bool res = ([&start](nsresult aValue) { return aValue == NS_ERROR_STORAGE_BUSY && TimeStamp::NowLoRes() - start <= TimeDuration::FromSeconds(10); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabase(aStorageService, aFileURL, aTelemetryId) .map([](auto connection) -> ConnectionType { return Some(std::move(connection)); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 799, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<ConnectionType>)" , tryResult795.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 799, mozilla::dom::quota::Severity::Error); return tryResult795 .propagateErr(); } connection = tryResult795.unwrap();; |
800 | } while (connection.isNothing()); |
801 | } |
802 | |
803 | return connection.extract(); |
804 | } |
805 | |
806 | // Returns true if a given nsIFile exists and is a directory. Returns false if |
807 | // it doesn't exist. Returns an error if it exists, but is not a directory, or |
808 | // any other error occurs. |
809 | Result<bool, nsresult> ExistsAsDirectory(nsIFile& aDirectory) { |
810 | QM_TRY_INSPECT(const bool& exists,auto tryResult796 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult796.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::Exists)" , tryResult796.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 811, mozilla::dom::quota::Severity::Error); return tryResult796 .propagateErr(); } const bool& exists = tryResult796.inspect (); |
811 | MOZ_TO_RESULT_INVOKE_MEMBER(aDirectory, Exists))auto tryResult796 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult796.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::Exists)" , tryResult796.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 811, mozilla::dom::quota::Severity::Error); return tryResult796 .propagateErr(); } const bool& exists = tryResult796.inspect ();; |
812 | |
813 | if (exists) { |
814 | QM_TRY_INSPECT(const bool& isDirectory,auto tryResult797 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult797.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::IsDirectory)" , tryResult797.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 815, mozilla::dom::quota::Severity::Error); return tryResult797 .propagateErr(); } const bool& isDirectory = tryResult797 .inspect(); |
815 | MOZ_TO_RESULT_INVOKE_MEMBER(aDirectory, IsDirectory))auto tryResult797 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult797.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::IsDirectory)" , tryResult797.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 815, mozilla::dom::quota::Severity::Error); return tryResult797 .propagateErr(); } const bool& isDirectory = tryResult797 .inspect();; |
816 | |
817 | QM_TRY(OkIf(isDirectory), Err(NS_ERROR_FAILURE)){auto tryResult798 = (OkIf(isDirectory)); static_assert(std:: is_empty_v<typename decltype(tryResult798)::ok_type>); if ((__builtin_expect(!!(tryResult798.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult798.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(isDirectory)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 817, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(isDirectory)" , tryTempError, Err(NS_ERROR_FAILURE)); }}; |
818 | } |
819 | |
820 | return exists; |
821 | } |
822 | |
823 | constexpr nsresult mapNoDeviceSpaceError(nsresult aRv) { |
824 | if (aRv == NS_ERROR_FILE_NO_DEVICE_SPACE) { |
825 | // mozstorage translates SQLITE_FULL to |
826 | // NS_ERROR_FILE_NO_DEVICE_SPACE, which we know better as |
827 | // NS_ERROR_DOM_INDEXEDDB_QUOTA_ERR. |
828 | return NS_ERROR_DOM_INDEXEDDB_QUOTA_ERR; |
829 | } |
830 | return aRv; |
831 | } |
832 | |
833 | Result<MovingNotNull<nsCOMPtr<mozIStorageConnection>>, nsresult> |
834 | CreateStorageConnection(nsIFile& aDBFile, nsIFile& aFMDirectory, |
835 | const nsAString& aName, const nsACString& aOrigin, |
836 | const int64_t aDirectoryLockId, |
837 | const uint32_t aTelemetryId, |
838 | const Maybe<CipherKey>& aMaybeKey) { |
839 | AssertIsOnIOThread(); |
840 | MOZ_ASSERT(aDirectoryLockId >= -1)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectoryLockId >= -1)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectoryLockId >= -1))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectoryLockId >= -1" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 840); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectoryLockId >= -1" ")"); do { *((volatile int*)__null) = 840; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
841 | |
842 | AUTO_PROFILER_LABEL("CreateStorageConnection", DOM)mozilla::AutoProfilerLabel raiiObject842( "CreateStorageConnection" , nullptr, JS::ProfilingCategoryPair::DOM); |
843 | |
844 | QM_TRY_INSPECT(const auto& dbFileUrl,auto tryResult799 = (GetDatabaseFileURL(aDBFile, aDirectoryLockId , aMaybeKey)); if ((__builtin_expect(!!(tryResult799.isErr()) , 0))) { mozilla::dom::quota::HandleError("GetDatabaseFileURL(aDBFile, aDirectoryLockId, aMaybeKey)" , tryResult799.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 845, mozilla::dom::quota::Severity::Error); return tryResult799 .propagateErr(); } const auto& dbFileUrl = tryResult799.inspect (); |
845 | GetDatabaseFileURL(aDBFile, aDirectoryLockId, aMaybeKey))auto tryResult799 = (GetDatabaseFileURL(aDBFile, aDirectoryLockId , aMaybeKey)); if ((__builtin_expect(!!(tryResult799.isErr()) , 0))) { mozilla::dom::quota::HandleError("GetDatabaseFileURL(aDBFile, aDirectoryLockId, aMaybeKey)" , tryResult799.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 845, mozilla::dom::quota::Severity::Error); return tryResult799 .propagateErr(); } const auto& dbFileUrl = tryResult799.inspect ();; |
846 | |
847 | QM_TRY_INSPECT(const auto& storageService,auto tryResult800 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult800.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult800.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 850, mozilla::dom::quota::Severity::Error); return tryResult800 .propagateErr(); } const auto& storageService = tryResult800 .inspect(); |
848 | MOZ_TO_RESULT_GET_TYPED(nsCOMPtr<mozIStorageService>,auto tryResult800 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult800.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult800.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 850, mozilla::dom::quota::Severity::Error); return tryResult800 .propagateErr(); } const auto& storageService = tryResult800 .inspect(); |
849 | MOZ_SELECT_OVERLOAD(do_GetService),auto tryResult800 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult800.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult800.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 850, mozilla::dom::quota::Severity::Error); return tryResult800 .propagateErr(); } const auto& storageService = tryResult800 .inspect(); |
850 | MOZ_STORAGE_SERVICE_CONTRACTID))auto tryResult800 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult800.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult800.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 850, mozilla::dom::quota::Severity::Error); return tryResult800 .propagateErr(); } const auto& storageService = tryResult800 .inspect();; |
851 | |
852 | QM_TRY_UNWRAP(auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
853 | auto connection,auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
854 | QM_OR_ELSE_WARN_IF(auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
855 | // Expression.auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
856 | OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId)auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
857 | .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> {auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
858 | return std::move(connection).unwrapBasePtr();auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
859 | }),auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
860 | // Predicate.auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
861 | ([&aName](nsresult aValue) {auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
862 | // If we're just opening the database during origin initialization,auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
863 | // then we don't want to erase any files. The failure here will failauto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
864 | // origin initialization too.auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
865 | return IsDatabaseCorruptionError(aValue) && !aName.IsVoid();auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
866 | }),auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
867 | // Fallback.auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap(); |
868 | ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>))auto tryResult801 = (mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy (*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection ) -> nsCOMPtr<mozIStorageConnection> { return std::move (connection).unwrapBasePtr(); })), [&](const auto& firstRes ) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError (aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom ::quota::HandleError("\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <nsCOMPtr<mozIStorageConnection>>)); if ((__builtin_expect (!!(tryResult801.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })), [&](const auto& firstRes) { bool res = ([&aName](nsresult aValue) { return IsDatabaseCorruptionError(aValue) && !aName.IsVoid(); })(firstRes); mozilla::dom::quota::HandleError(\"\\\"OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId) .map([](auto connection) -> nsCOMPtr<mozIStorageConnection> { return std::move(connection).unwrapBasePtr(); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 868, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<nsCOMPtr<mozIStorageConnection>>)" , tryResult801.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 868, mozilla::dom::quota::Severity::Error); return tryResult801 .propagateErr(); } auto connection = tryResult801.unwrap();; |
869 | |
870 | if (!connection) { |
871 | // XXX Shouldn't we also update quota usage? |
872 | |
873 | // Nuke the database file. |
874 | QM_TRY(MOZ_TO_RESULT(aDBFile.Remove(false))){auto tryResult802 = (ToResult(aDBFile.Remove(false))); static_assert (std::is_empty_v<typename decltype(tryResult802)::ok_type> ); if ((__builtin_expect(!!(tryResult802.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(aDBFile.Remove(false))", tryResult802 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 874, mozilla::dom::quota::Severity::Error); return tryResult802 .propagateErr(); }}; |
875 | QM_TRY_INSPECT(const bool& existsAsDirectory,auto tryResult803 = (ExistsAsDirectory(aFMDirectory)); if ((__builtin_expect (!!(tryResult803.isErr()), 0))) { mozilla::dom::quota::HandleError ("ExistsAsDirectory(aFMDirectory)", tryResult803.inspectErr() , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 876, mozilla::dom::quota::Severity::Error); return tryResult803 .propagateErr(); } const bool& existsAsDirectory = tryResult803 .inspect(); |
876 | ExistsAsDirectory(aFMDirectory))auto tryResult803 = (ExistsAsDirectory(aFMDirectory)); if ((__builtin_expect (!!(tryResult803.isErr()), 0))) { mozilla::dom::quota::HandleError ("ExistsAsDirectory(aFMDirectory)", tryResult803.inspectErr() , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 876, mozilla::dom::quota::Severity::Error); return tryResult803 .propagateErr(); } const bool& existsAsDirectory = tryResult803 .inspect();; |
877 | |
878 | if (existsAsDirectory) { |
879 | QM_TRY(MOZ_TO_RESULT(aFMDirectory.Remove(true))){auto tryResult804 = (ToResult(aFMDirectory.Remove(true))); static_assert (std::is_empty_v<typename decltype(tryResult804)::ok_type> ); if ((__builtin_expect(!!(tryResult804.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(aFMDirectory.Remove(true))" , tryResult804.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 879, mozilla::dom::quota::Severity::Error); return tryResult804 .propagateErr(); }}; |
880 | } |
881 | |
882 | QM_TRY_UNWRAP(connection, OpenDatabaseAndHandleBusy(auto tryResult805 = (OpenDatabaseAndHandleBusy( *storageService , *dbFileUrl, aTelemetryId)); if ((__builtin_expect(!!(tryResult805 .isErr()), 0))) { mozilla::dom::quota::HandleError("OpenDatabaseAndHandleBusy( *storageService, *dbFileUrl, aTelemetryId)" , tryResult805.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 883, mozilla::dom::quota::Severity::Error); return tryResult805 .propagateErr(); } connection = tryResult805.unwrap(); |
883 | *storageService, *dbFileUrl, aTelemetryId))auto tryResult805 = (OpenDatabaseAndHandleBusy( *storageService , *dbFileUrl, aTelemetryId)); if ((__builtin_expect(!!(tryResult805 .isErr()), 0))) { mozilla::dom::quota::HandleError("OpenDatabaseAndHandleBusy( *storageService, *dbFileUrl, aTelemetryId)" , tryResult805.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 883, mozilla::dom::quota::Severity::Error); return tryResult805 .propagateErr(); } connection = tryResult805.unwrap();; |
884 | } |
885 | |
886 | QM_TRY(MOZ_TO_RESULT(SetDefaultPragmas(*connection))){auto tryResult806 = (ToResult(SetDefaultPragmas(*connection) )); static_assert(std::is_empty_v<typename decltype(tryResult806 )::ok_type>); if ((__builtin_expect(!!(tryResult806.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(SetDefaultPragmas(*connection))" , tryResult806.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 886, mozilla::dom::quota::Severity::Error); return tryResult806 .propagateErr(); }}; |
887 | QM_TRY(MOZ_TO_RESULT(connection->EnableModule("filesystem"_ns))){auto tryResult807 = (ToResult(connection->EnableModule("filesystem"_ns ))); static_assert(std::is_empty_v<typename decltype(tryResult807 )::ok_type>); if ((__builtin_expect(!!(tryResult807.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->EnableModule(\"filesystem\"_ns))" , tryResult807.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 887, mozilla::dom::quota::Severity::Error); return tryResult807 .propagateErr(); }}; |
888 | |
889 | // Check to make sure that the database schema is correct. |
890 | QM_TRY_INSPECT(const int32_t& schemaVersion,auto tryResult808 = (::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::GetSchemaVersion)); if ((__builtin_expect(!!(tryResult808 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryResult808.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 891, mozilla::dom::quota::Severity::Error); return tryResult808 .propagateErr(); } const int32_t& schemaVersion = tryResult808 .inspect(); |
891 | MOZ_TO_RESULT_INVOKE_MEMBER(connection, GetSchemaVersion))auto tryResult808 = (::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::GetSchemaVersion)); if ((__builtin_expect(!!(tryResult808 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryResult808.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 891, mozilla::dom::quota::Severity::Error); return tryResult808 .propagateErr(); } const int32_t& schemaVersion = tryResult808 .inspect();; |
892 | |
893 | // Unknown schema will fail origin initialization too. |
894 | QM_TRY(OkIf(schemaVersion || !aName.IsVoid()),{auto tryResult809 = (OkIf(schemaVersion || !aName.IsVoid())) ; static_assert(std::is_empty_v<typename decltype(tryResult809 )::ok_type>); if ((__builtin_expect(!!(tryResult809.isErr( )), 0))) { auto tryTempError = tryResult809.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 897, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is not set!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
895 | Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR), [](const auto&) {{auto tryResult809 = (OkIf(schemaVersion || !aName.IsVoid())) ; static_assert(std::is_empty_v<typename decltype(tryResult809 )::ok_type>); if ((__builtin_expect(!!(tryResult809.isErr( )), 0))) { auto tryTempError = tryResult809.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 897, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is not set!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
896 | IDB_WARNING("Unable to open IndexedDB database, schema is not set!");{auto tryResult809 = (OkIf(schemaVersion || !aName.IsVoid())) ; static_assert(std::is_empty_v<typename decltype(tryResult809 )::ok_type>); if ((__builtin_expect(!!(tryResult809.isErr( )), 0))) { auto tryTempError = tryResult809.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 897, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is not set!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
897 | }){auto tryResult809 = (OkIf(schemaVersion || !aName.IsVoid())) ; static_assert(std::is_empty_v<typename decltype(tryResult809 )::ok_type>); if ((__builtin_expect(!!(tryResult809.isErr( )), 0))) { auto tryTempError = tryResult809.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 897, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is not set!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 896); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion || !aName.IsVoid())" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; |
898 | |
899 | QM_TRY({auto tryResult810 = (OkIf(schemaVersion <= kSQLiteSchemaVersion )); static_assert(std::is_empty_v<typename decltype(tryResult810 )::ok_type>); if ((__builtin_expect(!!(tryResult810.isErr( )), 0))) { auto tryTempError = tryResult810.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 903, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is too high!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
900 | OkIf(schemaVersion <= kSQLiteSchemaVersion),{auto tryResult810 = (OkIf(schemaVersion <= kSQLiteSchemaVersion )); static_assert(std::is_empty_v<typename decltype(tryResult810 )::ok_type>); if ((__builtin_expect(!!(tryResult810.isErr( )), 0))) { auto tryTempError = tryResult810.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 903, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is too high!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
901 | Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR), [](const auto&) {{auto tryResult810 = (OkIf(schemaVersion <= kSQLiteSchemaVersion )); static_assert(std::is_empty_v<typename decltype(tryResult810 )::ok_type>); if ((__builtin_expect(!!(tryResult810.isErr( )), 0))) { auto tryTempError = tryResult810.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 903, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is too high!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
902 | IDB_WARNING("Unable to open IndexedDB database, schema is too high!");{auto tryResult810 = (OkIf(schemaVersion <= kSQLiteSchemaVersion )); static_assert(std::is_empty_v<typename decltype(tryResult810 )::ok_type>); if ((__builtin_expect(!!(tryResult810.isErr( )), 0))) { auto tryTempError = tryResult810.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 903, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is too high!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
903 | }){auto tryResult810 = (OkIf(schemaVersion <= kSQLiteSchemaVersion )); static_assert(std::is_empty_v<typename decltype(tryResult810 )::ok_type>); if ((__builtin_expect(!!(tryResult810.isErr( )), 0))) { auto tryTempError = tryResult810.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 903, mozilla::dom::quota::Severity::Error); [](const auto& ) { do { nsPrintfCString s("Unable to open IndexedDB database, schema is too high!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 902); } while (0); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(schemaVersion <= kSQLiteSchemaVersion)" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; |
904 | |
905 | bool journalModeSet = false; |
906 | |
907 | if (schemaVersion != kSQLiteSchemaVersion) { |
908 | const bool newDatabase = !schemaVersion; |
909 | |
910 | if (newDatabase) { |
911 | // Set the page size first. |
912 | const auto sqlitePageSizeOverride = |
913 | aMaybeKey ? 8192 : kSQLitePageSizeOverride; |
914 | if (sqlitePageSizeOverride) { |
915 | QM_TRY(MOZ_TO_RESULT(connection->ExecuteSimpleSQL(nsPrintfCString({auto tryResult811 = (ToResult(connection->ExecuteSimpleSQL (nsPrintfCString( "PRAGMA page_size = %" "u" ";", sqlitePageSizeOverride )))); static_assert(std::is_empty_v<typename decltype(tryResult811 )::ok_type>); if ((__builtin_expect(!!(tryResult811.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL(nsPrintfCString( \"PRAGMA page_size = %\" \"u\" \";\", sqlitePageSizeOverride)))" , tryResult811.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 916, mozilla::dom::quota::Severity::Error); return tryResult811 .propagateErr(); }} |
916 | "PRAGMA page_size = %" PRIu32 ";", sqlitePageSizeOverride)))){auto tryResult811 = (ToResult(connection->ExecuteSimpleSQL (nsPrintfCString( "PRAGMA page_size = %" "u" ";", sqlitePageSizeOverride )))); static_assert(std::is_empty_v<typename decltype(tryResult811 )::ok_type>); if ((__builtin_expect(!!(tryResult811.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL(nsPrintfCString( \"PRAGMA page_size = %\" \"u\" \";\", sqlitePageSizeOverride)))" , tryResult811.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 916, mozilla::dom::quota::Severity::Error); return tryResult811 .propagateErr(); }}; |
917 | } |
918 | |
919 | // We have to set the auto_vacuum mode before opening a transaction. |
920 | QM_TRY((MOZ_TO_RESULT_INVOKE_MEMBER({auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
921 | connection, ExecuteSimpleSQL,{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
922 | #ifdef IDB_MOBILE{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
923 | // Turn on full auto_vacuum mode to reclaim disk space on{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
924 | // mobile devices (at the cost of some COMMIT speed).{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
925 | "PRAGMA auto_vacuum = FULL;"_ns{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
926 | #else{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
927 | // Turn on incremental auto_vacuum mode on desktop builds.{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
928 | "PRAGMA auto_vacuum = INCREMENTAL;"_ns{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
929 | #endif{auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
930 | ){auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }} |
931 | .mapErr(mapNoDeviceSpaceError))){auto tryResult812 = ((::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::ExecuteSimpleSQL,ifdef IDB_MOBILE "PRAGMA auto_vacuum = FULL;"_ns else "PRAGMA auto_vacuum = INCREMENTAL;"_ns endif) .mapErr(mapNoDeviceSpaceError ))); static_assert(std::is_empty_v<typename decltype(tryResult812 )::ok_type>); if ((__builtin_expect(!!(tryResult812.isErr( )), 0))) { mozilla::dom::quota::HandleError("(::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::ExecuteSimpleSQL,ifdef IDB_MOBILE \"PRAGMA auto_vacuum = FULL;\"_nselse \"PRAGMA auto_vacuum = INCREMENTAL;\"_nsendif) .mapErr(mapNoDeviceSpaceError))" , tryResult812.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 931, mozilla::dom::quota::Severity::Error); return tryResult812 .propagateErr(); }}; |
932 | |
933 | QM_TRY(MOZ_TO_RESULT(SetJournalMode(*connection))){auto tryResult813 = (ToResult(SetJournalMode(*connection))); static_assert(std::is_empty_v<typename decltype(tryResult813 )::ok_type>); if ((__builtin_expect(!!(tryResult813.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(SetJournalMode(*connection))" , tryResult813.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 933, mozilla::dom::quota::Severity::Error); return tryResult813 .propagateErr(); }}; |
934 | |
935 | journalModeSet = true; |
936 | } else { |
937 | #ifdef DEBUG1 |
938 | // Disable foreign key support while upgrading. This has to be done before |
939 | // starting a transaction. |
940 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (connection->ExecuteSimpleSQL("PRAGMA foreign_keys = OFF;"_ns ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 941); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" ")"); do { *((volatile int*)__null) = 941; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
941 | connection->ExecuteSimpleSQL("PRAGMA foreign_keys = OFF;"_ns))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (connection->ExecuteSimpleSQL("PRAGMA foreign_keys = OFF;"_ns ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 941); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" ")"); do { *((volatile int*)__null) = 941; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
942 | #endif |
943 | } |
944 | |
945 | bool vacuumNeeded = false; |
946 | |
947 | mozStorageTransaction transaction( |
948 | connection.get(), false, mozIStorageConnection::TRANSACTION_IMMEDIATE); |
949 | |
950 | QM_TRY(MOZ_TO_RESULT(transaction.Start())){auto tryResult814 = (ToResult(transaction.Start())); static_assert (std::is_empty_v<typename decltype(tryResult814)::ok_type> ); if ((__builtin_expect(!!(tryResult814.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(transaction.Start())", tryResult814 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 950, mozilla::dom::quota::Severity::Error); return tryResult814 .propagateErr(); }}; |
951 | |
952 | if (newDatabase) { |
953 | QM_TRY(MOZ_TO_RESULT(CreateTables(*connection))){auto tryResult815 = (ToResult(CreateTables(*connection))); static_assert (std::is_empty_v<typename decltype(tryResult815)::ok_type> ); if ((__builtin_expect(!!(tryResult815.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(CreateTables(*connection))" , tryResult815.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 953, mozilla::dom::quota::Severity::Error); return tryResult815 .propagateErr(); }}; |
954 | |
955 | #ifdef DEBUG1 |
956 | { |
957 | QM_TRY_INSPECT(auto tryResult816 = (::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::GetSchemaVersion)); if ((__builtin_expect(!!(tryResult816 .isErr()), 0))) { auto tryTempError __attribute__((__unused__ )) = tryResult816.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 960; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & schemaVersion = tryResult816.inspect(); |
958 | const int32_t& schemaVersion,auto tryResult816 = (::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::GetSchemaVersion)); if ((__builtin_expect(!!(tryResult816 .isErr()), 0))) { auto tryTempError __attribute__((__unused__ )) = tryResult816.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 960; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & schemaVersion = tryResult816.inspect(); |
959 | MOZ_TO_RESULT_INVOKE_MEMBER(connection, GetSchemaVersion),auto tryResult816 = (::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::GetSchemaVersion)); if ((__builtin_expect(!!(tryResult816 .isErr()), 0))) { auto tryTempError __attribute__((__unused__ )) = tryResult816.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 960; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & schemaVersion = tryResult816.inspect(); |
960 | QM_ASSERT_UNREACHABLE)auto tryResult816 = (::mozilla::ToResultInvokeMember( (connection ), &::mozilla::detail::DerefedType<decltype(connection )>::GetSchemaVersion)); if ((__builtin_expect(!!(tryResult816 .isErr()), 0))) { auto tryTempError __attribute__((__unused__ )) = tryResult816.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (connection), &::mozilla::detail::DerefedType<decltype(connection)>::GetSchemaVersion)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 960); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 960; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & schemaVersion = tryResult816.inspect();; |
961 | MOZ_ASSERT(schemaVersion == kSQLiteSchemaVersion)do { static_assert( mozilla::detail::AssertionConditionType< decltype(schemaVersion == kSQLiteSchemaVersion)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(! !(schemaVersion == kSQLiteSchemaVersion))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("schemaVersion == kSQLiteSchemaVersion" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 961); AnnotateMozCrashReason("MOZ_ASSERT" "(" "schemaVersion == kSQLiteSchemaVersion" ")"); do { *((volatile int*)__null) = 961; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
962 | } |
963 | #endif |
964 | |
965 | // The parameter names are not used, parameters are bound by index only |
966 | // locally in the same function. |
967 | QM_TRY_INSPECT(auto tryResult817 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "INSERT INTO database (name, origin) " "VALUES (:name, :origin)"_ns )); if ((__builtin_expect(!!(tryResult817.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"INSERT INTO database (name, origin) \" \"VALUES (:name, :origin)\"_ns)" , tryResult817.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 972, mozilla::dom::quota::Severity::Error); return tryResult817 .propagateErr(); } const auto& stmt = tryResult817.inspect (); |
968 | const auto& stmt,auto tryResult817 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "INSERT INTO database (name, origin) " "VALUES (:name, :origin)"_ns )); if ((__builtin_expect(!!(tryResult817.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"INSERT INTO database (name, origin) \" \"VALUES (:name, :origin)\"_ns)" , tryResult817.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 972, mozilla::dom::quota::Severity::Error); return tryResult817 .propagateErr(); } const auto& stmt = tryResult817.inspect (); |
969 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult817 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "INSERT INTO database (name, origin) " "VALUES (:name, :origin)"_ns )); if ((__builtin_expect(!!(tryResult817.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"INSERT INTO database (name, origin) \" \"VALUES (:name, :origin)\"_ns)" , tryResult817.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 972, mozilla::dom::quota::Severity::Error); return tryResult817 .propagateErr(); } const auto& stmt = tryResult817.inspect (); |
970 | nsCOMPtr<mozIStorageStatement>, connection, CreateStatement,auto tryResult817 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "INSERT INTO database (name, origin) " "VALUES (:name, :origin)"_ns )); if ((__builtin_expect(!!(tryResult817.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"INSERT INTO database (name, origin) \" \"VALUES (:name, :origin)\"_ns)" , tryResult817.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 972, mozilla::dom::quota::Severity::Error); return tryResult817 .propagateErr(); } const auto& stmt = tryResult817.inspect (); |
971 | "INSERT INTO database (name, origin) "auto tryResult817 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "INSERT INTO database (name, origin) " "VALUES (:name, :origin)"_ns )); if ((__builtin_expect(!!(tryResult817.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"INSERT INTO database (name, origin) \" \"VALUES (:name, :origin)\"_ns)" , tryResult817.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 972, mozilla::dom::quota::Severity::Error); return tryResult817 .propagateErr(); } const auto& stmt = tryResult817.inspect (); |
972 | "VALUES (:name, :origin)"_ns))auto tryResult817 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "INSERT INTO database (name, origin) " "VALUES (:name, :origin)"_ns )); if ((__builtin_expect(!!(tryResult817.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"INSERT INTO database (name, origin) \" \"VALUES (:name, :origin)\"_ns)" , tryResult817.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 972, mozilla::dom::quota::Severity::Error); return tryResult817 .propagateErr(); } const auto& stmt = tryResult817.inspect ();; |
973 | |
974 | QM_TRY(MOZ_TO_RESULT(stmt->BindStringByIndex(0, aName))){auto tryResult818 = (ToResult(stmt->BindStringByIndex(0, aName ))); static_assert(std::is_empty_v<typename decltype(tryResult818 )::ok_type>); if ((__builtin_expect(!!(tryResult818.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt->BindStringByIndex(0, aName))" , tryResult818.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 974, mozilla::dom::quota::Severity::Error); return tryResult818 .propagateErr(); }}; |
975 | QM_TRY(MOZ_TO_RESULT(stmt->BindUTF8StringByIndex(1, aOrigin))){auto tryResult819 = (ToResult(stmt->BindUTF8StringByIndex (1, aOrigin))); static_assert(std::is_empty_v<typename decltype (tryResult819)::ok_type>); if ((__builtin_expect(!!(tryResult819 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt->BindUTF8StringByIndex(1, aOrigin))" , tryResult819.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 975, mozilla::dom::quota::Severity::Error); return tryResult819 .propagateErr(); }}; |
976 | QM_TRY(MOZ_TO_RESULT(stmt->Execute())){auto tryResult820 = (ToResult(stmt->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult820)::ok_type> ); if ((__builtin_expect(!!(tryResult820.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt->Execute())", tryResult820 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 976, mozilla::dom::quota::Severity::Error); return tryResult820 .propagateErr(); }}; |
977 | } else { |
978 | QM_TRY_UNWRAP(vacuumNeeded, MaybeUpgradeSchema(*connection, schemaVersion,auto tryResult821 = (MaybeUpgradeSchema(*connection, schemaVersion , aFMDirectory, aOrigin)); if ((__builtin_expect(!!(tryResult821 .isErr()), 0))) { mozilla::dom::quota::HandleError("MaybeUpgradeSchema(*connection, schemaVersion, aFMDirectory, aOrigin)" , tryResult821.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 979, mozilla::dom::quota::Severity::Error); return tryResult821 .propagateErr(); } vacuumNeeded = tryResult821.unwrap(); |
979 | aFMDirectory, aOrigin))auto tryResult821 = (MaybeUpgradeSchema(*connection, schemaVersion , aFMDirectory, aOrigin)); if ((__builtin_expect(!!(tryResult821 .isErr()), 0))) { mozilla::dom::quota::HandleError("MaybeUpgradeSchema(*connection, schemaVersion, aFMDirectory, aOrigin)" , tryResult821.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 979, mozilla::dom::quota::Severity::Error); return tryResult821 .propagateErr(); } vacuumNeeded = tryResult821.unwrap();; |
980 | } |
981 | |
982 | QM_TRY(MOZ_TO_RESULT_INVOKE_MEMBER(transaction, Commit){auto tryResult822 = (::mozilla::ToResultInvokeMember( (transaction ), &::mozilla::detail::DerefedType<decltype(transaction )>::Commit) .mapErr(mapNoDeviceSpaceError)); static_assert (std::is_empty_v<typename decltype(tryResult822)::ok_type> ); if ((__builtin_expect(!!(tryResult822.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (transaction), &::mozilla::detail::DerefedType<decltype(transaction)>::Commit) .mapErr(mapNoDeviceSpaceError)" , tryResult822.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 983, mozilla::dom::quota::Severity::Error); return tryResult822 .propagateErr(); }} |
983 | .mapErr(mapNoDeviceSpaceError)){auto tryResult822 = (::mozilla::ToResultInvokeMember( (transaction ), &::mozilla::detail::DerefedType<decltype(transaction )>::Commit) .mapErr(mapNoDeviceSpaceError)); static_assert (std::is_empty_v<typename decltype(tryResult822)::ok_type> ); if ((__builtin_expect(!!(tryResult822.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (transaction), &::mozilla::detail::DerefedType<decltype(transaction)>::Commit) .mapErr(mapNoDeviceSpaceError)" , tryResult822.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 983, mozilla::dom::quota::Severity::Error); return tryResult822 .propagateErr(); }}; |
984 | |
985 | #ifdef DEBUG1 |
986 | if (!newDatabase) { |
987 | // Re-enable foreign key support after doing a foreign key check. |
988 | QM_TRY_INSPECT(const bool& foreignKeyError,auto tryResult823 = (CreateAndExecuteSingleStepStatement< SingleStepResult ::ReturnNullIfNoResult>( *connection, "PRAGMA foreign_key_check;"_ns )); if ((__builtin_expect(!!(tryResult823.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult823.unwrapErr (); mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 992; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const bool & foreignKeyError = tryResult823.inspect(); |
989 | CreateAndExecuteSingleStepStatement<auto tryResult823 = (CreateAndExecuteSingleStepStatement< SingleStepResult ::ReturnNullIfNoResult>( *connection, "PRAGMA foreign_key_check;"_ns )); if ((__builtin_expect(!!(tryResult823.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult823.unwrapErr (); mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 992; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const bool & foreignKeyError = tryResult823.inspect(); |
990 | SingleStepResult::ReturnNullIfNoResult>(auto tryResult823 = (CreateAndExecuteSingleStepStatement< SingleStepResult ::ReturnNullIfNoResult>( *connection, "PRAGMA foreign_key_check;"_ns )); if ((__builtin_expect(!!(tryResult823.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult823.unwrapErr (); mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 992; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const bool & foreignKeyError = tryResult823.inspect(); |
991 | *connection, "PRAGMA foreign_key_check;"_ns),auto tryResult823 = (CreateAndExecuteSingleStepStatement< SingleStepResult ::ReturnNullIfNoResult>( *connection, "PRAGMA foreign_key_check;"_ns )); if ((__builtin_expect(!!(tryResult823.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult823.unwrapErr (); mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 992; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const bool & foreignKeyError = tryResult823.inspect(); |
992 | QM_ASSERT_UNREACHABLE)auto tryResult823 = (CreateAndExecuteSingleStepStatement< SingleStepResult ::ReturnNullIfNoResult>( *connection, "PRAGMA foreign_key_check;"_ns )); if ((__builtin_expect(!!(tryResult823.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult823.unwrapErr (); mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "CreateAndExecuteSingleStepStatement< SingleStepResult::ReturnNullIfNoResult>( *connection, \"PRAGMA foreign_key_check;\"_ns)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 992); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 992; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const bool & foreignKeyError = tryResult823.inspect();; |
993 | |
994 | MOZ_ASSERT(!foreignKeyError, "Database has inconsisistent foreign keys!")do { static_assert( mozilla::detail::AssertionConditionType< decltype(!foreignKeyError)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!foreignKeyError))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!foreignKeyError" " (" "Database has inconsisistent foreign keys!" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 994); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!foreignKeyError" ") (" "Database has inconsisistent foreign keys!" ")"); do { *((volatile int*)__null) = 994; __attribute__((nomerge)) ::abort (); } while (false); } } while (false); |
995 | |
996 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (connection->ExecuteSimpleSQL("PRAGMA foreign_keys = OFF;"_ns ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 997); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" ")"); do { *((volatile int*)__null) = 997; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
997 | connection->ExecuteSimpleSQL("PRAGMA foreign_keys = OFF;"_ns))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (connection->ExecuteSimpleSQL("PRAGMA foreign_keys = OFF;"_ns ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 997); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(connection->ExecuteSimpleSQL(\"PRAGMA foreign_keys = OFF;\"_ns))" ")"); do { *((volatile int*)__null) = 997; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
998 | } |
999 | #endif |
1000 | |
1001 | if (kSQLitePageSizeOverride && !newDatabase) { |
1002 | QM_TRY_INSPECT(const auto& stmt,auto tryResult824 = (CreateAndExecuteSingleStepStatement( *connection , "PRAGMA page_size;"_ns)); if ((__builtin_expect(!!(tryResult824 .isErr()), 0))) { mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement( *connection, \"PRAGMA page_size;\"_ns)" , tryResult824.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1004, mozilla::dom::quota::Severity::Error); return tryResult824 .propagateErr(); } const auto& stmt = tryResult824.inspect (); |
1003 | CreateAndExecuteSingleStepStatement(auto tryResult824 = (CreateAndExecuteSingleStepStatement( *connection , "PRAGMA page_size;"_ns)); if ((__builtin_expect(!!(tryResult824 .isErr()), 0))) { mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement( *connection, \"PRAGMA page_size;\"_ns)" , tryResult824.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1004, mozilla::dom::quota::Severity::Error); return tryResult824 .propagateErr(); } const auto& stmt = tryResult824.inspect (); |
1004 | *connection, "PRAGMA page_size;"_ns))auto tryResult824 = (CreateAndExecuteSingleStepStatement( *connection , "PRAGMA page_size;"_ns)); if ((__builtin_expect(!!(tryResult824 .isErr()), 0))) { mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement( *connection, \"PRAGMA page_size;\"_ns)" , tryResult824.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1004, mozilla::dom::quota::Severity::Error); return tryResult824 .propagateErr(); } const auto& stmt = tryResult824.inspect ();; |
1005 | |
1006 | QM_TRY_INSPECT(const int32_t& pageSize,auto tryResult825 = (::mozilla::ToResultInvokeMember( (*stmt) , &::mozilla::detail::DerefedType<decltype(*stmt)>:: GetInt32, 0)); if ((__builtin_expect(!!(tryResult825.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (*stmt), &::mozilla::detail::DerefedType<decltype(*stmt)>::GetInt32, 0)" , tryResult825.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1007, mozilla::dom::quota::Severity::Error); return tryResult825 .propagateErr(); } const int32_t& pageSize = tryResult825 .inspect(); |
1007 | MOZ_TO_RESULT_INVOKE_MEMBER(*stmt, GetInt32, 0))auto tryResult825 = (::mozilla::ToResultInvokeMember( (*stmt) , &::mozilla::detail::DerefedType<decltype(*stmt)>:: GetInt32, 0)); if ((__builtin_expect(!!(tryResult825.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (*stmt), &::mozilla::detail::DerefedType<decltype(*stmt)>::GetInt32, 0)" , tryResult825.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1007, mozilla::dom::quota::Severity::Error); return tryResult825 .propagateErr(); } const int32_t& pageSize = tryResult825 .inspect();; |
1008 | MOZ_ASSERT(pageSize >= 512 && pageSize <= 65536)do { static_assert( mozilla::detail::AssertionConditionType< decltype(pageSize >= 512 && pageSize <= 65536)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(pageSize >= 512 && pageSize <= 65536)) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("pageSize >= 512 && pageSize <= 65536" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1008); AnnotateMozCrashReason("MOZ_ASSERT" "(" "pageSize >= 512 && pageSize <= 65536" ")"); do { *((volatile int*)__null) = 1008; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1009 | |
1010 | if (kSQLitePageSizeOverride != uint32_t(pageSize)) { |
1011 | // We must not be in WAL journal mode to change the page size. |
1012 | QM_TRY(MOZ_TO_RESULT({auto tryResult826 = (ToResult(connection->ExecuteSimpleSQL ("PRAGMA journal_mode = DELETE;"_ns))); static_assert(std::is_empty_v <typename decltype(tryResult826)::ok_type>); if ((__builtin_expect (!!(tryResult826.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(connection->ExecuteSimpleSQL(\"PRAGMA journal_mode = DELETE;\"_ns))" , tryResult826.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1013, mozilla::dom::quota::Severity::Error); return tryResult826 .propagateErr(); }} |
1013 | connection->ExecuteSimpleSQL("PRAGMA journal_mode = DELETE;"_ns))){auto tryResult826 = (ToResult(connection->ExecuteSimpleSQL ("PRAGMA journal_mode = DELETE;"_ns))); static_assert(std::is_empty_v <typename decltype(tryResult826)::ok_type>); if ((__builtin_expect (!!(tryResult826.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(connection->ExecuteSimpleSQL(\"PRAGMA journal_mode = DELETE;\"_ns))" , tryResult826.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1013, mozilla::dom::quota::Severity::Error); return tryResult826 .propagateErr(); }}; |
1014 | |
1015 | QM_TRY_INSPECT(const auto& stmt,auto tryResult827 = (CreateAndExecuteSingleStepStatement( *connection , "PRAGMA journal_mode;"_ns)); if ((__builtin_expect(!!(tryResult827 .isErr()), 0))) { mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement( *connection, \"PRAGMA journal_mode;\"_ns)" , tryResult827.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1017, mozilla::dom::quota::Severity::Error); return tryResult827 .propagateErr(); } const auto& stmt = tryResult827.inspect (); |
1016 | CreateAndExecuteSingleStepStatement(auto tryResult827 = (CreateAndExecuteSingleStepStatement( *connection , "PRAGMA journal_mode;"_ns)); if ((__builtin_expect(!!(tryResult827 .isErr()), 0))) { mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement( *connection, \"PRAGMA journal_mode;\"_ns)" , tryResult827.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1017, mozilla::dom::quota::Severity::Error); return tryResult827 .propagateErr(); } const auto& stmt = tryResult827.inspect (); |
1017 | *connection, "PRAGMA journal_mode;"_ns))auto tryResult827 = (CreateAndExecuteSingleStepStatement( *connection , "PRAGMA journal_mode;"_ns)); if ((__builtin_expect(!!(tryResult827 .isErr()), 0))) { mozilla::dom::quota::HandleError("CreateAndExecuteSingleStepStatement( *connection, \"PRAGMA journal_mode;\"_ns)" , tryResult827.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1017, mozilla::dom::quota::Severity::Error); return tryResult827 .propagateErr(); } const auto& stmt = tryResult827.inspect ();; |
1018 | |
1019 | QM_TRY_INSPECT(const auto& journalMode,auto tryResult828 = (::mozilla::ToResultInvoke< nsCString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (*stmt)>::GetUTF8String), (*stmt), 0)); if ((__builtin_expect (!!(tryResult828.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*stmt)>::GetUTF8String), (*stmt), 0)" , tryResult828.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1021, mozilla::dom::quota::Severity::Error); return tryResult828 .propagateErr(); } const auto& journalMode = tryResult828 .inspect(); |
1020 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(nsCString, *stmt,auto tryResult828 = (::mozilla::ToResultInvoke< nsCString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (*stmt)>::GetUTF8String), (*stmt), 0)); if ((__builtin_expect (!!(tryResult828.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*stmt)>::GetUTF8String), (*stmt), 0)" , tryResult828.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1021, mozilla::dom::quota::Severity::Error); return tryResult828 .propagateErr(); } const auto& journalMode = tryResult828 .inspect(); |
1021 | GetUTF8String, 0))auto tryResult828 = (::mozilla::ToResultInvoke< nsCString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (*stmt)>::GetUTF8String), (*stmt), 0)); if ((__builtin_expect (!!(tryResult828.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*stmt)>::GetUTF8String), (*stmt), 0)" , tryResult828.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1021, mozilla::dom::quota::Severity::Error); return tryResult828 .propagateErr(); } const auto& journalMode = tryResult828 .inspect();; |
1022 | |
1023 | if (journalMode.EqualsLiteral("delete")) { |
1024 | // Successfully set to rollback journal mode so changing the page size |
1025 | // is possible with a VACUUM. |
1026 | QM_TRY(MOZ_TO_RESULT(connection->ExecuteSimpleSQL(nsPrintfCString({auto tryResult829 = (ToResult(connection->ExecuteSimpleSQL (nsPrintfCString( "PRAGMA page_size = %" "u" ";", kSQLitePageSizeOverride )))); static_assert(std::is_empty_v<typename decltype(tryResult829 )::ok_type>); if ((__builtin_expect(!!(tryResult829.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL(nsPrintfCString( \"PRAGMA page_size = %\" \"u\" \";\", kSQLitePageSizeOverride)))" , tryResult829.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1027, mozilla::dom::quota::Severity::Error); return tryResult829 .propagateErr(); }} |
1027 | "PRAGMA page_size = %" PRIu32 ";", kSQLitePageSizeOverride)))){auto tryResult829 = (ToResult(connection->ExecuteSimpleSQL (nsPrintfCString( "PRAGMA page_size = %" "u" ";", kSQLitePageSizeOverride )))); static_assert(std::is_empty_v<typename decltype(tryResult829 )::ok_type>); if ((__builtin_expect(!!(tryResult829.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL(nsPrintfCString( \"PRAGMA page_size = %\" \"u\" \";\", kSQLitePageSizeOverride)))" , tryResult829.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1027, mozilla::dom::quota::Severity::Error); return tryResult829 .propagateErr(); }}; |
1028 | |
1029 | // We will need to VACUUM in order to change the page size. |
1030 | vacuumNeeded = true; |
1031 | } else { |
1032 | NS_WARNING(NS_DebugBreak(NS_DEBUG_WARNING, "Failed to set journal_mode for database, unable to " "change the page size!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1034) |
1033 | "Failed to set journal_mode for database, unable to "NS_DebugBreak(NS_DEBUG_WARNING, "Failed to set journal_mode for database, unable to " "change the page size!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1034) |
1034 | "change the page size!")NS_DebugBreak(NS_DEBUG_WARNING, "Failed to set journal_mode for database, unable to " "change the page size!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1034); |
1035 | } |
1036 | } |
1037 | } |
1038 | |
1039 | if (vacuumNeeded) { |
1040 | QM_TRY(MOZ_TO_RESULT(connection->ExecuteSimpleSQL("VACUUM;"_ns))){auto tryResult830 = (ToResult(connection->ExecuteSimpleSQL ("VACUUM;"_ns))); static_assert(std::is_empty_v<typename decltype (tryResult830)::ok_type>); if ((__builtin_expect(!!(tryResult830 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL(\"VACUUM;\"_ns))" , tryResult830.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1040, mozilla::dom::quota::Severity::Error); return tryResult830 .propagateErr(); }}; |
1041 | } |
1042 | |
1043 | if (newDatabase || vacuumNeeded) { |
1044 | if (journalModeSet) { |
1045 | // Make sure we checkpoint to get an accurate file size. |
1046 | QM_TRY(MOZ_TO_RESULT({auto tryResult831 = (ToResult(connection->ExecuteSimpleSQL ("PRAGMA wal_checkpoint(FULL);"_ns))); static_assert(std::is_empty_v <typename decltype(tryResult831)::ok_type>); if ((__builtin_expect (!!(tryResult831.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(connection->ExecuteSimpleSQL(\"PRAGMA wal_checkpoint(FULL);\"_ns))" , tryResult831.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1047, mozilla::dom::quota::Severity::Error); return tryResult831 .propagateErr(); }} |
1047 | connection->ExecuteSimpleSQL("PRAGMA wal_checkpoint(FULL);"_ns))){auto tryResult831 = (ToResult(connection->ExecuteSimpleSQL ("PRAGMA wal_checkpoint(FULL);"_ns))); static_assert(std::is_empty_v <typename decltype(tryResult831)::ok_type>); if ((__builtin_expect (!!(tryResult831.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(connection->ExecuteSimpleSQL(\"PRAGMA wal_checkpoint(FULL);\"_ns))" , tryResult831.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1047, mozilla::dom::quota::Severity::Error); return tryResult831 .propagateErr(); }}; |
1048 | } |
1049 | |
1050 | QM_TRY_INSPECT(const int64_t& fileSize,auto tryResult832 = (::mozilla::ToResultInvokeMember( (aDBFile ), &::mozilla::detail::DerefedType<decltype(aDBFile)> ::GetFileSize)); if ((__builtin_expect(!!(tryResult832.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDBFile), &::mozilla::detail::DerefedType<decltype(aDBFile)>::GetFileSize)" , tryResult832.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1051, mozilla::dom::quota::Severity::Error); return tryResult832 .propagateErr(); } const int64_t& fileSize = tryResult832 .inspect(); |
1051 | MOZ_TO_RESULT_INVOKE_MEMBER(aDBFile, GetFileSize))auto tryResult832 = (::mozilla::ToResultInvokeMember( (aDBFile ), &::mozilla::detail::DerefedType<decltype(aDBFile)> ::GetFileSize)); if ((__builtin_expect(!!(tryResult832.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDBFile), &::mozilla::detail::DerefedType<decltype(aDBFile)>::GetFileSize)" , tryResult832.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1051, mozilla::dom::quota::Severity::Error); return tryResult832 .propagateErr(); } const int64_t& fileSize = tryResult832 .inspect();; |
1052 | MOZ_ASSERT(fileSize > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileSize > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileSize > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileSize > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1052); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileSize > 0" ")"); do { *((volatile int*)__null) = 1052; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1053 | |
1054 | PRTime vacuumTime = PR_Now(); |
1055 | MOZ_ASSERT(vacuumTime)do { static_assert( mozilla::detail::AssertionConditionType< decltype(vacuumTime)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(vacuumTime))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("vacuumTime", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1055); AnnotateMozCrashReason("MOZ_ASSERT" "(" "vacuumTime" ")"); do { *((volatile int*)__null) = 1055; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1056 | |
1057 | // The parameter names are not used, parameters are bound by index only |
1058 | // locally in the same function. |
1059 | QM_TRY_INSPECT(auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect(); |
1060 | const auto& vacuumTimeStmt,auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect(); |
1061 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(nsCOMPtr<mozIStorageStatement>,auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect(); |
1062 | connection, CreateStatement,auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect(); |
1063 | "UPDATE database "auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect(); |
1064 | "SET last_vacuum_time = :time"auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect(); |
1065 | ", last_vacuum_size = :size;"_ns))auto tryResult833 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(connection)>::CreateStatement ), (connection), "UPDATE database " "SET last_vacuum_time = :time" ", last_vacuum_size = :size;"_ns)); if ((__builtin_expect(!! (tryResult833.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(connection)>::CreateStatement), (connection), \"UPDATE database \" \"SET last_vacuum_time = :time\" \", last_vacuum_size = :size;\"_ns)" , tryResult833.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1065, mozilla::dom::quota::Severity::Error); return tryResult833 .propagateErr(); } const auto& vacuumTimeStmt = tryResult833 .inspect();; |
1066 | |
1067 | QM_TRY(MOZ_TO_RESULT(vacuumTimeStmt->BindInt64ByIndex(0, vacuumTime))){auto tryResult834 = (ToResult(vacuumTimeStmt->BindInt64ByIndex (0, vacuumTime))); static_assert(std::is_empty_v<typename decltype (tryResult834)::ok_type>); if ((__builtin_expect(!!(tryResult834 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(vacuumTimeStmt->BindInt64ByIndex(0, vacuumTime))" , tryResult834.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1067, mozilla::dom::quota::Severity::Error); return tryResult834 .propagateErr(); }}; |
1068 | QM_TRY(MOZ_TO_RESULT(vacuumTimeStmt->BindInt64ByIndex(1, fileSize))){auto tryResult835 = (ToResult(vacuumTimeStmt->BindInt64ByIndex (1, fileSize))); static_assert(std::is_empty_v<typename decltype (tryResult835)::ok_type>); if ((__builtin_expect(!!(tryResult835 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(vacuumTimeStmt->BindInt64ByIndex(1, fileSize))" , tryResult835.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1068, mozilla::dom::quota::Severity::Error); return tryResult835 .propagateErr(); }}; |
1069 | QM_TRY(MOZ_TO_RESULT(vacuumTimeStmt->Execute())){auto tryResult836 = (ToResult(vacuumTimeStmt->Execute())) ; static_assert(std::is_empty_v<typename decltype(tryResult836 )::ok_type>); if ((__builtin_expect(!!(tryResult836.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(vacuumTimeStmt->Execute())" , tryResult836.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1069, mozilla::dom::quota::Severity::Error); return tryResult836 .propagateErr(); }}; |
1070 | } |
1071 | } |
1072 | |
1073 | if (!journalModeSet) { |
1074 | QM_TRY(MOZ_TO_RESULT(SetJournalMode(*connection))){auto tryResult837 = (ToResult(SetJournalMode(*connection))); static_assert(std::is_empty_v<typename decltype(tryResult837 )::ok_type>); if ((__builtin_expect(!!(tryResult837.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(SetJournalMode(*connection))" , tryResult837.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1074, mozilla::dom::quota::Severity::Error); return tryResult837 .propagateErr(); }}; |
1075 | } |
1076 | |
1077 | return WrapMovingNotNullUnchecked(std::move(connection)); |
1078 | } |
1079 | |
1080 | nsCOMPtr<nsIFile> GetFileForPath(const nsAString& aPath) { |
1081 | MOZ_ASSERT(!aPath.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aPath.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aPath.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aPath.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1081); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aPath.IsEmpty()" ")"); do { *((volatile int*)__null) = 1081; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1082 | |
1083 | QM_TRY_RETURN(QM_NewLocalFile(aPath), nullptr){auto tryResult838 = (QM_NewLocalFile(aPath)); if ((__builtin_expect (!!(tryResult838.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult838.unwrapErr(); mozilla::dom::quota ::HandleError("QM_NewLocalFile(aPath)", tryResult838.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1083, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "QM_NewLocalFile(aPath)" , tryTempError, nullptr); } return tryResult838.unwrap();}; |
1084 | } |
1085 | |
1086 | Result<MovingNotNull<nsCOMPtr<mozIStorageConnection>>, nsresult> |
1087 | GetStorageConnection(nsIFile& aDatabaseFile, const int64_t aDirectoryLockId, |
1088 | const uint32_t aTelemetryId, |
1089 | const Maybe<CipherKey>& aMaybeKey) { |
1090 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1090); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 1090; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1091 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1091); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 1091; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1092 | MOZ_ASSERT(aDirectoryLockId >= 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectoryLockId >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectoryLockId >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectoryLockId >= 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1092); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectoryLockId >= 0" ")"); do { *((volatile int*)__null) = 1092; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1093 | |
1094 | AUTO_PROFILER_LABEL("GetStorageConnection", DOM)mozilla::AutoProfilerLabel raiiObject1094( "GetStorageConnection" , nullptr, JS::ProfilingCategoryPair::DOM); |
1095 | |
1096 | QM_TRY_INSPECT(const bool& exists,auto tryResult839 = (::mozilla::ToResultInvokeMember( (aDatabaseFile ), &::mozilla::detail::DerefedType<decltype(aDatabaseFile )>::Exists)); if ((__builtin_expect(!!(tryResult839.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDatabaseFile), &::mozilla::detail::DerefedType<decltype(aDatabaseFile)>::Exists)" , tryResult839.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1097, mozilla::dom::quota::Severity::Error); return tryResult839 .propagateErr(); } const bool& exists = tryResult839.inspect (); |
1097 | MOZ_TO_RESULT_INVOKE_MEMBER(aDatabaseFile, Exists))auto tryResult839 = (::mozilla::ToResultInvokeMember( (aDatabaseFile ), &::mozilla::detail::DerefedType<decltype(aDatabaseFile )>::Exists)); if ((__builtin_expect(!!(tryResult839.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDatabaseFile), &::mozilla::detail::DerefedType<decltype(aDatabaseFile)>::Exists)" , tryResult839.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1097, mozilla::dom::quota::Severity::Error); return tryResult839 .propagateErr(); } const bool& exists = tryResult839.inspect ();; |
1098 | |
1099 | QM_TRY(OkIf(exists), Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR),{auto tryResult840 = (OkIf(exists)); static_assert(std::is_empty_v <typename decltype(tryResult840)::ok_type>); if ((__builtin_expect (!!(tryResult840.isErr()), 0))) { auto tryTempError = tryResult840 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(exists)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1100, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1100, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(exists)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
1100 | IDB_REPORT_INTERNAL_ERR_LAMBDA){auto tryResult840 = (OkIf(exists)); static_assert(std::is_empty_v <typename decltype(tryResult840)::ok_type>); if ((__builtin_expect (!!(tryResult840.isErr()), 0))) { auto tryTempError = tryResult840 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(exists)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1100, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1100, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(exists)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; |
1101 | |
1102 | QM_TRY_INSPECT(auto tryResult841 = (GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId , aMaybeKey)); if ((__builtin_expect(!!(tryResult841.isErr()) , 0))) { mozilla::dom::quota::HandleError("GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId, aMaybeKey)" , tryResult841.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1104, mozilla::dom::quota::Severity::Error); return tryResult841 .propagateErr(); } const auto& dbFileUrl = tryResult841.inspect (); |
1103 | const auto& dbFileUrl,auto tryResult841 = (GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId , aMaybeKey)); if ((__builtin_expect(!!(tryResult841.isErr()) , 0))) { mozilla::dom::quota::HandleError("GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId, aMaybeKey)" , tryResult841.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1104, mozilla::dom::quota::Severity::Error); return tryResult841 .propagateErr(); } const auto& dbFileUrl = tryResult841.inspect (); |
1104 | GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId, aMaybeKey))auto tryResult841 = (GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId , aMaybeKey)); if ((__builtin_expect(!!(tryResult841.isErr()) , 0))) { mozilla::dom::quota::HandleError("GetDatabaseFileURL(aDatabaseFile, aDirectoryLockId, aMaybeKey)" , tryResult841.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1104, mozilla::dom::quota::Severity::Error); return tryResult841 .propagateErr(); } const auto& dbFileUrl = tryResult841.inspect ();; |
1105 | |
1106 | QM_TRY_INSPECT(const auto& storageService,auto tryResult842 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult842.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult842.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1109, mozilla::dom::quota::Severity::Error); return tryResult842 .propagateErr(); } const auto& storageService = tryResult842 .inspect(); |
1107 | MOZ_TO_RESULT_GET_TYPED(nsCOMPtr<mozIStorageService>,auto tryResult842 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult842.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult842.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1109, mozilla::dom::quota::Severity::Error); return tryResult842 .propagateErr(); } const auto& storageService = tryResult842 .inspect(); |
1108 | MOZ_SELECT_OVERLOAD(do_GetService),auto tryResult842 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult842.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult842.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1109, mozilla::dom::quota::Severity::Error); return tryResult842 .propagateErr(); } const auto& storageService = tryResult842 .inspect(); |
1109 | MOZ_STORAGE_SERVICE_CONTRACTID))auto tryResult842 = (::mozilla::ToResultGet< nsCOMPtr<mozIStorageService > >([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...) ; }, "@mozilla.org/storage" "/service;1")); if ((__builtin_expect (!!(tryResult842.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultGet< nsCOMPtr<mozIStorageService>>([](auto&&... aArgs) -> decltype(auto) { return do_GetService(std::forward<decltype(aArgs)>(aArgs)...); }, \"@mozilla.org/storage\" \"/service;1\")" , tryResult842.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1109, mozilla::dom::quota::Severity::Error); return tryResult842 .propagateErr(); } const auto& storageService = tryResult842 .inspect();; |
1110 | |
1111 | QM_TRY_UNWRAP(auto tryResult843 = (OpenDatabaseAndHandleBusy(*storageService , *dbFileUrl, aTelemetryId)); if ((__builtin_expect(!!(tryResult843 .isErr()), 0))) { mozilla::dom::quota::HandleError("OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId)" , tryResult843.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1113, mozilla::dom::quota::Severity::Error); return tryResult843 .propagateErr(); } nsCOMPtr<mozIStorageConnection> connection = tryResult843.unwrap(); |
1112 | nsCOMPtr<mozIStorageConnection> connection,auto tryResult843 = (OpenDatabaseAndHandleBusy(*storageService , *dbFileUrl, aTelemetryId)); if ((__builtin_expect(!!(tryResult843 .isErr()), 0))) { mozilla::dom::quota::HandleError("OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId)" , tryResult843.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1113, mozilla::dom::quota::Severity::Error); return tryResult843 .propagateErr(); } nsCOMPtr<mozIStorageConnection> connection = tryResult843.unwrap(); |
1113 | OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId))auto tryResult843 = (OpenDatabaseAndHandleBusy(*storageService , *dbFileUrl, aTelemetryId)); if ((__builtin_expect(!!(tryResult843 .isErr()), 0))) { mozilla::dom::quota::HandleError("OpenDatabaseAndHandleBusy(*storageService, *dbFileUrl, aTelemetryId)" , tryResult843.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1113, mozilla::dom::quota::Severity::Error); return tryResult843 .propagateErr(); } nsCOMPtr<mozIStorageConnection> connection = tryResult843.unwrap();; |
1114 | |
1115 | QM_TRY(MOZ_TO_RESULT(SetDefaultPragmas(*connection))){auto tryResult844 = (ToResult(SetDefaultPragmas(*connection) )); static_assert(std::is_empty_v<typename decltype(tryResult844 )::ok_type>); if ((__builtin_expect(!!(tryResult844.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(SetDefaultPragmas(*connection))" , tryResult844.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1115, mozilla::dom::quota::Severity::Error); return tryResult844 .propagateErr(); }}; |
1116 | |
1117 | QM_TRY(MOZ_TO_RESULT(SetJournalMode(*connection))){auto tryResult845 = (ToResult(SetJournalMode(*connection))); static_assert(std::is_empty_v<typename decltype(tryResult845 )::ok_type>); if ((__builtin_expect(!!(tryResult845.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(SetJournalMode(*connection))" , tryResult845.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1117, mozilla::dom::quota::Severity::Error); return tryResult845 .propagateErr(); }}; |
1118 | |
1119 | return WrapMovingNotNullUnchecked(std::move(connection)); |
1120 | } |
1121 | |
1122 | Result<MovingNotNull<nsCOMPtr<mozIStorageConnection>>, nsresult> |
1123 | GetStorageConnection(const nsAString& aDatabaseFilePath, |
1124 | const int64_t aDirectoryLockId, |
1125 | const uint32_t aTelemetryId, |
1126 | const Maybe<CipherKey>& aMaybeKey) { |
1127 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1127); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 1127; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1128 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1128); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 1128; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1129 | MOZ_ASSERT(!aDatabaseFilePath.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseFilePath.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseFilePath.IsEmpty() ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "!aDatabaseFilePath.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1129); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseFilePath.IsEmpty()" ")"); do { *((volatile int*)__null) = 1129; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1130 | MOZ_ASSERT(StringEndsWith(aDatabaseFilePath, kSQLiteSuffix))do { static_assert( mozilla::detail::AssertionConditionType< decltype(StringEndsWith(aDatabaseFilePath, kSQLiteSuffix))> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(StringEndsWith(aDatabaseFilePath, kSQLiteSuffix)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("StringEndsWith(aDatabaseFilePath, kSQLiteSuffix)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1130); AnnotateMozCrashReason("MOZ_ASSERT" "(" "StringEndsWith(aDatabaseFilePath, kSQLiteSuffix)" ")"); do { *((volatile int*)__null) = 1130; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1131 | MOZ_ASSERT(aDirectoryLockId >= 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectoryLockId >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectoryLockId >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectoryLockId >= 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1131); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectoryLockId >= 0" ")"); do { *((volatile int*)__null) = 1131; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1132 | |
1133 | nsCOMPtr<nsIFile> dbFile = GetFileForPath(aDatabaseFilePath); |
1134 | |
1135 | QM_TRY(OkIf(dbFile), Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR),{auto tryResult846 = (OkIf(dbFile)); static_assert(std::is_empty_v <typename decltype(tryResult846)::ok_type>); if ((__builtin_expect (!!(tryResult846.isErr()), 0))) { auto tryTempError = tryResult846 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(dbFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1136, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1136, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(dbFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
1136 | IDB_REPORT_INTERNAL_ERR_LAMBDA){auto tryResult846 = (OkIf(dbFile)); static_assert(std::is_empty_v <typename decltype(tryResult846)::ok_type>); if ((__builtin_expect (!!(tryResult846.isErr()), 0))) { auto tryTempError = tryResult846 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(dbFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1136, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1136, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(dbFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; |
1137 | |
1138 | return GetStorageConnection(*dbFile, aDirectoryLockId, aTelemetryId, |
1139 | aMaybeKey); |
1140 | } |
1141 | |
1142 | /******************************************************************************* |
1143 | * ConnectionPool declarations |
1144 | ******************************************************************************/ |
1145 | |
1146 | class DatabaseConnection final : public CachingDatabaseConnection { |
1147 | friend class ConnectionPool; |
1148 | |
1149 | enum class CheckpointMode { Full, Restart, Truncate }; |
1150 | |
1151 | public: |
1152 | class AutoSavepoint; |
1153 | class UpdateRefcountFunction; |
1154 | |
1155 | private: |
1156 | InitializedOnce<const NotNull<SafeRefPtr<DatabaseFileManager>>> mFileManager; |
1157 | RefPtr<UpdateRefcountFunction> mUpdateRefcountFunction; |
1158 | RefPtr<QuotaObject> mQuotaObject; |
1159 | RefPtr<QuotaObject> mJournalQuotaObject; |
1160 | IDBTransaction::Durability mLastDurability; |
1161 | bool mInReadTransaction; |
1162 | bool mInWriteTransaction; |
1163 | |
1164 | #ifdef DEBUG1 |
1165 | uint32_t mDEBUGSavepointCount; |
1166 | #endif |
1167 | |
1168 | public: |
1169 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(DatabaseConnection)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<DatabaseConnection>, "Reference-counted class " "DatabaseConnection" " should not have a public destructor. " "Make this class's destructor non-public"); do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1169); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 1169; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("DatabaseConnection"), (uint32_t)(sizeof(*this)) ); return (nsrefcnt)count; } MozExternalRefCountType Release( void) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1169); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 1169 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("DatabaseConnection")); if (count == 0) { delete (this ); return 0; } return count; } using HasThreadSafeRefCnt = std ::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt ; public: |
1170 | |
1171 | UpdateRefcountFunction* GetUpdateRefcountFunction() const { |
1172 | AssertIsOnConnectionThread(); |
1173 | |
1174 | return mUpdateRefcountFunction; |
1175 | } |
1176 | |
1177 | nsresult BeginWriteTransaction(const IDBTransaction::Durability aDurability); |
1178 | |
1179 | nsresult CommitWriteTransaction(); |
1180 | |
1181 | void RollbackWriteTransaction(); |
1182 | |
1183 | void FinishWriteTransaction(); |
1184 | |
1185 | nsresult StartSavepoint(); |
1186 | |
1187 | nsresult ReleaseSavepoint(); |
1188 | |
1189 | nsresult RollbackSavepoint(); |
1190 | |
1191 | nsresult Checkpoint() { |
1192 | AssertIsOnConnectionThread(); |
1193 | |
1194 | return CheckpointInternal(CheckpointMode::Full); |
1195 | } |
1196 | |
1197 | void DoIdleProcessing(bool aNeedsCheckpoint, |
1198 | const Atomic<bool>& aInterrupted); |
1199 | |
1200 | void Close(); |
1201 | |
1202 | nsresult DisableQuotaChecks(); |
1203 | |
1204 | void EnableQuotaChecks(); |
1205 | |
1206 | private: |
1207 | DatabaseConnection( |
1208 | MovingNotNull<nsCOMPtr<mozIStorageConnection>> aStorageConnection, |
1209 | MovingNotNull<SafeRefPtr<DatabaseFileManager>> aFileManager); |
1210 | |
1211 | ~DatabaseConnection(); |
1212 | |
1213 | nsresult Init(); |
1214 | |
1215 | nsresult CheckpointInternal(CheckpointMode aMode); |
1216 | |
1217 | Result<uint32_t, nsresult> GetFreelistCount( |
1218 | CachedStatement& aCachedStatement); |
1219 | |
1220 | /** |
1221 | * On success, returns whether some pages were freed. |
1222 | */ |
1223 | Result<bool, nsresult> ReclaimFreePagesWhileIdle( |
1224 | CachedStatement& aFreelistStatement, CachedStatement& aRollbackStatement, |
1225 | uint32_t aFreelistCount, bool aNeedsCheckpoint, |
1226 | const Atomic<bool>& aInterrupted); |
1227 | |
1228 | Result<int64_t, nsresult> GetFileSize(const nsAString& aPath); |
1229 | }; |
1230 | |
1231 | class MOZ_STACK_CLASS DatabaseConnection::AutoSavepoint final { |
1232 | DatabaseConnection* mConnection; |
1233 | #ifdef DEBUG1 |
1234 | const TransactionBase* mDEBUGTransaction; |
1235 | #endif |
1236 | |
1237 | public: |
1238 | AutoSavepoint(); |
1239 | ~AutoSavepoint(); |
1240 | |
1241 | nsresult Start(const TransactionBase& aTransaction); |
1242 | |
1243 | nsresult Commit(); |
1244 | }; |
1245 | |
1246 | class DatabaseConnection::UpdateRefcountFunction final |
1247 | : public mozIStorageFunction { |
1248 | class FileInfoEntry; |
1249 | |
1250 | enum class UpdateType { Increment, Decrement }; |
1251 | |
1252 | DatabaseConnection* const mConnection; |
1253 | DatabaseFileManager& mFileManager; |
1254 | nsClassHashtable<nsUint64HashKey, FileInfoEntry> mFileInfoEntries; |
1255 | nsTHashMap<nsUint64HashKey, NotNull<FileInfoEntry*>> mSavepointEntriesIndex; |
1256 | |
1257 | nsTArray<int64_t> mJournalsToCreateBeforeCommit; |
1258 | nsTArray<int64_t> mJournalsToRemoveAfterCommit; |
1259 | nsTArray<int64_t> mJournalsToRemoveAfterAbort; |
1260 | |
1261 | bool mInSavepoint; |
1262 | |
1263 | public: |
1264 | NS_DECL_ISUPPORTS_ONEVENTTARGETpublic: virtual nsresult QueryInterface(const nsIID& aIID , void** aInstancePtr) override; virtual MozExternalRefCountType AddRef(void) override; virtual MozExternalRefCountType Release (void) override; using HasThreadSafeRefCnt = std::false_type; protected: nsAutoRefCnt mRefCnt; nsAutoOwningEventTarget _mOwningThread ; public: |
1265 | NS_DECL_MOZISTORAGEFUNCTIONvirtual nsresult OnFunctionCall(mozIStorageValueArray *aFunctionArguments , nsIVariant **_retval) override; |
1266 | |
1267 | UpdateRefcountFunction(DatabaseConnection* aConnection, |
1268 | DatabaseFileManager& aFileManager); |
1269 | |
1270 | nsresult WillCommit(); |
1271 | |
1272 | void DidCommit(); |
1273 | |
1274 | void DidAbort(); |
1275 | |
1276 | void StartSavepoint(); |
1277 | |
1278 | void ReleaseSavepoint(); |
1279 | |
1280 | void RollbackSavepoint(); |
1281 | |
1282 | void Reset(); |
1283 | |
1284 | private: |
1285 | ~UpdateRefcountFunction() = default; |
1286 | |
1287 | nsresult ProcessValue(mozIStorageValueArray* aValues, int32_t aIndex, |
1288 | UpdateType aUpdateType); |
1289 | |
1290 | nsresult CreateJournals(); |
1291 | |
1292 | nsresult RemoveJournals(const nsTArray<int64_t>& aJournals); |
1293 | }; |
1294 | |
1295 | class DatabaseConnection::UpdateRefcountFunction::FileInfoEntry final { |
1296 | SafeRefPtr<DatabaseFileInfo> mFileInfo; |
1297 | int32_t mDelta; |
1298 | int32_t mSavepointDelta; |
1299 | |
1300 | public: |
1301 | explicit FileInfoEntry(SafeRefPtr<DatabaseFileInfo> aFileInfo) |
1302 | : mFileInfo(std::move(aFileInfo)), mDelta(0), mSavepointDelta(0) { |
1303 | MOZ_COUNT_CTOR(DatabaseConnection::UpdateRefcountFunction::FileInfoEntry)do { static_assert(std::is_class_v<DatabaseConnection::UpdateRefcountFunction ::FileInfoEntry>, "Token '" "DatabaseConnection::UpdateRefcountFunction::FileInfoEntry" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, DatabaseConnection::UpdateRefcountFunction::FileInfoEntry >::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "DatabaseConnection::UpdateRefcountFunction::FileInfoEntry" , sizeof(*this)); } while (0); |
1304 | } |
1305 | |
1306 | void IncDeltas(bool aUpdateSavepointDelta) { |
1307 | ++mDelta; |
1308 | if (aUpdateSavepointDelta) { |
1309 | ++mSavepointDelta; |
1310 | } |
1311 | } |
1312 | void DecDeltas(bool aUpdateSavepointDelta) { |
1313 | --mDelta; |
1314 | if (aUpdateSavepointDelta) { |
1315 | --mSavepointDelta; |
1316 | } |
1317 | } |
1318 | void DecBySavepointDelta() { mDelta -= mSavepointDelta; } |
1319 | SafeRefPtr<DatabaseFileInfo> ReleaseFileInfo() { |
1320 | return std::move(mFileInfo); |
1321 | } |
1322 | void MaybeUpdateDBRefs() { |
1323 | if (mDelta) { |
1324 | mFileInfo->UpdateDBRefs(mDelta); |
1325 | } |
1326 | } |
1327 | |
1328 | int32_t Delta() const { return mDelta; } |
1329 | int32_t SavepointDelta() const { return mSavepointDelta; } |
1330 | |
1331 | ~FileInfoEntry() { |
1332 | MOZ_COUNT_DTOR(DatabaseConnection::UpdateRefcountFunction::FileInfoEntry)do { static_assert(std::is_class_v<DatabaseConnection::UpdateRefcountFunction ::FileInfoEntry>, "Token '" "DatabaseConnection::UpdateRefcountFunction::FileInfoEntry" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, DatabaseConnection::UpdateRefcountFunction::FileInfoEntry >::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "DatabaseConnection::UpdateRefcountFunction::FileInfoEntry" , sizeof(*this)); } while (0); |
1333 | } |
1334 | }; |
1335 | |
1336 | class ConnectionPool final { |
1337 | public: |
1338 | class FinishCallback; |
1339 | |
1340 | private: |
1341 | class ConnectionRunnable; |
1342 | class CloseConnectionRunnable; |
1343 | struct DatabaseInfo; |
1344 | struct DatabaseCompleteCallback; |
1345 | class FinishCallbackWrapper; |
1346 | class IdleConnectionRunnable; |
1347 | |
1348 | #ifdef DEBUG1 |
1349 | class TransactionRunnable; |
1350 | #endif |
1351 | class TransactionInfo; |
1352 | struct TransactionInfoPair; |
1353 | |
1354 | struct IdleResource { |
1355 | TimeStamp mIdleTime; |
1356 | |
1357 | IdleResource(const IdleResource& aOther) = delete; |
1358 | IdleResource(IdleResource&& aOther) noexcept |
1359 | : IdleResource(aOther.mIdleTime) {} |
1360 | IdleResource& operator=(const IdleResource& aOther) = delete; |
1361 | IdleResource& operator=(IdleResource&& aOther) = delete; |
1362 | |
1363 | protected: |
1364 | explicit IdleResource(const TimeStamp& aIdleTime); |
1365 | |
1366 | ~IdleResource(); |
1367 | }; |
1368 | |
1369 | struct IdleDatabaseInfo final : public IdleResource { |
1370 | InitializedOnce<const NotNull<DatabaseInfo*>> mDatabaseInfo; |
1371 | |
1372 | public: |
1373 | explicit IdleDatabaseInfo(DatabaseInfo& aDatabaseInfo); |
1374 | |
1375 | IdleDatabaseInfo(const IdleDatabaseInfo& aOther) = delete; |
1376 | IdleDatabaseInfo(IdleDatabaseInfo&& aOther) noexcept |
1377 | : IdleResource(std::move(aOther)), |
1378 | mDatabaseInfo{std::move(aOther.mDatabaseInfo)} { |
1379 | MOZ_ASSERT(mDatabaseInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabaseInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabaseInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabaseInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1379); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabaseInfo" ")"); do { *((volatile int*)__null) = 1379; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1380 | |
1381 | MOZ_COUNT_CTOR(ConnectionPool::IdleDatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::IdleDatabaseInfo >, "Token '" "ConnectionPool::IdleDatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::IdleDatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::IdleDatabaseInfo" , sizeof(*this)); } while (0); |
1382 | } |
1383 | IdleDatabaseInfo& operator=(const IdleDatabaseInfo& aOther) = delete; |
1384 | IdleDatabaseInfo& operator=(IdleDatabaseInfo&& aOther) = delete; |
1385 | |
1386 | ~IdleDatabaseInfo(); |
1387 | |
1388 | bool operator==(const IdleDatabaseInfo& aOther) const { |
1389 | return *mDatabaseInfo == *aOther.mDatabaseInfo; |
1390 | } |
1391 | |
1392 | bool operator==(const DatabaseInfo* aDatabaseInfo) const { |
1393 | return *mDatabaseInfo == aDatabaseInfo; |
1394 | } |
1395 | |
1396 | bool operator<(const IdleDatabaseInfo& aOther) const { |
1397 | return mIdleTime < aOther.mIdleTime; |
1398 | } |
1399 | }; |
1400 | |
1401 | struct PerformingIdleMaintenanceDatabaseInfo { |
1402 | const NotNull<DatabaseInfo*> mDatabaseInfo; |
1403 | RefPtr<IdleConnectionRunnable> mIdleConnectionRunnable; |
1404 | |
1405 | PerformingIdleMaintenanceDatabaseInfo( |
1406 | DatabaseInfo& aDatabaseInfo, |
1407 | RefPtr<IdleConnectionRunnable> aIdleConnectionRunnable); |
1408 | |
1409 | PerformingIdleMaintenanceDatabaseInfo( |
1410 | const PerformingIdleMaintenanceDatabaseInfo& aOther) = delete; |
1411 | PerformingIdleMaintenanceDatabaseInfo( |
1412 | PerformingIdleMaintenanceDatabaseInfo&& aOther) noexcept |
1413 | : mDatabaseInfo{aOther.mDatabaseInfo}, |
1414 | mIdleConnectionRunnable{std::move(aOther.mIdleConnectionRunnable)} { |
1415 | MOZ_COUNT_CTOR(ConnectionPool::PerformingIdleMaintenanceDatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::PerformingIdleMaintenanceDatabaseInfo >, "Token '" "ConnectionPool::PerformingIdleMaintenanceDatabaseInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ConnectionPool::PerformingIdleMaintenanceDatabaseInfo >::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::PerformingIdleMaintenanceDatabaseInfo" , sizeof(*this)); } while (0); |
1416 | } |
1417 | PerformingIdleMaintenanceDatabaseInfo& operator=( |
1418 | const PerformingIdleMaintenanceDatabaseInfo& aOther) = delete; |
1419 | PerformingIdleMaintenanceDatabaseInfo& operator=( |
1420 | PerformingIdleMaintenanceDatabaseInfo&& aOther) = delete; |
1421 | |
1422 | ~PerformingIdleMaintenanceDatabaseInfo(); |
1423 | |
1424 | bool operator==(const DatabaseInfo* aDatabaseInfo) const { |
1425 | return mDatabaseInfo == aDatabaseInfo; |
1426 | } |
1427 | }; |
1428 | |
1429 | // This mutex guards mDatabases, see below. |
1430 | Mutex mDatabasesMutex MOZ_UNANNOTATED; |
1431 | |
1432 | nsCOMPtr<nsIThreadPool> mIOTarget; |
1433 | nsTArray<IdleDatabaseInfo> mIdleDatabases; |
1434 | nsTArray<PerformingIdleMaintenanceDatabaseInfo> |
1435 | mDatabasesPerformingIdleMaintenance; |
1436 | nsCOMPtr<nsITimer> mIdleTimer; |
1437 | TimeStamp mTargetIdleTime; |
1438 | |
1439 | // Only modifed on the owning thread, but read on multiple threads. Therefore |
1440 | // all modifications and all reads off the owning thread must be protected by |
1441 | // mDatabasesMutex. |
1442 | nsClassHashtable<nsCStringHashKey, DatabaseInfo> mDatabases; |
1443 | |
1444 | nsClassHashtable<nsUint64HashKey, TransactionInfo> mTransactions; |
1445 | nsTArray<NotNull<TransactionInfo*>> mQueuedTransactions; |
1446 | |
1447 | nsTArray<UniquePtr<DatabaseCompleteCallback>> mCompleteCallbacks; |
1448 | |
1449 | uint64_t mNextTransactionId; |
1450 | FlippedOnce<false> mShutdownRequested; |
1451 | FlippedOnce<false> mShutdownComplete; |
1452 | |
1453 | public: |
1454 | ConnectionPool(); |
1455 | |
1456 | void AssertIsOnOwningThread() const { |
1457 | NS_ASSERT_OWNINGTHREAD(ConnectionPool)_mOwningThread.AssertOwnership("ConnectionPool" " not thread-safe" ); |
1458 | } |
1459 | |
1460 | Result<RefPtr<DatabaseConnection>, nsresult> GetOrCreateConnection( |
1461 | const Database& aDatabase); |
1462 | |
1463 | uint64_t Start(const nsID& aBackgroundChildLoggingId, |
1464 | const nsACString& aDatabaseId, int64_t aLoggingSerialNumber, |
1465 | const nsTArray<nsString>& aObjectStoreNames, |
1466 | bool aIsWriteTransaction, |
1467 | TransactionDatabaseOperationBase* aTransactionOp); |
1468 | |
1469 | void Dispatch(uint64_t aTransactionId, nsIRunnable* aRunnable); |
1470 | |
1471 | void Finish(uint64_t aTransactionId, FinishCallback* aCallback); |
1472 | |
1473 | void CloseDatabaseWhenIdle(const nsACString& aDatabaseId) { |
1474 | Unused << CloseDatabaseWhenIdleInternal(aDatabaseId); |
1475 | } |
1476 | |
1477 | void WaitForDatabaseToComplete(const nsCString& aDatabaseId, |
1478 | nsIRunnable* aCallback); |
1479 | |
1480 | void Shutdown(); |
1481 | |
1482 | NS_INLINE_DECL_REFCOUNTING(ConnectionPool)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<ConnectionPool>, "Reference-counted class " "ConnectionPool" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1482); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 1482; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); _mOwningThread.AssertOwnership("ConnectionPool" " not thread-safe"); ++mRefCnt; NS_LogAddRef((this), (mRefCnt ), ("ConnectionPool"), (uint32_t)(sizeof(*this))); return mRefCnt ; } MozExternalRefCountType Release(void) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1482); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 1482 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); _mOwningThread.AssertOwnership("ConnectionPool" " not thread-safe" ); --mRefCnt; NS_LogRelease((this), (mRefCnt), ("ConnectionPool" )); if (mRefCnt == 0) { mRefCnt = 1; delete (this); return 0; } return mRefCnt; } using HasThreadSafeRefCnt = std::false_type ; protected: nsAutoRefCnt mRefCnt; nsAutoOwningThread _mOwningThread ; public: |
1483 | |
1484 | private: |
1485 | ~ConnectionPool(); |
1486 | |
1487 | static void IdleTimerCallback(nsITimer* aTimer, void* aClosure); |
1488 | |
1489 | static uint32_t SerialNumber() { return ++sSerialNumber; } |
1490 | |
1491 | static uint32_t sSerialNumber; |
1492 | |
1493 | void Cleanup(); |
1494 | |
1495 | void AdjustIdleTimer(); |
1496 | |
1497 | void CancelIdleTimer(); |
1498 | |
1499 | void CloseIdleDatabases(); |
1500 | |
1501 | bool ScheduleTransaction(TransactionInfo& aTransactionInfo, |
1502 | bool aFromQueuedTransactions); |
1503 | |
1504 | void NoteFinishedTransaction(uint64_t aTransactionId); |
1505 | |
1506 | void ScheduleQueuedTransactions(); |
1507 | |
1508 | void NoteIdleDatabase(DatabaseInfo& aDatabaseInfo); |
1509 | |
1510 | void NoteClosedDatabase(DatabaseInfo& aDatabaseInfo); |
1511 | |
1512 | bool MaybeFireCallback(DatabaseCompleteCallback* aCallback); |
1513 | |
1514 | void PerformIdleDatabaseMaintenance(DatabaseInfo& aDatabaseInfo); |
1515 | |
1516 | void CloseDatabase(DatabaseInfo& aDatabaseInfo) const; |
1517 | |
1518 | bool CloseDatabaseWhenIdleInternal(const nsACString& aDatabaseId); |
1519 | }; |
1520 | |
1521 | class ConnectionPool::ConnectionRunnable : public Runnable { |
1522 | protected: |
1523 | DatabaseInfo& mDatabaseInfo; |
1524 | nsCOMPtr<nsIEventTarget> mOwningEventTarget; |
1525 | |
1526 | explicit ConnectionRunnable(DatabaseInfo& aDatabaseInfo); |
1527 | |
1528 | ~ConnectionRunnable() override = default; |
1529 | }; |
1530 | |
1531 | class ConnectionPool::IdleConnectionRunnable final : public ConnectionRunnable { |
1532 | const bool mNeedsCheckpoint; |
1533 | Atomic<bool> mInterrupted; |
1534 | |
1535 | public: |
1536 | IdleConnectionRunnable(DatabaseInfo& aDatabaseInfo, bool aNeedsCheckpoint) |
1537 | : ConnectionRunnable(aDatabaseInfo), mNeedsCheckpoint(aNeedsCheckpoint) {} |
1538 | |
1539 | NS_INLINE_DECL_REFCOUNTING_INHERITED(IdleConnectionRunnable,virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<IdleConnectionRunnable>, "Reference-counted class " "IdleConnectionRunnable" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = ConnectionRunnable ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <IdleConnectionRunnable>) { NS_LogAddRef((this), (r), ( "IdleConnectionRunnable"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = ConnectionRunnable::Release(); if constexpr (::mozilla:: detail::ShouldLogInheritedRefcnt<IdleConnectionRunnable> ) { NS_LogRelease((this), (r), ("IdleConnectionRunnable")); } return r; } |
1540 | ConnectionRunnable)virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<IdleConnectionRunnable>, "Reference-counted class " "IdleConnectionRunnable" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = ConnectionRunnable ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <IdleConnectionRunnable>) { NS_LogAddRef((this), (r), ( "IdleConnectionRunnable"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = ConnectionRunnable::Release(); if constexpr (::mozilla:: detail::ShouldLogInheritedRefcnt<IdleConnectionRunnable> ) { NS_LogRelease((this), (r), ("IdleConnectionRunnable")); } return r; } |
1541 | |
1542 | void Interrupt() { mInterrupted = true; } |
1543 | |
1544 | private: |
1545 | ~IdleConnectionRunnable() override = default; |
1546 | |
1547 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
1548 | }; |
1549 | |
1550 | class ConnectionPool::CloseConnectionRunnable final |
1551 | : public ConnectionRunnable { |
1552 | public: |
1553 | explicit CloseConnectionRunnable(DatabaseInfo& aDatabaseInfo) |
1554 | : ConnectionRunnable(aDatabaseInfo) {} |
1555 | |
1556 | NS_INLINE_DECL_REFCOUNTING_INHERITED(CloseConnectionRunnable,virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<CloseConnectionRunnable>, "Reference-counted class " "CloseConnectionRunnable" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = ConnectionRunnable ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <CloseConnectionRunnable>) { NS_LogAddRef((this), (r), ( "CloseConnectionRunnable"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = ConnectionRunnable::Release(); if constexpr (::mozilla:: detail::ShouldLogInheritedRefcnt<CloseConnectionRunnable> ) { NS_LogRelease((this), (r), ("CloseConnectionRunnable")); } return r; } |
1557 | ConnectionRunnable)virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<CloseConnectionRunnable>, "Reference-counted class " "CloseConnectionRunnable" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = ConnectionRunnable ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <CloseConnectionRunnable>) { NS_LogAddRef((this), (r), ( "CloseConnectionRunnable"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = ConnectionRunnable::Release(); if constexpr (::mozilla:: detail::ShouldLogInheritedRefcnt<CloseConnectionRunnable> ) { NS_LogRelease((this), (r), ("CloseConnectionRunnable")); } return r; } |
1558 | |
1559 | private: |
1560 | ~CloseConnectionRunnable() override = default; |
1561 | |
1562 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
1563 | }; |
1564 | |
1565 | struct ConnectionPool::DatabaseInfo final { |
1566 | friend class mozilla::DefaultDelete<DatabaseInfo>; |
1567 | |
1568 | RefPtr<ConnectionPool> mConnectionPool; |
1569 | const nsCString mDatabaseId; |
1570 | RefPtr<DatabaseConnection> mConnection; |
1571 | nsClassHashtable<nsStringHashKey, TransactionInfoPair> mBlockingTransactions; |
1572 | nsTArray<NotNull<TransactionInfo*>> mTransactionsScheduledDuringClose; |
1573 | nsTArray<NotNull<TransactionInfo*>> mScheduledWriteTransactions; |
1574 | Maybe<TransactionInfo&> mRunningWriteTransaction; |
1575 | RefPtr<TaskQueue> mEventTarget; |
1576 | uint32_t mReadTransactionCount; |
1577 | uint32_t mWriteTransactionCount; |
1578 | bool mNeedsCheckpoint; |
1579 | bool mIdle; |
1580 | FlippedOnce<false> mCloseOnIdle; |
1581 | bool mClosing; |
1582 | |
1583 | #ifdef DEBUG1 |
1584 | nsISerialEventTarget* mDEBUGConnectionEventTarget; |
1585 | #endif |
1586 | |
1587 | DatabaseInfo(ConnectionPool* aConnectionPool, const nsACString& aDatabaseId); |
1588 | |
1589 | void AssertIsOnConnectionThread() const { |
1590 | MOZ_ASSERT(mDEBUGConnectionEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGConnectionEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGConnectionEventTarget) )), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGConnectionEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1590); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGConnectionEventTarget" ")"); do { *((volatile int*)__null) = 1590; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1591 | MOZ_ASSERT(GetCurrentSerialEventTarget() == mDEBUGConnectionEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(GetCurrentSerialEventTarget() == mDEBUGConnectionEventTarget )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(GetCurrentSerialEventTarget() == mDEBUGConnectionEventTarget ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "GetCurrentSerialEventTarget() == mDEBUGConnectionEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1591); AnnotateMozCrashReason("MOZ_ASSERT" "(" "GetCurrentSerialEventTarget() == mDEBUGConnectionEventTarget" ")"); do { *((volatile int*)__null) = 1591; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1592 | } |
1593 | |
1594 | uint64_t TotalTransactionCount() const { |
1595 | return mReadTransactionCount + mWriteTransactionCount; |
1596 | } |
1597 | |
1598 | nsresult Dispatch(already_AddRefed<nsIRunnable> aRunnable); |
1599 | |
1600 | private: |
1601 | ~DatabaseInfo(); |
1602 | |
1603 | DatabaseInfo(const DatabaseInfo&) = delete; |
1604 | DatabaseInfo& operator=(const DatabaseInfo&) = delete; |
1605 | }; |
1606 | |
1607 | struct ConnectionPool::DatabaseCompleteCallback final { |
1608 | friend class DefaultDelete<DatabaseCompleteCallback>; |
1609 | |
1610 | nsCString mDatabaseId; |
1611 | nsCOMPtr<nsIRunnable> mCallback; |
1612 | |
1613 | DatabaseCompleteCallback(const nsCString& aDatabaseIds, |
1614 | nsIRunnable* aCallback); |
1615 | |
1616 | private: |
1617 | ~DatabaseCompleteCallback(); |
1618 | }; |
1619 | |
1620 | class NS_NO_VTABLE ConnectionPool::FinishCallback : public nsIRunnable { |
1621 | public: |
1622 | // Called on the owning thread before any additional transactions are |
1623 | // unblocked. |
1624 | virtual void TransactionFinishedBeforeUnblock() = 0; |
1625 | |
1626 | // Called on the owning thread after additional transactions may have been |
1627 | // unblocked. |
1628 | virtual void TransactionFinishedAfterUnblock() = 0; |
1629 | |
1630 | protected: |
1631 | FinishCallback() = default; |
1632 | |
1633 | virtual ~FinishCallback() = default; |
1634 | }; |
1635 | |
1636 | class ConnectionPool::FinishCallbackWrapper final : public Runnable { |
1637 | RefPtr<ConnectionPool> mConnectionPool; |
1638 | RefPtr<FinishCallback> mCallback; |
1639 | nsCOMPtr<nsIEventTarget> mOwningEventTarget; |
1640 | uint64_t mTransactionId; |
1641 | bool mHasRunOnce; |
1642 | |
1643 | public: |
1644 | FinishCallbackWrapper(ConnectionPool* aConnectionPool, |
1645 | uint64_t aTransactionId, FinishCallback* aCallback); |
1646 | |
1647 | NS_INLINE_DECL_REFCOUNTING_INHERITED(FinishCallbackWrapper, Runnable)virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<FinishCallbackWrapper>, "Reference-counted class " "FinishCallbackWrapper" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = Runnable ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <FinishCallbackWrapper>) { NS_LogAddRef((this), (r), ("FinishCallbackWrapper" ), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = Runnable::Release(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt<FinishCallbackWrapper >) { NS_LogRelease((this), (r), ("FinishCallbackWrapper")) ; } return r; } |
1648 | |
1649 | private: |
1650 | ~FinishCallbackWrapper() override; |
1651 | |
1652 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
1653 | }; |
1654 | |
1655 | #ifdef DEBUG1 |
1656 | |
1657 | class ConnectionPool::TransactionRunnable final : public Runnable { |
1658 | public: |
1659 | explicit TransactionRunnable(nsCOMPtr<nsIRunnable> aRunnable); |
1660 | |
1661 | private: |
1662 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
1663 | |
1664 | nsCOMPtr<nsIRunnable> mRunnable; |
1665 | }; |
1666 | |
1667 | #endif |
1668 | |
1669 | class ConnectionPool::TransactionInfo final { |
1670 | friend class mozilla::DefaultDelete<TransactionInfo>; |
1671 | |
1672 | nsTHashSet<TransactionInfo*> mBlocking; |
1673 | nsTArray<NotNull<TransactionInfo*>> mBlockingOrdered; |
1674 | |
1675 | public: |
1676 | DatabaseInfo& mDatabaseInfo; |
1677 | const nsID mBackgroundChildLoggingId; |
1678 | const nsCString mDatabaseId; |
1679 | const uint64_t mTransactionId; |
1680 | const int64_t mLoggingSerialNumber; |
1681 | const nsTArray<nsString> mObjectStoreNames; |
1682 | nsTHashSet<TransactionInfo*> mBlockedOn; |
1683 | nsTArray<nsCOMPtr<nsIRunnable>> mQueuedRunnables; |
1684 | const bool mIsWriteTransaction; |
1685 | bool mRunning; |
1686 | |
1687 | #ifdef DEBUG1 |
1688 | FlippedOnce<false> mFinished; |
1689 | #endif |
1690 | |
1691 | TransactionInfo(DatabaseInfo& aDatabaseInfo, |
1692 | const nsID& aBackgroundChildLoggingId, |
1693 | const nsACString& aDatabaseId, uint64_t aTransactionId, |
1694 | int64_t aLoggingSerialNumber, |
1695 | const nsTArray<nsString>& aObjectStoreNames, |
1696 | bool aIsWriteTransaction, |
1697 | TransactionDatabaseOperationBase* aTransactionOp); |
1698 | |
1699 | void AddBlockingTransaction(TransactionInfo& aTransactionInfo); |
1700 | |
1701 | void RemoveBlockingTransactions(); |
1702 | |
1703 | private: |
1704 | ~TransactionInfo(); |
1705 | |
1706 | void MaybeUnblock(TransactionInfo& aTransactionInfo); |
1707 | }; |
1708 | |
1709 | struct ConnectionPool::TransactionInfoPair final { |
1710 | // Multiple reading transactions can block future writes. |
1711 | nsTArray<NotNull<TransactionInfo*>> mLastBlockingWrites; |
1712 | // But only a single writing transaction can block future reads. |
1713 | Maybe<TransactionInfo&> mLastBlockingReads; |
1714 | |
1715 | #if defined(DEBUG1) || defined(NS_BUILD_REFCNT_LOGGING1) |
1716 | TransactionInfoPair(); |
1717 | ~TransactionInfoPair(); |
1718 | #endif |
1719 | }; |
1720 | |
1721 | /******************************************************************************* |
1722 | * Actor class declarations |
1723 | ******************************************************************************/ |
1724 | |
1725 | template <IDBCursorType CursorType> |
1726 | class CommonOpenOpHelper; |
1727 | template <IDBCursorType CursorType> |
1728 | class IndexOpenOpHelper; |
1729 | template <IDBCursorType CursorType> |
1730 | class ObjectStoreOpenOpHelper; |
1731 | template <IDBCursorType CursorType> |
1732 | class OpenOpHelper; |
1733 | |
1734 | class DatabaseOperationBase : public Runnable, |
1735 | public mozIStorageProgressHandler { |
1736 | template <IDBCursorType CursorType> |
1737 | friend class OpenOpHelper; |
1738 | |
1739 | protected: |
1740 | class AutoSetProgressHandler; |
1741 | |
1742 | using UniqueIndexTable = nsTHashMap<nsUint64HashKey, bool>; |
1743 | |
1744 | const nsCOMPtr<nsIEventTarget> mOwningEventTarget; |
1745 | const nsID mBackgroundChildLoggingId; |
1746 | const uint64_t mLoggingSerialNumber; |
1747 | |
1748 | private: |
1749 | nsresult mResultCode = NS_OK; |
1750 | Atomic<bool> mOperationMayProceed; |
1751 | FlippedOnce<false> mActorDestroyed; |
1752 | |
1753 | public: |
1754 | NS_DECL_ISUPPORTS_INHERITEDpublic: virtual nsresult QueryInterface(const nsIID& aIID , void** aInstancePtr) override; virtual MozExternalRefCountType AddRef(void) override; virtual MozExternalRefCountType Release (void) override; |
1755 | |
1756 | bool IsOnOwningThread() const { |
1757 | MOZ_ASSERT(mOwningEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOwningEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOwningEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOwningEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1757); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOwningEventTarget" ")"); do { *((volatile int*)__null) = 1757; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1758 | |
1759 | bool current; |
1760 | return NS_SUCCEEDED(mOwningEventTarget->IsOnCurrentThread(¤t))((bool)(__builtin_expect(!!(!NS_FAILED_impl(mOwningEventTarget ->IsOnCurrentThread(¤t))), 1))) && |
1761 | current; |
1762 | } |
1763 | |
1764 | void AssertIsOnOwningThread() const { |
1765 | MOZ_ASSERT(IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1765); AnnotateMozCrashReason("MOZ_ASSERT" "(" "IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 1765; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1766 | MOZ_ASSERT(IsOnOwningThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(IsOnOwningThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(IsOnOwningThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("IsOnOwningThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1766); AnnotateMozCrashReason("MOZ_ASSERT" "(" "IsOnOwningThread()" ")"); do { *((volatile int*)__null) = 1766; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1767 | } |
1768 | |
1769 | void NoteActorDestroyed() { |
1770 | AssertIsOnOwningThread(); |
1771 | |
1772 | mActorDestroyed.EnsureFlipped(); |
1773 | mOperationMayProceed = false; |
1774 | } |
1775 | |
1776 | bool IsActorDestroyed() const { |
1777 | AssertIsOnOwningThread(); |
1778 | |
1779 | return mActorDestroyed; |
1780 | } |
1781 | |
1782 | // May be called on any thread, but you should call IsActorDestroyed() if |
1783 | // you know you're on the background thread because it is slightly faster. |
1784 | bool OperationMayProceed() const { return mOperationMayProceed; } |
1785 | |
1786 | const nsID& BackgroundChildLoggingId() const { |
1787 | return mBackgroundChildLoggingId; |
1788 | } |
1789 | |
1790 | uint64_t LoggingSerialNumber() const { return mLoggingSerialNumber; } |
1791 | |
1792 | nsresult ResultCode() const { return mResultCode; } |
1793 | |
1794 | void SetFailureCode(nsresult aFailureCode) { |
1795 | MOZ_ASSERT(NS_SUCCEEDED(mResultCode))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode )), 1))))>::isValid, "invalid assertion condition"); if (( __builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mResultCode)), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1795); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1)))" ")"); do { *((volatile int*)__null) = 1795; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1796 | OverrideFailureCode(aFailureCode); |
1797 | } |
1798 | |
1799 | void SetFailureCodeIfUnset(nsresult aFailureCode) { |
1800 | if (NS_SUCCEEDED(mResultCode)((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1) ))) { |
1801 | OverrideFailureCode(aFailureCode); |
1802 | } |
1803 | } |
1804 | |
1805 | bool HasFailed() const { return NS_FAILED(mResultCode)((bool)(__builtin_expect(!!(NS_FAILED_impl(mResultCode)), 0)) ); } |
1806 | |
1807 | protected: |
1808 | DatabaseOperationBase(const nsID& aBackgroundChildLoggingId, |
1809 | uint64_t aLoggingSerialNumber) |
1810 | : Runnable("dom::indexedDB::DatabaseOperationBase"), |
1811 | mOwningEventTarget(GetCurrentSerialEventTarget()), |
1812 | mBackgroundChildLoggingId(aBackgroundChildLoggingId), |
1813 | mLoggingSerialNumber(aLoggingSerialNumber), |
1814 | mOperationMayProceed(true) { |
1815 | AssertIsOnOwningThread(); |
1816 | } |
1817 | |
1818 | ~DatabaseOperationBase() override { MOZ_ASSERT(mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1818); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mActorDestroyed" ")"); do { *((volatile int*)__null) = 1818; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } |
1819 | |
1820 | void OverrideFailureCode(nsresult aFailureCode) { |
1821 | MOZ_ASSERT(NS_FAILED(aFailureCode))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(NS_FAILED_impl(aFailureCode )), 0))))>::isValid, "invalid assertion condition"); if (( __builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(NS_FAILED_impl (aFailureCode)), 0)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("((bool)(__builtin_expect(!!(NS_FAILED_impl(aFailureCode)), 0)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 1821); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(NS_FAILED_impl(aFailureCode)), 0)))" ")"); do { *((volatile int*)__null) = 1821; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
1822 | |
1823 | mResultCode = aFailureCode; |
1824 | } |
1825 | |
1826 | static nsAutoCString MaybeGetBindingClauseForKeyRange( |
1827 | const Maybe<SerializedKeyRange>& aOptionalKeyRange, |
1828 | const nsACString& aKeyColumnName); |
1829 | |
1830 | static nsAutoCString GetBindingClauseForKeyRange( |
1831 | const SerializedKeyRange& aKeyRange, const nsACString& aKeyColumnName); |
1832 | |
1833 | static uint64_t ReinterpretDoubleAsUInt64(double aDouble); |
1834 | |
1835 | static nsresult BindKeyRangeToStatement(const SerializedKeyRange& aKeyRange, |
1836 | mozIStorageStatement* aStatement); |
1837 | |
1838 | static nsresult BindKeyRangeToStatement(const SerializedKeyRange& aKeyRange, |
1839 | mozIStorageStatement* aStatement, |
1840 | const nsCString& aLocale); |
1841 | |
1842 | static Result<IndexDataValuesAutoArray, nsresult> |
1843 | IndexDataValuesFromUpdateInfos(const nsTArray<IndexUpdateInfo>& aUpdateInfos, |
1844 | const UniqueIndexTable& aUniqueIndexTable); |
1845 | |
1846 | static nsresult InsertIndexTableRows( |
1847 | DatabaseConnection* aConnection, IndexOrObjectStoreId aObjectStoreId, |
1848 | const Key& aObjectStoreKey, const nsTArray<IndexDataValue>& aIndexValues); |
1849 | |
1850 | static nsresult DeleteIndexDataTableRows( |
1851 | DatabaseConnection* aConnection, const Key& aObjectStoreKey, |
1852 | const nsTArray<IndexDataValue>& aIndexValues); |
1853 | |
1854 | static nsresult DeleteObjectStoreDataTableRowsWithIndexes( |
1855 | DatabaseConnection* aConnection, IndexOrObjectStoreId aObjectStoreId, |
1856 | const Maybe<SerializedKeyRange>& aKeyRange); |
1857 | |
1858 | static nsresult UpdateIndexValues( |
1859 | DatabaseConnection* aConnection, IndexOrObjectStoreId aObjectStoreId, |
1860 | const Key& aObjectStoreKey, const nsTArray<IndexDataValue>& aIndexValues); |
1861 | |
1862 | static Result<bool, nsresult> ObjectStoreHasIndexes( |
1863 | DatabaseConnection& aConnection, IndexOrObjectStoreId aObjectStoreId); |
1864 | |
1865 | private: |
1866 | template <typename KeyTransformation> |
1867 | static nsresult MaybeBindKeyToStatement( |
1868 | const Key& aKey, mozIStorageStatement* aStatement, |
1869 | const nsACString& aParameterName, |
1870 | const KeyTransformation& aKeyTransformation); |
1871 | |
1872 | template <typename KeyTransformation> |
1873 | static nsresult BindTransformedKeyRangeToStatement( |
1874 | const SerializedKeyRange& aKeyRange, mozIStorageStatement* aStatement, |
1875 | const KeyTransformation& aKeyTransformation); |
1876 | |
1877 | // Not to be overridden by subclasses. |
1878 | NS_DECL_MOZISTORAGEPROGRESSHANDLERvirtual nsresult OnProgress(mozIStorageConnection *aConnection , bool *_retval) override; |
1879 | }; |
1880 | |
1881 | class MOZ_STACK_CLASS DatabaseOperationBase::AutoSetProgressHandler final { |
1882 | Maybe<mozIStorageConnection&> mConnection; |
1883 | #ifdef DEBUG1 |
1884 | DatabaseOperationBase* mDEBUGDatabaseOp; |
1885 | #endif |
1886 | |
1887 | public: |
1888 | AutoSetProgressHandler(); |
1889 | |
1890 | ~AutoSetProgressHandler(); |
1891 | |
1892 | nsresult Register(mozIStorageConnection& aConnection, |
1893 | DatabaseOperationBase* aDatabaseOp); |
1894 | |
1895 | void Unregister(); |
1896 | }; |
1897 | |
1898 | class TransactionDatabaseOperationBase : public DatabaseOperationBase { |
1899 | enum class InternalState { |
1900 | Initial, |
1901 | DatabaseWork, |
1902 | SendingPreprocess, |
1903 | WaitingForContinue, |
1904 | SendingResults, |
1905 | Completed |
1906 | }; |
1907 | |
1908 | InitializedOnce<const NotNull<SafeRefPtr<TransactionBase>>> mTransaction; |
1909 | // Unique request id within the context of the transaction, allocated by the |
1910 | // transaction in the content process starting from 0. Values less than 0 are |
1911 | // impossible and forbidden. Used to support the explicit commit() request. |
1912 | const int64_t mRequestId; |
1913 | InternalState mInternalState = InternalState::Initial; |
1914 | bool mWaitingForContinue = false; |
1915 | const bool mTransactionIsAborted; |
1916 | |
1917 | protected: |
1918 | const int64_t mTransactionLoggingSerialNumber; |
1919 | |
1920 | #ifdef MOZ_DIAGNOSTIC_ASSERT_ENABLED1 |
1921 | protected: |
1922 | // A check only enables when the diagnostic assert turns on. It assumes the |
1923 | // mUpdateRefcountFunction is a nullptr because the previous |
1924 | // StartTransactionOp failed on the connection thread and the next write |
1925 | // operation (e.g. ObjectstoreAddOrPutRequestOp) doesn't have enough time to |
1926 | // catch up the failure information. |
1927 | bool mAssumingPreviousOperationFail = false; |
1928 | #endif |
1929 | |
1930 | public: |
1931 | void AssertIsOnConnectionThread() const |
1932 | #ifdef DEBUG1 |
1933 | ; |
1934 | #else |
1935 | { |
1936 | } |
1937 | #endif |
1938 | |
1939 | uint64_t StartOnConnectionPool(const nsID& aBackgroundChildLoggingId, |
1940 | const nsACString& aDatabaseId, |
1941 | int64_t aLoggingSerialNumber, |
1942 | const nsTArray<nsString>& aObjectStoreNames, |
1943 | bool aIsWriteTransaction); |
1944 | |
1945 | void DispatchToConnectionPool(); |
1946 | |
1947 | TransactionBase& Transaction() { return **mTransaction; } |
1948 | |
1949 | const TransactionBase& Transaction() const { return **mTransaction; } |
1950 | |
1951 | bool IsWaitingForContinue() const { |
1952 | AssertIsOnOwningThread(); |
1953 | |
1954 | return mWaitingForContinue; |
1955 | } |
1956 | |
1957 | void NoteContinueReceived(); |
1958 | |
1959 | int64_t TransactionLoggingSerialNumber() const { |
1960 | return mTransactionLoggingSerialNumber; |
1961 | } |
1962 | |
1963 | // May be overridden by subclasses if they need to perform work on the |
1964 | // background thread before being dispatched. Returning false will kill the |
1965 | // child actors and prevent dispatch. |
1966 | virtual bool Init(TransactionBase& aTransaction); |
1967 | |
1968 | // This callback will be called on the background thread before releasing the |
1969 | // final reference to this request object. Subclasses may perform any |
1970 | // additional cleanup here but must always call the base class implementation. |
1971 | virtual void Cleanup(); |
1972 | |
1973 | protected: |
1974 | TransactionDatabaseOperationBase(SafeRefPtr<TransactionBase> aTransaction, |
1975 | int64_t aRequestId); |
1976 | |
1977 | TransactionDatabaseOperationBase(SafeRefPtr<TransactionBase> aTransaction, |
1978 | const int64_t aRequestId, |
1979 | uint64_t aLoggingSerialNumber); |
1980 | |
1981 | ~TransactionDatabaseOperationBase() override; |
1982 | |
1983 | virtual void RunOnConnectionThread(); |
1984 | |
1985 | // Must be overridden in subclasses. Called on the target thread to allow the |
1986 | // subclass to perform necessary database or file operations. A successful |
1987 | // return value will trigger a SendSuccessResult callback on the background |
1988 | // thread while a failure value will trigger a SendFailureResult callback. |
1989 | virtual nsresult DoDatabaseWork(DatabaseConnection* aConnection) = 0; |
1990 | |
1991 | // May be overriden in subclasses. Called on the background thread to decide |
1992 | // if the subclass needs to send any preprocess info to the child actor. |
1993 | virtual bool HasPreprocessInfo(); |
1994 | |
1995 | // May be overriden in subclasses. Called on the background thread to allow |
1996 | // the subclass to serialize its preprocess info and send it to the child |
1997 | // actor. A successful return value will trigger a wait for a |
1998 | // NoteContinueReceived callback on the background thread while a failure |
1999 | // value will trigger a SendFailureResult callback. |
2000 | virtual nsresult SendPreprocessInfo(); |
2001 | |
2002 | // Must be overridden in subclasses. Called on the background thread to allow |
2003 | // the subclass to serialize its results and send them to the child actor. A |
2004 | // failed return value will trigger a SendFailureResult callback. |
2005 | virtual nsresult SendSuccessResult() = 0; |
2006 | |
2007 | // Must be overridden in subclasses. Called on the background thread to allow |
2008 | // the subclass to send its failure code. Returning false will cause the |
2009 | // transaction to be aborted with aResultCode. Returning true will not cause |
2010 | // the transaction to be aborted. |
2011 | virtual bool SendFailureResult(nsresult aResultCode) = 0; |
2012 | |
2013 | #ifdef MOZ_DIAGNOSTIC_ASSERT_ENABLED1 |
2014 | auto MakeAutoSavepointCleanupHandler(DatabaseConnection& aConnection) { |
2015 | return [this, &aConnection](const auto) { |
2016 | if (!aConnection.GetUpdateRefcountFunction()) { |
2017 | mAssumingPreviousOperationFail = true; |
2018 | } |
2019 | }; |
2020 | } |
2021 | #endif |
2022 | |
2023 | private: |
2024 | void SendToConnectionPool(); |
2025 | |
2026 | void SendPreprocess(); |
2027 | |
2028 | void SendResults(); |
2029 | |
2030 | void SendPreprocessInfoOrResults(bool aSendPreprocessInfo); |
2031 | |
2032 | // Not to be overridden by subclasses. |
2033 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
2034 | }; |
2035 | |
2036 | class Factory final : public PBackgroundIDBFactoryParent, |
2037 | public AtomicSafeRefCounted<Factory> { |
2038 | nsCString mSystemLocale; |
2039 | RefPtr<DatabaseLoggingInfo> mLoggingInfo; |
2040 | |
2041 | #ifdef DEBUG1 |
2042 | bool mActorDestroyed; |
2043 | #endif |
2044 | |
2045 | // Reference counted. |
2046 | ~Factory() override; |
2047 | |
2048 | public: |
2049 | [[nodiscard]] static SafeRefPtr<Factory> Create( |
2050 | const LoggingInfo& aLoggingInfo, const nsACString& aSystemLocale); |
2051 | |
2052 | DatabaseLoggingInfo* GetLoggingInfo() const { |
2053 | AssertIsOnBackgroundThread(); |
2054 | MOZ_ASSERT(mLoggingInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLoggingInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mLoggingInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mLoggingInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2054); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLoggingInfo" ")"); do { *((volatile int*)__null) = 2054; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2055 | |
2056 | return mLoggingInfo; |
2057 | } |
2058 | |
2059 | const nsCString& GetSystemLocale() const { return mSystemLocale; } |
2060 | |
2061 | MOZ_DECLARE_REFCOUNTED_TYPENAME(mozilla::dom::indexedDB::Factory)const char* typeName() const { return "mozilla::dom::indexedDB::Factory" ; } size_t typeSize() const { return sizeof(*this); } |
2062 | MOZ_INLINE_DECL_SAFEREFCOUNTING_INHERITED(Factory, AtomicSafeRefCounted)template <typename T, ::mozilla::detail::RefCountAtomicity Atomicity> friend class ::mozilla::detail::SafeRefCounted ; virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<Factory>, "Reference-counted class " "Factory" " should not have a public destructor. " "Make this class's destructor non-public" ); nsrefcnt r = AtomicSafeRefCounted::AddRef(); if constexpr ( ::mozilla::detail::ShouldLogInheritedRefcnt<Factory>) { NS_LogAddRef((this), (r), ("Factory"), (uint32_t)(sizeof(*this ))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = AtomicSafeRefCounted::Release(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt<Factory>) { NS_LogRelease((this), (r), ("Factory")); } return r; } |
2063 | |
2064 | // Only constructed in Create(). |
2065 | Factory(RefPtr<DatabaseLoggingInfo> aLoggingInfo, |
2066 | const nsACString& aSystemLocale); |
2067 | |
2068 | // IPDL methods are only called by IPDL. |
2069 | void ActorDestroy(ActorDestroyReason aWhy) override; |
2070 | |
2071 | mozilla::ipc::IPCResult RecvDeleteMe() override; |
2072 | |
2073 | PBackgroundIDBFactoryRequestParent* AllocPBackgroundIDBFactoryRequestParent( |
2074 | const FactoryRequestParams& aParams) override; |
2075 | |
2076 | mozilla::ipc::IPCResult RecvPBackgroundIDBFactoryRequestConstructor( |
2077 | PBackgroundIDBFactoryRequestParent* aActor, |
2078 | const FactoryRequestParams& aParams) override; |
2079 | |
2080 | bool DeallocPBackgroundIDBFactoryRequestParent( |
2081 | PBackgroundIDBFactoryRequestParent* aActor) override; |
2082 | |
2083 | mozilla::ipc::IPCResult RecvGetDatabases( |
2084 | const PersistenceType& aPersistenceType, |
2085 | const PrincipalInfo& aPrincipalInfo, |
2086 | GetDatabasesResolver&& aResolve) override; |
2087 | |
2088 | private: |
2089 | Maybe<ContentParentId> GetContentParentId() const; |
2090 | }; |
2091 | |
2092 | class WaitForTransactionsHelper final : public Runnable { |
2093 | const nsCString mDatabaseId; |
2094 | nsCOMPtr<nsIRunnable> mCallback; |
2095 | |
2096 | enum class State { Initial = 0, WaitingForTransactions, Complete } mState; |
2097 | |
2098 | public: |
2099 | WaitForTransactionsHelper(const nsACString& aDatabaseId, |
2100 | nsIRunnable* aCallback) |
2101 | : Runnable("dom::indexedDB::WaitForTransactionsHelper"), |
2102 | mDatabaseId(aDatabaseId), |
2103 | mCallback(aCallback), |
2104 | mState(State::Initial) { |
2105 | AssertIsOnBackgroundThread(); |
2106 | MOZ_ASSERT(!aDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseId.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseId.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2106); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 2106; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2107 | MOZ_ASSERT(aCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2107); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCallback" ")" ); do { *((volatile int*)__null) = 2107; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2108 | } |
2109 | |
2110 | void WaitForTransactions(); |
2111 | |
2112 | NS_INLINE_DECL_REFCOUNTING_INHERITED(WaitForTransactionsHelper, Runnable)virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<WaitForTransactionsHelper>, "Reference-counted class " "WaitForTransactionsHelper" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = Runnable ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <WaitForTransactionsHelper>) { NS_LogAddRef((this), (r) , ("WaitForTransactionsHelper"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = Runnable::Release(); if constexpr (::mozilla:: detail::ShouldLogInheritedRefcnt<WaitForTransactionsHelper >) { NS_LogRelease((this), (r), ("WaitForTransactionsHelper" )); } return r; } |
2113 | |
2114 | private: |
2115 | ~WaitForTransactionsHelper() override { |
2116 | MOZ_ASSERT(!mCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2116); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mCallback" ")"); do { *((volatile int*)__null) = 2116; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2117 | MOZ_ASSERT(mState == State::Complete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Complete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Complete))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("mState == State::Complete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2117); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Complete" ")"); do { *((volatile int*)__null) = 2117; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2118 | } |
2119 | |
2120 | void MaybeWaitForTransactions(); |
2121 | |
2122 | void CallCallback(); |
2123 | |
2124 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
2125 | }; |
2126 | |
2127 | class Database final |
2128 | : public PBackgroundIDBDatabaseParent, |
2129 | public SupportsCheckedUnsafePtr<CheckIf<DiagnosticAssertEnabled>>, |
2130 | public AtomicSafeRefCounted<Database> { |
2131 | friend class VersionChangeTransaction; |
2132 | |
2133 | class StartTransactionOp; |
2134 | class UnmapBlobCallback; |
2135 | |
2136 | private: |
2137 | SafeRefPtr<Factory> mFactory; |
2138 | SafeRefPtr<FullDatabaseMetadata> mMetadata; |
2139 | SafeRefPtr<DatabaseFileManager> mFileManager; |
2140 | RefPtr<ClientDirectoryLock> mDirectoryLock; |
2141 | nsTHashSet<TransactionBase*> mTransactions; |
2142 | nsTHashMap<nsIDHashKey, SafeRefPtr<DatabaseFileInfo>> mMappedBlobs; |
2143 | RefPtr<DatabaseConnection> mConnection; |
2144 | const PrincipalInfo mPrincipalInfo; |
2145 | const Maybe<ContentParentId> mOptionalContentParentId; |
2146 | // XXX Consider changing this to ClientMetadata. |
2147 | const quota::OriginMetadata mOriginMetadata; |
2148 | const nsCString mId; |
2149 | const nsString mFilePath; |
2150 | const Maybe<const CipherKey> mKey; |
2151 | int64_t mDirectoryLockId; |
2152 | const uint32_t mTelemetryId; |
2153 | const PersistenceType mPersistenceType; |
2154 | const bool mInPrivateBrowsing; |
2155 | FlippedOnce<false> mClosed; |
2156 | FlippedOnce<false> mInvalidated; |
2157 | FlippedOnce<false> mActorWasAlive; |
2158 | FlippedOnce<false> mActorDestroyed; |
2159 | nsCOMPtr<nsIEventTarget> mBackgroundThread; |
2160 | #ifdef DEBUG1 |
2161 | bool mAllBlobsUnmapped; |
2162 | #endif |
2163 | |
2164 | public: |
2165 | // Created by OpenDatabaseOp. |
2166 | Database(SafeRefPtr<Factory> aFactory, const PrincipalInfo& aPrincipalInfo, |
2167 | const Maybe<ContentParentId>& aOptionalContentParentId, |
2168 | const quota::OriginMetadata& aOriginMetadata, uint32_t aTelemetryId, |
2169 | SafeRefPtr<FullDatabaseMetadata> aMetadata, |
2170 | SafeRefPtr<DatabaseFileManager> aFileManager, |
2171 | RefPtr<ClientDirectoryLock> aDirectoryLock, bool aInPrivateBrowsing, |
2172 | const Maybe<const CipherKey>& aMaybeKey); |
2173 | |
2174 | void AssertIsOnConnectionThread() const { |
2175 | #ifdef DEBUG1 |
2176 | // mConnection is used to cache the result from ConnectionPool's |
2177 | // GetOrCreateConnection method (potentially avoiding a lock and a hash |
2178 | // lookup). However, once the connection is closed, the task queue for the |
2179 | // given database is also destroyed, so the connection, which caches the |
2180 | // event target it was created on, is no longer reliable for asserting that |
2181 | // the current thread is the connection thread (mConnection might be reset |
2182 | // when EnsureConnection is called again, but in the meantime, we have to |
2183 | // fallback to just checking the main thread and the PBackgroud thread). |
2184 | if (mConnection && !mConnection->Closed()) { |
2185 | mConnection->AssertIsOnConnectionThread(); |
2186 | } else { |
2187 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2187); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 2187; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2188 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2188); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 2188; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2189 | MOZ_ASSERT(mInvalidated)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInvalidated)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInvalidated))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInvalidated", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2189); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInvalidated" ")"); do { *((volatile int*)__null) = 2189; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2190 | } |
2191 | #endif |
2192 | } |
2193 | |
2194 | NS_IMETHOD_(MozExternalRefCountType)virtual MozExternalRefCountType AddRef() override { |
2195 | return AtomicSafeRefCounted<Database>::AddRef(); |
2196 | } |
2197 | NS_IMETHOD_(MozExternalRefCountType)virtual MozExternalRefCountType Release() override { |
2198 | return AtomicSafeRefCounted<Database>::Release(); |
2199 | } |
2200 | |
2201 | MOZ_DECLARE_REFCOUNTED_TYPENAME(mozilla::dom::indexedDB::Database)const char* typeName() const { return "mozilla::dom::indexedDB::Database" ; } size_t typeSize() const { return sizeof(*this); } |
2202 | |
2203 | void Invalidate(); |
2204 | |
2205 | bool IsOwnedByProcess(ContentParentId aContentParentId) const { |
2206 | return mOptionalContentParentId && |
2207 | mOptionalContentParentId.value() == aContentParentId; |
2208 | } |
2209 | |
2210 | const quota::OriginMetadata& OriginMetadata() const { |
2211 | return mOriginMetadata; |
2212 | } |
2213 | |
2214 | const nsCString& Id() const { return mId; } |
2215 | |
2216 | Maybe<ClientDirectoryLock&> MaybeDirectoryLockRef() const { |
2217 | AssertIsOnBackgroundThread(); |
2218 | |
2219 | return ToMaybeRef(mDirectoryLock.get()); |
2220 | } |
2221 | |
2222 | int64_t DirectoryLockId() const { return mDirectoryLockId; } |
2223 | |
2224 | uint32_t TelemetryId() const { return mTelemetryId; } |
2225 | |
2226 | PersistenceType Type() const { return mPersistenceType; } |
2227 | |
2228 | const nsString& FilePath() const { return mFilePath; } |
2229 | |
2230 | DatabaseFileManager& GetFileManager() const { return *mFileManager; } |
2231 | |
2232 | MovingNotNull<SafeRefPtr<DatabaseFileManager>> GetFileManagerPtr() const { |
2233 | return WrapMovingNotNull(mFileManager.clonePtr()); |
2234 | } |
2235 | |
2236 | const FullDatabaseMetadata& Metadata() const { |
2237 | MOZ_ASSERT(mMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2237); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mMetadata" ")" ); do { *((volatile int*)__null) = 2237; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2238 | return *mMetadata; |
2239 | } |
2240 | |
2241 | SafeRefPtr<FullDatabaseMetadata> MetadataPtr() const { |
2242 | MOZ_ASSERT(mMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2242); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mMetadata" ")" ); do { *((volatile int*)__null) = 2242; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2243 | return mMetadata.clonePtr(); |
2244 | } |
2245 | |
2246 | PBackgroundParent* GetBackgroundParent() const { |
2247 | AssertIsOnBackgroundThread(); |
2248 | MOZ_ASSERT(!IsActorDestroyed())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsActorDestroyed())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsActorDestroyed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!IsActorDestroyed()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2248); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsActorDestroyed()" ")"); do { *((volatile int*)__null) = 2248; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2249 | |
2250 | return Manager()->Manager(); |
2251 | } |
2252 | |
2253 | DatabaseLoggingInfo* GetLoggingInfo() const { |
2254 | AssertIsOnBackgroundThread(); |
2255 | MOZ_ASSERT(mFactory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFactory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFactory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFactory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFactory" ")" ); do { *((volatile int*)__null) = 2255; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2256 | |
2257 | return mFactory->GetLoggingInfo(); |
2258 | } |
2259 | |
2260 | bool RegisterTransaction(TransactionBase& aTransaction); |
2261 | |
2262 | void UnregisterTransaction(TransactionBase& aTransaction); |
2263 | |
2264 | void SetActorAlive(); |
2265 | |
2266 | void MapBlob(const IPCBlob& aIPCBlob, SafeRefPtr<DatabaseFileInfo> aFileInfo); |
2267 | |
2268 | bool IsActorAlive() const { |
2269 | AssertIsOnBackgroundThread(); |
2270 | |
2271 | return mActorWasAlive && !mActorDestroyed; |
2272 | } |
2273 | |
2274 | bool IsActorDestroyed() const { |
2275 | AssertIsOnBackgroundThread(); |
2276 | |
2277 | return mActorWasAlive && mActorDestroyed; |
2278 | } |
2279 | |
2280 | bool IsClosed() const { |
2281 | AssertIsOnBackgroundThread(); |
2282 | |
2283 | return mClosed; |
2284 | } |
2285 | |
2286 | bool IsInvalidated() const { |
2287 | AssertIsOnBackgroundThread(); |
2288 | |
2289 | return mInvalidated; |
2290 | } |
2291 | |
2292 | nsresult EnsureConnection(); |
2293 | |
2294 | DatabaseConnection* GetConnection() const { |
2295 | #ifdef DEBUG1 |
2296 | if (mConnection) { |
2297 | mConnection->AssertIsOnConnectionThread(); |
2298 | } |
2299 | #endif |
2300 | |
2301 | return mConnection; |
2302 | } |
2303 | |
2304 | void Stringify(nsACString& aResult) const; |
2305 | |
2306 | bool IsInPrivateBrowsing() const { |
2307 | AssertIsOnBackgroundThread(); |
2308 | return mInPrivateBrowsing; |
2309 | } |
2310 | |
2311 | const Maybe<const CipherKey>& MaybeKeyRef() const { |
2312 | // This can be called on any thread, as it is const. |
2313 | MOZ_ASSERT(mKey.isSome() == mInPrivateBrowsing)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mKey.isSome() == mInPrivateBrowsing)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mKey.isSome() == mInPrivateBrowsing ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "mKey.isSome() == mInPrivateBrowsing", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2313); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mKey.isSome() == mInPrivateBrowsing" ")"); do { *((volatile int*)__null) = 2313; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2314 | return mKey; |
2315 | } |
2316 | |
2317 | ~Database() override { |
2318 | MOZ_ASSERT(mClosed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mClosed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mClosed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mClosed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2318); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mClosed" ")" ); do { *((volatile int*)__null) = 2318; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2319 | MOZ_ASSERT_IF(mActorWasAlive, mActorDestroyed)do { if (mActorWasAlive) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(mActorDestroyed)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mActorDestroyed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2319); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mActorDestroyed" ")"); do { *((volatile int*)__null) = 2319; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
2320 | |
2321 | NS_ProxyRelease("ReleaseIDBFactory", mBackgroundThread.get(), |
2322 | mFactory.forget()); |
2323 | } |
2324 | |
2325 | private: |
2326 | [[nodiscard]] SafeRefPtr<DatabaseFileInfo> GetBlob(const IPCBlob& aIPCBlob); |
2327 | |
2328 | void UnmapBlob(const nsID& aID); |
2329 | |
2330 | void UnmapAllBlobs(); |
2331 | |
2332 | bool CloseInternal(); |
2333 | |
2334 | void MaybeCloseConnection(); |
2335 | |
2336 | void ConnectionClosedCallback(); |
2337 | |
2338 | void CleanupMetadata(); |
2339 | |
2340 | // IPDL methods are only called by IPDL. |
2341 | void ActorDestroy(ActorDestroyReason aWhy) override; |
2342 | |
2343 | PBackgroundIDBDatabaseFileParent* AllocPBackgroundIDBDatabaseFileParent( |
2344 | const IPCBlob& aIPCBlob) override; |
2345 | |
2346 | bool DeallocPBackgroundIDBDatabaseFileParent( |
2347 | PBackgroundIDBDatabaseFileParent* aActor) override; |
2348 | |
2349 | already_AddRefed<PBackgroundIDBTransactionParent> |
2350 | AllocPBackgroundIDBTransactionParent( |
2351 | const nsTArray<nsString>& aObjectStoreNames, const Mode& aMode, |
2352 | const Durability& aDurability) override; |
2353 | |
2354 | mozilla::ipc::IPCResult RecvPBackgroundIDBTransactionConstructor( |
2355 | PBackgroundIDBTransactionParent* aActor, |
2356 | nsTArray<nsString>&& aObjectStoreNames, const Mode& aMode, |
2357 | const Durability& aDurability) override; |
2358 | |
2359 | mozilla::ipc::IPCResult RecvDeleteMe() override; |
2360 | |
2361 | mozilla::ipc::IPCResult RecvBlocked() override; |
2362 | |
2363 | mozilla::ipc::IPCResult RecvClose() override; |
2364 | |
2365 | template <typename T> |
2366 | static bool InvalidateAll(const nsTBaseHashSet<nsPtrHashKey<T>>& aTable); |
2367 | }; |
2368 | |
2369 | class Database::StartTransactionOp final |
2370 | : public TransactionDatabaseOperationBase { |
2371 | friend class Database; |
2372 | |
2373 | private: |
2374 | explicit StartTransactionOp(SafeRefPtr<TransactionBase> aTransaction) |
2375 | : TransactionDatabaseOperationBase(std::move(aTransaction), |
2376 | /* aRequestId */ 0, |
2377 | /* aLoggingSerialNumber */ 0) {} |
2378 | |
2379 | ~StartTransactionOp() override = default; |
2380 | |
2381 | void RunOnConnectionThread() override; |
2382 | |
2383 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
2384 | |
2385 | nsresult SendSuccessResult() override; |
2386 | |
2387 | bool SendFailureResult(nsresult aResultCode) override; |
2388 | |
2389 | void Cleanup() override; |
2390 | }; |
2391 | |
2392 | class Database::UnmapBlobCallback final |
2393 | : public RemoteLazyInputStreamParentCallback { |
2394 | SafeRefPtr<Database> mDatabase; |
2395 | nsCOMPtr<nsISerialEventTarget> mBackgroundThread; |
2396 | |
2397 | public: |
2398 | explicit UnmapBlobCallback(SafeRefPtr<Database> aDatabase) |
2399 | : mDatabase(std::move(aDatabase)), |
2400 | mBackgroundThread(GetCurrentSerialEventTarget()) { |
2401 | AssertIsOnBackgroundThread(); |
2402 | } |
2403 | |
2404 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(Database::UnmapBlobCallback, override)public: MozExternalRefCountType AddRef(void) override { static_assert (!std::is_destructible_v<Database::UnmapBlobCallback>, "Reference-counted class " "Database::UnmapBlobCallback" " should not have a public destructor. " "Make this class's destructor non-public"); do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2404); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 2404; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("Database::UnmapBlobCallback"), (uint32_t)(sizeof (*this))); return (nsrefcnt)count; } MozExternalRefCountType Release (void) override { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2404); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 2404 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("Database::UnmapBlobCallback")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public: |
2405 | |
2406 | void ActorDestroyed(const nsID& aID) override { |
2407 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2407); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2407; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2408 | mBackgroundThread->Dispatch(NS_NewRunnableFunction( |
2409 | "UnmapBlobCallback", [aID, database = std::move(mDatabase)] { |
2410 | AssertIsOnBackgroundThread(); |
2411 | database->UnmapBlob(aID); |
2412 | })); |
2413 | } |
2414 | |
2415 | private: |
2416 | ~UnmapBlobCallback() = default; |
2417 | }; |
2418 | |
2419 | /** |
2420 | * In coordination with IDBDatabase's mFileActors weak-map on the child side, a |
2421 | * long-lived mapping from a child process's live Blobs to their corresponding |
2422 | * DatabaseFileInfo in our owning database. Assists in avoiding redundant IPC |
2423 | * traffic and disk storage. This includes both: |
2424 | * - Blobs retrieved from this database and sent to the child that do not need |
2425 | * to be written to disk because they already exist on disk in this database's |
2426 | * files directory. |
2427 | * - Blobs retrieved from other databases or from anywhere else that will need |
2428 | * to be written to this database's files directory. In this case we will |
2429 | * hold a reference to its BlobImpl in mBlobImpl until we have successfully |
2430 | * written the Blob to disk. |
2431 | * |
2432 | * Relevant Blob context: Blobs sent from the parent process to child processes |
2433 | * are automatically linked back to their source BlobImpl when the child process |
2434 | * references the Blob via IPC. This is done using the internal IPCBlob |
2435 | * inputStream actor ID to DatabaseFileInfo mapping. However, when getting an |
2436 | * actor in the child process for sending an in-child-created Blob to the |
2437 | * parent process, there is (currently) no Blob machinery to automatically |
2438 | * establish and reuse a long-lived Actor. As a result, without IDB's weak-map |
2439 | * cleverness, a memory-backed Blob repeatedly sent from the child to the parent |
2440 | * would appear as a different Blob each time, requiring the Blob data to be |
2441 | * sent over IPC each time as well as potentially needing to be written to disk |
2442 | * each time. |
2443 | * |
2444 | * This object remains alive as long as there is an active child actor or an |
2445 | * ObjectStoreAddOrPutRequestOp::StoredFileInfo for a queued or active add/put |
2446 | * op is holding a reference to us. |
2447 | */ |
2448 | class DatabaseFile final : public PBackgroundIDBDatabaseFileParent { |
2449 | // mBlobImpl's ownership lifecycle: |
2450 | // - Initialized on the background thread at creation time. Then |
2451 | // responsibility is handed off to the connection thread. |
2452 | // - Checked and used by the connection thread to generate a stream to write |
2453 | // the blob to disk by an add/put operation. |
2454 | // - Cleared on the connection thread once the file has successfully been |
2455 | // written to disk. |
2456 | InitializedOnce<const RefPtr<BlobImpl>> mBlobImpl; |
2457 | const SafeRefPtr<DatabaseFileInfo> mFileInfo; |
2458 | |
2459 | public: |
2460 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(mozilla::dom::indexedDB::DatabaseFile)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<mozilla::dom::indexedDB::DatabaseFile >, "Reference-counted class " "mozilla::dom::indexedDB::DatabaseFile" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2460); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 2460; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("mozilla::dom::indexedDB::DatabaseFile"), (uint32_t )(sizeof(*this))); return (nsrefcnt)count; } MozExternalRefCountType Release(void) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2460); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 2460 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("mozilla::dom::indexedDB::DatabaseFile")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public:; |
2461 | |
2462 | const DatabaseFileInfo& GetFileInfo() const { |
2463 | AssertIsOnBackgroundThread(); |
2464 | |
2465 | return *mFileInfo; |
2466 | } |
2467 | |
2468 | SafeRefPtr<DatabaseFileInfo> GetFileInfoPtr() const { |
2469 | AssertIsOnBackgroundThread(); |
2470 | |
2471 | return mFileInfo.clonePtr(); |
2472 | } |
2473 | |
2474 | /** |
2475 | * If mBlobImpl is non-null (implying the contents of this file have not yet |
2476 | * been written to disk), then return an input stream. Otherwise, if mBlobImpl |
2477 | * is null (because the contents have been written to disk), returns null. |
2478 | */ |
2479 | [[nodiscard]] nsCOMPtr<nsIInputStream> GetInputStream(ErrorResult& rv) const; |
2480 | |
2481 | /** |
2482 | * To be called upon successful copying of the stream GetInputStream() |
2483 | * returned so that we won't try and redundantly write the file to disk in the |
2484 | * future. This is a separate step from GetInputStream() because |
2485 | * the write could fail due to quota errors that happen now but that might |
2486 | * not happen in a future attempt. |
2487 | */ |
2488 | void WriteSucceededClearBlobImpl() { |
2489 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2489); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 2489; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2490 | |
2491 | MOZ_ASSERT(*mBlobImpl)do { static_assert( mozilla::detail::AssertionConditionType< decltype(*mBlobImpl)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(*mBlobImpl))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("*mBlobImpl", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2491); AnnotateMozCrashReason("MOZ_ASSERT" "(" "*mBlobImpl" ")"); do { *((volatile int*)__null) = 2491; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2492 | mBlobImpl.destroy(); |
2493 | } |
2494 | |
2495 | public: |
2496 | // Called when sending to the child. |
2497 | explicit DatabaseFile(SafeRefPtr<DatabaseFileInfo> aFileInfo) |
2498 | : mBlobImpl{nullptr}, mFileInfo(std::move(aFileInfo)) { |
2499 | AssertIsOnBackgroundThread(); |
2500 | MOZ_ASSERT(mFileInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2500); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileInfo" ")" ); do { *((volatile int*)__null) = 2500; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2501 | } |
2502 | |
2503 | // Called when receiving from the child. |
2504 | DatabaseFile(RefPtr<BlobImpl> aBlobImpl, |
2505 | SafeRefPtr<DatabaseFileInfo> aFileInfo) |
2506 | : mBlobImpl(std::move(aBlobImpl)), mFileInfo(std::move(aFileInfo)) { |
2507 | AssertIsOnBackgroundThread(); |
2508 | MOZ_ASSERT(*mBlobImpl)do { static_assert( mozilla::detail::AssertionConditionType< decltype(*mBlobImpl)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(*mBlobImpl))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("*mBlobImpl", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2508); AnnotateMozCrashReason("MOZ_ASSERT" "(" "*mBlobImpl" ")"); do { *((volatile int*)__null) = 2508; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2509 | MOZ_ASSERT(mFileInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2509); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileInfo" ")" ); do { *((volatile int*)__null) = 2509; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2510 | } |
2511 | |
2512 | private: |
2513 | ~DatabaseFile() override = default; |
2514 | |
2515 | void ActorDestroy(ActorDestroyReason aWhy) override { |
2516 | AssertIsOnBackgroundThread(); |
2517 | } |
2518 | }; |
2519 | |
2520 | nsCOMPtr<nsIInputStream> DatabaseFile::GetInputStream(ErrorResult& rv) const { |
2521 | // We should only be called from our DB connection thread, not the background |
2522 | // thread. |
2523 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2523); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 2523; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2524 | |
2525 | // If we were constructed without a BlobImpl, or WriteSucceededClearBlobImpl |
2526 | // was already called, return nullptr. |
2527 | if (!mBlobImpl || !*mBlobImpl) { |
2528 | return nullptr; |
2529 | } |
2530 | |
2531 | nsCOMPtr<nsIInputStream> inputStream; |
2532 | (*mBlobImpl)->CreateInputStream(getter_AddRefs(inputStream), rv); |
2533 | if (rv.Failed()) { |
2534 | return nullptr; |
2535 | } |
2536 | |
2537 | return inputStream; |
2538 | } |
2539 | |
2540 | class TransactionBase : public AtomicSafeRefCounted<TransactionBase> { |
2541 | friend class CursorBase; |
2542 | |
2543 | template <IDBCursorType CursorType> |
2544 | friend class Cursor; |
2545 | |
2546 | class CommitOp; |
2547 | |
2548 | protected: |
2549 | using Mode = IDBTransaction::Mode; |
2550 | using Durability = IDBTransaction::Durability; |
2551 | |
2552 | private: |
2553 | const SafeRefPtr<Database> mDatabase; |
2554 | nsTArray<SafeRefPtr<FullObjectStoreMetadata>> |
2555 | mModifiedAutoIncrementObjectStoreMetadataArray; |
2556 | LazyInitializedOnceNotNull<const uint64_t> mTransactionId; |
2557 | const nsCString mDatabaseId; |
2558 | const int64_t mLoggingSerialNumber; |
2559 | uint64_t mActiveRequestCount; |
2560 | Atomic<bool> mInvalidatedOnAnyThread; |
2561 | const Mode mMode; |
2562 | const Durability mDurability; |
2563 | FlippedOnce<false> mInitialized; |
2564 | FlippedOnce<false> mHasBeenActiveOnConnectionThread; |
2565 | FlippedOnce<false> mActorDestroyed; |
2566 | FlippedOnce<false> mInvalidated; |
2567 | |
2568 | protected: |
2569 | nsresult mResultCode; |
2570 | FlippedOnce<false> mCommitOrAbortReceived; |
2571 | FlippedOnce<false> mCommittedOrAborted; |
2572 | FlippedOnce<false> mForceAborted; |
2573 | LazyInitializedOnce<const Maybe<int64_t>> mLastRequestBeforeCommit; |
2574 | Maybe<int64_t> mLastFailedRequest; |
2575 | |
2576 | public: |
2577 | void AssertIsOnConnectionThread() const { |
2578 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2578); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2578; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2579 | mDatabase->AssertIsOnConnectionThread(); |
2580 | } |
2581 | |
2582 | bool IsActorDestroyed() const { |
2583 | AssertIsOnBackgroundThread(); |
2584 | |
2585 | return mActorDestroyed; |
2586 | } |
2587 | |
2588 | // Must be called on the background thread. |
2589 | bool IsInvalidated() const { |
2590 | MOZ_ASSERT(IsOnBackgroundThread(), "Use IsInvalidatedOnAnyThread()")do { static_assert( mozilla::detail::AssertionConditionType< decltype(IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("IsOnBackgroundThread()" " (" "Use IsInvalidatedOnAnyThread()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2590); AnnotateMozCrashReason("MOZ_ASSERT" "(" "IsOnBackgroundThread()" ") (" "Use IsInvalidatedOnAnyThread()" ")"); do { *((volatile int*)__null) = 2590; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); |
2591 | MOZ_ASSERT_IF(mInvalidated, NS_FAILED(mResultCode))do { if (mInvalidated) { do { static_assert( mozilla::detail:: AssertionConditionType<decltype(((bool)(__builtin_expect(! !(NS_FAILED_impl(mResultCode)), 0))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( NS_FAILED_impl(mResultCode)), 0)))))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(NS_FAILED_impl(mResultCode)), 0)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2591); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(NS_FAILED_impl(mResultCode)), 0)))" ")"); do { *((volatile int*)__null) = 2591; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
2592 | |
2593 | return mInvalidated; |
2594 | } |
2595 | |
2596 | // May be called on any thread, but is more expensive than IsInvalidated(). |
2597 | bool IsInvalidatedOnAnyThread() const { return mInvalidatedOnAnyThread; } |
2598 | |
2599 | void Init(const uint64_t aTransactionId) { |
2600 | AssertIsOnBackgroundThread(); |
2601 | MOZ_ASSERT(aTransactionId)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aTransactionId)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aTransactionId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aTransactionId" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2601); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aTransactionId" ")"); do { *((volatile int*)__null) = 2601; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2602 | |
2603 | mTransactionId.init(aTransactionId); |
2604 | mInitialized.Flip(); |
2605 | } |
2606 | |
2607 | void SetActiveOnConnectionThread() { |
2608 | AssertIsOnConnectionThread(); |
2609 | mHasBeenActiveOnConnectionThread.Flip(); |
2610 | } |
2611 | |
2612 | MOZ_DECLARE_REFCOUNTED_TYPENAME(mozilla::dom::indexedDB::TransactionBase)const char* typeName() const { return "mozilla::dom::indexedDB::TransactionBase" ; } size_t typeSize() const { return sizeof(*this); } |
2613 | |
2614 | void Abort(nsresult aResultCode, bool aForce); |
2615 | |
2616 | uint64_t TransactionId() const { return *mTransactionId; } |
2617 | |
2618 | const nsACString& DatabaseId() const { return mDatabaseId; } |
2619 | |
2620 | Mode GetMode() const { return mMode; } |
2621 | |
2622 | Durability GetDurability() const { return mDurability; } |
2623 | |
2624 | const Database& GetDatabase() const { |
2625 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2625); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2625; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2626 | |
2627 | return *mDatabase; |
2628 | } |
2629 | |
2630 | Database& GetMutableDatabase() const { |
2631 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2631); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2631; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2632 | |
2633 | return *mDatabase; |
2634 | } |
2635 | |
2636 | SafeRefPtr<Database> GetDatabasePtr() const { |
2637 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2637); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2637; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2638 | |
2639 | return mDatabase.clonePtr(); |
2640 | } |
2641 | |
2642 | DatabaseLoggingInfo* GetLoggingInfo() const { |
2643 | AssertIsOnBackgroundThread(); |
2644 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2644); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2644; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2645 | |
2646 | return mDatabase->GetLoggingInfo(); |
2647 | } |
2648 | |
2649 | int64_t LoggingSerialNumber() const { return mLoggingSerialNumber; } |
2650 | |
2651 | bool IsAborted() const { |
2652 | AssertIsOnBackgroundThread(); |
2653 | |
2654 | return NS_FAILED(mResultCode)((bool)(__builtin_expect(!!(NS_FAILED_impl(mResultCode)), 0)) ); |
2655 | } |
2656 | |
2657 | [[nodiscard]] SafeRefPtr<FullObjectStoreMetadata> GetMetadataForObjectStoreId( |
2658 | IndexOrObjectStoreId aObjectStoreId) const; |
2659 | |
2660 | [[nodiscard]] SafeRefPtr<FullIndexMetadata> GetMetadataForIndexId( |
2661 | FullObjectStoreMetadata& aObjectStoreMetadata, |
2662 | IndexOrObjectStoreId aIndexId) const; |
2663 | |
2664 | PBackgroundParent* GetBackgroundParent() const { |
2665 | AssertIsOnBackgroundThread(); |
2666 | MOZ_ASSERT(!IsActorDestroyed())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsActorDestroyed())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsActorDestroyed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!IsActorDestroyed()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2666); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsActorDestroyed()" ")"); do { *((volatile int*)__null) = 2666; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2667 | |
2668 | return GetDatabase().GetBackgroundParent(); |
2669 | } |
2670 | |
2671 | void NoteModifiedAutoIncrementObjectStore( |
2672 | const SafeRefPtr<FullObjectStoreMetadata>& aMetadata); |
2673 | |
2674 | void ForgetModifiedAutoIncrementObjectStore( |
2675 | FullObjectStoreMetadata& aMetadata); |
2676 | |
2677 | void NoteActiveRequest(); |
2678 | |
2679 | void NoteFinishedRequest(int64_t aRequestId, nsresult aResultCode); |
2680 | |
2681 | void Invalidate(); |
2682 | |
2683 | virtual ~TransactionBase(); |
2684 | |
2685 | protected: |
2686 | TransactionBase(SafeRefPtr<Database> aDatabase, Mode aMode, |
2687 | Durability aDurability); |
2688 | |
2689 | void NoteActorDestroyed() { |
2690 | AssertIsOnBackgroundThread(); |
2691 | |
2692 | mActorDestroyed.Flip(); |
2693 | } |
2694 | |
2695 | #ifdef DEBUG1 |
2696 | // Only called by VersionChangeTransaction. |
2697 | void FakeActorDestroyed() { mActorDestroyed.EnsureFlipped(); } |
2698 | #endif |
2699 | |
2700 | mozilla::ipc::IPCResult RecvCommit(IProtocol* aActor, |
2701 | const Maybe<int64_t> aLastRequest); |
2702 | |
2703 | mozilla::ipc::IPCResult RecvAbort(IProtocol* aActor, nsresult aResultCode); |
2704 | |
2705 | void MaybeCommitOrAbort() { |
2706 | AssertIsOnBackgroundThread(); |
2707 | |
2708 | // If we've already committed or aborted then there's nothing else to do. |
2709 | if (mCommittedOrAborted) { |
2710 | return; |
2711 | } |
2712 | |
2713 | // If there are active requests then we have to wait for those requests to |
2714 | // complete (see NoteFinishedRequest). |
2715 | if (mActiveRequestCount) { |
2716 | return; |
2717 | } |
2718 | |
2719 | // If we haven't yet received a commit or abort message then there could be |
2720 | // additional requests coming so we should wait unless we're being forced to |
2721 | // abort. |
2722 | if (!mCommitOrAbortReceived && !mForceAborted) { |
2723 | return; |
2724 | } |
2725 | |
2726 | CommitOrAbort(); |
2727 | } |
2728 | |
2729 | PBackgroundIDBRequestParent* AllocRequest(const int64_t aRequestId, |
2730 | RequestParams&& aParams, |
2731 | bool aTrustParams); |
2732 | |
2733 | bool StartRequest(PBackgroundIDBRequestParent* aActor); |
2734 | |
2735 | bool DeallocRequest(PBackgroundIDBRequestParent* aActor); |
2736 | |
2737 | already_AddRefed<PBackgroundIDBCursorParent> AllocCursor( |
2738 | const OpenCursorParams& aParams, bool aTrustParams); |
2739 | |
2740 | bool StartCursor(PBackgroundIDBCursorParent* aActor, const int64_t aRequestId, |
2741 | const OpenCursorParams& aParams); |
2742 | |
2743 | virtual void UpdateMetadata(nsresult aResult) {} |
2744 | |
2745 | virtual void SendCompleteNotification(nsresult aResult) = 0; |
2746 | |
2747 | private: |
2748 | bool VerifyRequestParams(const RequestParams& aParams) const; |
2749 | |
2750 | bool VerifyRequestParams(const SerializedKeyRange& aParams) const; |
2751 | |
2752 | bool VerifyRequestParams(const ObjectStoreAddPutParams& aParams) const; |
2753 | |
2754 | bool VerifyRequestParams(const Maybe<SerializedKeyRange>& aParams) const; |
2755 | |
2756 | void CommitOrAbort(); |
2757 | }; |
2758 | |
2759 | class TransactionBase::CommitOp final : public DatabaseOperationBase, |
2760 | public ConnectionPool::FinishCallback { |
2761 | friend class TransactionBase; |
2762 | |
2763 | SafeRefPtr<TransactionBase> mTransaction; |
2764 | nsresult mResultCode; ///< TODO: There is also a mResultCode in |
2765 | ///< DatabaseOperationBase. Is there a reason not to |
2766 | ///< use that? At least a more specific name should be |
2767 | ///< given to this one. |
2768 | |
2769 | private: |
2770 | CommitOp(SafeRefPtr<TransactionBase> aTransaction, nsresult aResultCode); |
2771 | |
2772 | ~CommitOp() override = default; |
2773 | |
2774 | // Writes new autoIncrement counts to database. |
2775 | nsresult WriteAutoIncrementCounts(); |
2776 | |
2777 | // Updates counts after a database activity has finished. |
2778 | void CommitOrRollbackAutoIncrementCounts(); |
2779 | |
2780 | void AssertForeignKeyConsistency(DatabaseConnection* aConnection) |
2781 | #ifdef DEBUG1 |
2782 | ; |
2783 | #else |
2784 | { |
2785 | } |
2786 | #endif |
2787 | |
2788 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
2789 | |
2790 | void TransactionFinishedBeforeUnblock() override; |
2791 | |
2792 | void TransactionFinishedAfterUnblock() override; |
2793 | |
2794 | public: |
2795 | // We need to declare all of nsISupports, because FinishCallback has |
2796 | // a pure-virtual nsISupports declaration. |
2797 | NS_DECL_ISUPPORTS_INHERITEDpublic: virtual nsresult QueryInterface(const nsIID& aIID , void** aInstancePtr) override; virtual MozExternalRefCountType AddRef(void) override; virtual MozExternalRefCountType Release (void) override; |
2798 | }; |
2799 | |
2800 | class NormalTransaction final : public TransactionBase, |
2801 | public PBackgroundIDBTransactionParent { |
2802 | nsTArray<SafeRefPtr<FullObjectStoreMetadata>> mObjectStores; |
2803 | |
2804 | // Reference counted. |
2805 | ~NormalTransaction() override = default; |
2806 | |
2807 | bool IsSameProcessActor(); |
2808 | |
2809 | // Only called by TransactionBase. |
2810 | void SendCompleteNotification(nsresult aResult) override; |
2811 | |
2812 | // IPDL methods are only called by IPDL. |
2813 | void ActorDestroy(ActorDestroyReason aWhy) override; |
2814 | |
2815 | mozilla::ipc::IPCResult RecvDeleteMe() override; |
2816 | |
2817 | mozilla::ipc::IPCResult RecvCommit( |
2818 | const Maybe<int64_t>& aLastRequest) override; |
2819 | |
2820 | mozilla::ipc::IPCResult RecvAbort(const nsresult& aResultCode) override; |
2821 | |
2822 | PBackgroundIDBRequestParent* AllocPBackgroundIDBRequestParent( |
2823 | const int64_t& aRequestId, const RequestParams& aParams) override; |
2824 | |
2825 | mozilla::ipc::IPCResult RecvPBackgroundIDBRequestConstructor( |
2826 | PBackgroundIDBRequestParent* aActor, const int64_t& aRequestId, |
2827 | const RequestParams& aParams) override; |
2828 | |
2829 | bool DeallocPBackgroundIDBRequestParent( |
2830 | PBackgroundIDBRequestParent* aActor) override; |
2831 | |
2832 | already_AddRefed<PBackgroundIDBCursorParent> AllocPBackgroundIDBCursorParent( |
2833 | const int64_t& aRequestId, const OpenCursorParams& aParams) override; |
2834 | |
2835 | mozilla::ipc::IPCResult RecvPBackgroundIDBCursorConstructor( |
2836 | PBackgroundIDBCursorParent* aActor, const int64_t& aRequestId, |
2837 | const OpenCursorParams& aParams) override; |
2838 | |
2839 | public: |
2840 | // This constructor is only called by Database. |
2841 | NormalTransaction( |
2842 | SafeRefPtr<Database> aDatabase, TransactionBase::Mode aMode, |
2843 | TransactionBase::Durability aDurability, |
2844 | nsTArray<SafeRefPtr<FullObjectStoreMetadata>>&& aObjectStores); |
2845 | |
2846 | MOZ_INLINE_DECL_SAFEREFCOUNTING_INHERITED(NormalTransaction, TransactionBase)template <typename T, ::mozilla::detail::RefCountAtomicity Atomicity> friend class ::mozilla::detail::SafeRefCounted ; virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<NormalTransaction>, "Reference-counted class " "NormalTransaction" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = TransactionBase ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <NormalTransaction>) { NS_LogAddRef((this), (r), ("NormalTransaction" ), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = TransactionBase::Release() ; if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt< NormalTransaction>) { NS_LogRelease((this), (r), ("NormalTransaction" )); } return r; } |
2847 | }; |
2848 | |
2849 | class VersionChangeTransaction final |
2850 | : public TransactionBase, |
2851 | public PBackgroundIDBVersionChangeTransactionParent { |
2852 | friend class OpenDatabaseOp; |
2853 | |
2854 | RefPtr<OpenDatabaseOp> mOpenDatabaseOp; |
2855 | SafeRefPtr<FullDatabaseMetadata> mOldMetadata; |
2856 | |
2857 | FlippedOnce<false> mActorWasAlive; |
2858 | |
2859 | public: |
2860 | // Only called by OpenDatabaseOp. |
2861 | explicit VersionChangeTransaction(OpenDatabaseOp* aOpenDatabaseOp); |
2862 | |
2863 | MOZ_INLINE_DECL_SAFEREFCOUNTING_INHERITED(VersionChangeTransaction,template <typename T, ::mozilla::detail::RefCountAtomicity Atomicity> friend class ::mozilla::detail::SafeRefCounted ; virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<VersionChangeTransaction>, "Reference-counted class " "VersionChangeTransaction" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = TransactionBase ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <VersionChangeTransaction>) { NS_LogAddRef((this), (r), ("VersionChangeTransaction"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = TransactionBase::Release(); if constexpr (::mozilla::detail ::ShouldLogInheritedRefcnt<VersionChangeTransaction>) { NS_LogRelease((this), (r), ("VersionChangeTransaction")); } return r; } |
2864 | TransactionBase)template <typename T, ::mozilla::detail::RefCountAtomicity Atomicity> friend class ::mozilla::detail::SafeRefCounted ; virtual MozExternalRefCountType AddRef() override { static_assert (!std::is_destructible_v<VersionChangeTransaction>, "Reference-counted class " "VersionChangeTransaction" " should not have a public destructor. " "Make this class's destructor non-public"); nsrefcnt r = TransactionBase ::AddRef(); if constexpr (::mozilla::detail::ShouldLogInheritedRefcnt <VersionChangeTransaction>) { NS_LogAddRef((this), (r), ("VersionChangeTransaction"), (uint32_t)(sizeof(*this))); } return r; } virtual MozExternalRefCountType Release() override { nsrefcnt r = TransactionBase::Release(); if constexpr (::mozilla::detail ::ShouldLogInheritedRefcnt<VersionChangeTransaction>) { NS_LogRelease((this), (r), ("VersionChangeTransaction")); } return r; } |
2865 | |
2866 | private: |
2867 | // Reference counted. |
2868 | ~VersionChangeTransaction() override; |
2869 | |
2870 | bool IsSameProcessActor(); |
2871 | |
2872 | // Only called by OpenDatabaseOp. |
2873 | bool CopyDatabaseMetadata(); |
2874 | |
2875 | void SetActorAlive(); |
2876 | |
2877 | // Only called by TransactionBase. |
2878 | void UpdateMetadata(nsresult aResult) override; |
2879 | |
2880 | // Only called by TransactionBase. |
2881 | void SendCompleteNotification(nsresult aResult) override; |
2882 | |
2883 | // IPDL methods are only called by IPDL. |
2884 | void ActorDestroy(ActorDestroyReason aWhy) override; |
2885 | |
2886 | mozilla::ipc::IPCResult RecvDeleteMe() override; |
2887 | |
2888 | mozilla::ipc::IPCResult RecvCommit( |
2889 | const Maybe<int64_t>& aLastRequest) override; |
2890 | |
2891 | mozilla::ipc::IPCResult RecvAbort(const nsresult& aResultCode) override; |
2892 | |
2893 | mozilla::ipc::IPCResult RecvCreateObjectStore( |
2894 | const ObjectStoreMetadata& aMetadata) override; |
2895 | |
2896 | mozilla::ipc::IPCResult RecvDeleteObjectStore( |
2897 | const IndexOrObjectStoreId& aObjectStoreId) override; |
2898 | |
2899 | mozilla::ipc::IPCResult RecvRenameObjectStore( |
2900 | const IndexOrObjectStoreId& aObjectStoreId, |
2901 | const nsAString& aName) override; |
2902 | |
2903 | mozilla::ipc::IPCResult RecvCreateIndex( |
2904 | const IndexOrObjectStoreId& aObjectStoreId, |
2905 | const IndexMetadata& aMetadata) override; |
2906 | |
2907 | mozilla::ipc::IPCResult RecvDeleteIndex( |
2908 | const IndexOrObjectStoreId& aObjectStoreId, |
2909 | const IndexOrObjectStoreId& aIndexId) override; |
2910 | |
2911 | mozilla::ipc::IPCResult RecvRenameIndex( |
2912 | const IndexOrObjectStoreId& aObjectStoreId, |
2913 | const IndexOrObjectStoreId& aIndexId, const nsAString& aName) override; |
2914 | |
2915 | PBackgroundIDBRequestParent* AllocPBackgroundIDBRequestParent( |
2916 | const int64_t& aRequestId, const RequestParams& aParams) override; |
2917 | |
2918 | mozilla::ipc::IPCResult RecvPBackgroundIDBRequestConstructor( |
2919 | PBackgroundIDBRequestParent* aActor, const int64_t& aRequestId, |
2920 | const RequestParams& aParams) override; |
2921 | |
2922 | bool DeallocPBackgroundIDBRequestParent( |
2923 | PBackgroundIDBRequestParent* aActor) override; |
2924 | |
2925 | already_AddRefed<PBackgroundIDBCursorParent> AllocPBackgroundIDBCursorParent( |
2926 | const int64_t& aRequestId, const OpenCursorParams& aParams) override; |
2927 | |
2928 | mozilla::ipc::IPCResult RecvPBackgroundIDBCursorConstructor( |
2929 | PBackgroundIDBCursorParent* aActor, const int64_t& aRequestId, |
2930 | const OpenCursorParams& aParams) override; |
2931 | }; |
2932 | |
2933 | class FactoryOp |
2934 | : public DatabaseOperationBase, |
2935 | public SupportsCheckedUnsafePtr<CheckIf<DiagnosticAssertEnabled>> { |
2936 | public: |
2937 | struct MaybeBlockedDatabaseInfo final { |
2938 | SafeRefPtr<Database> mDatabase; |
2939 | bool mBlocked; |
2940 | |
2941 | MaybeBlockedDatabaseInfo(MaybeBlockedDatabaseInfo&&) = default; |
2942 | MaybeBlockedDatabaseInfo& operator=(MaybeBlockedDatabaseInfo&&) = default; |
2943 | |
2944 | MOZ_IMPLICIT MaybeBlockedDatabaseInfo(SafeRefPtr<Database> aDatabase) |
2945 | : mDatabase(std::move(aDatabase)), mBlocked(false) { |
2946 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 2946); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 2946; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
2947 | |
2948 | MOZ_COUNT_CTOR(FactoryOp::MaybeBlockedDatabaseInfo)do { static_assert(std::is_class_v<FactoryOp::MaybeBlockedDatabaseInfo >, "Token '" "FactoryOp::MaybeBlockedDatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, FactoryOp:: MaybeBlockedDatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "FactoryOp::MaybeBlockedDatabaseInfo" , sizeof(*this)); } while (0); |
2949 | } |
2950 | |
2951 | ~MaybeBlockedDatabaseInfo() { |
2952 | MOZ_COUNT_DTOR(FactoryOp::MaybeBlockedDatabaseInfo)do { static_assert(std::is_class_v<FactoryOp::MaybeBlockedDatabaseInfo >, "Token '" "FactoryOp::MaybeBlockedDatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, FactoryOp:: MaybeBlockedDatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "FactoryOp::MaybeBlockedDatabaseInfo" , sizeof(*this)); } while (0); |
2953 | } |
2954 | |
2955 | bool operator==(const Database* aOther) const { |
2956 | return mDatabase == aOther; |
2957 | } |
2958 | |
2959 | Database* operator->() const& MOZ_NO_ADDREF_RELEASE_ON_RETURN { |
2960 | return mDatabase.unsafeGetRawPtr(); |
2961 | } |
2962 | }; |
2963 | |
2964 | protected: |
2965 | enum class State { |
2966 | // Just created on the PBackground thread, dispatched to the current thread. |
2967 | // Next step is either SendingResults if opening initialization failed, or |
2968 | // DirectoryOpenPending if the opening initialization succeeded. |
2969 | Initial, |
2970 | |
2971 | // Waiting for directory open allowed on the PBackground thread. The next |
2972 | // step is either SendingResults if directory lock failed to acquire, or |
2973 | // DirectoryWorkOpen if the factory operation is not tied up to a specific |
2974 | // database, or DatabaseOpenPending otherwise. |
2975 | DirectoryOpenPending, |
2976 | |
2977 | // Waiting to do/doing directory work on the QuotaManager IO thread. Its |
2978 | // next step is DirectoryWorkDone if directory work was successful or |
2979 | // SendingResults if directory work failed. |
2980 | DirectoryWorkOpen, |
2981 | |
2982 | // Checking if database work can be started. If the database is not blocked |
2983 | // by other factory operations then the next step is DatabaseWorkOpen. |
2984 | // Otherwise the next step is DatabaseOpenPending. |
2985 | DirectoryWorkDone, |
2986 | |
2987 | // Waiting for database open allowed on the PBackground thread. The next |
2988 | // step is DatabaseWorkOpen. |
2989 | DatabaseOpenPending, |
2990 | |
2991 | // Waiting to do/doing work on the QuotaManager IO thread. Its next step is |
2992 | // either BeginVersionChange if the requested version doesn't match the |
2993 | // existing database version or SendingResults if the versions match. |
2994 | DatabaseWorkOpen, |
2995 | |
2996 | // Starting a version change transaction or deleting a database on the |
2997 | // PBackground thread. We need to notify other databases that a version |
2998 | // change is about to happen, and maybe tell the request that a version |
2999 | // change has been blocked. If databases are notified then the next step is |
3000 | // WaitingForOtherDatabasesToClose. Otherwise the next step is |
3001 | // WaitingForTransactionsToComplete. |
3002 | BeginVersionChange, |
3003 | |
3004 | // Waiting for other databases to close on the PBackground thread. This |
3005 | // state may persist until all databases are closed. The next state is |
3006 | // WaitingForTransactionsToComplete. |
3007 | WaitingForOtherDatabasesToClose, |
3008 | |
3009 | // Waiting for all transactions that could interfere with this operation to |
3010 | // complete on the PBackground thread. Next state is |
3011 | // DatabaseWorkVersionChange. |
3012 | WaitingForTransactionsToComplete, |
3013 | |
3014 | // Waiting to do/doing work on the "work thread". This involves waiting for |
3015 | // the VersionChangeOp (OpenDatabaseOp and DeleteDatabaseOp each have a |
3016 | // different implementation) to do its work. If the VersionChangeOp is |
3017 | // OpenDatabaseOp and it succeeded then the next state is |
3018 | // DatabaseWorkVersionUpdate. Otherwise the next step is SendingResults. |
3019 | DatabaseWorkVersionChange, |
3020 | |
3021 | // Waiting to do/doing finalization work on the QuotaManager IO thread. |
3022 | // Eventually the state will transition to SendingResults. |
3023 | DatabaseWorkVersionUpdate, |
3024 | |
3025 | // Waiting to send/sending results on the PBackground thread. Next step is |
3026 | // Completed. |
3027 | SendingResults, |
3028 | |
3029 | // All done. |
3030 | Completed |
3031 | }; |
3032 | |
3033 | // Must be released on the background thread! |
3034 | SafeRefPtr<Factory> mFactory; |
3035 | |
3036 | Maybe<ContentParentId> mContentParentId; |
3037 | |
3038 | // Must be released on the main thread! |
3039 | RefPtr<ClientDirectoryLock> mDirectoryLock; |
3040 | |
3041 | nsTArray<NotNull<RefPtr<FactoryOp>>> mBlocking; |
3042 | nsTArray<NotNull<RefPtr<FactoryOp>>> mBlockedOn; |
3043 | |
3044 | nsTArray<MaybeBlockedDatabaseInfo> mMaybeBlockedDatabases; |
3045 | |
3046 | const PrincipalInfo mPrincipalInfo; |
3047 | OriginMetadata mOriginMetadata; |
3048 | Maybe<nsString> mDatabaseName; |
3049 | Maybe<nsCString> mDatabaseId; |
3050 | Maybe<nsString> mDatabaseFilePath; |
3051 | int64_t mDirectoryLockId; |
3052 | const PersistenceType mPersistenceType; |
3053 | State mState; |
3054 | bool mWaitingForPermissionRetry; |
3055 | bool mEnforcingQuota; |
3056 | const bool mDeleting; |
3057 | FlippedOnce<false> mInPrivateBrowsing; |
3058 | |
3059 | public: |
3060 | const nsACString& Origin() const { |
3061 | AssertIsOnOwningThread(); |
3062 | |
3063 | return mOriginMetadata.mOrigin; |
3064 | } |
3065 | |
3066 | const Maybe<nsString>& DatabaseNameRef() const { |
3067 | AssertIsOnOwningThread(); |
3068 | |
3069 | return mDatabaseName; |
3070 | } |
3071 | |
3072 | bool DatabaseFilePathIsKnown() const { |
3073 | AssertIsOnOwningThread(); |
3074 | |
3075 | return mDatabaseFilePath.isSome(); |
3076 | } |
3077 | |
3078 | const nsAString& DatabaseFilePath() const { |
3079 | AssertIsOnOwningThread(); |
3080 | MOZ_ASSERT(mDatabaseFilePath)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabaseFilePath)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabaseFilePath))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabaseFilePath" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3080); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabaseFilePath" ")"); do { *((volatile int*)__null) = 3080; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3081 | |
3082 | return mDatabaseFilePath.ref(); |
3083 | } |
3084 | |
3085 | nsresult DispatchThisAfterProcessingCurrentEvent( |
3086 | nsCOMPtr<nsIEventTarget> aEventTarget); |
3087 | |
3088 | void NoteDatabaseBlocked(Database* aDatabase); |
3089 | |
3090 | void NoteDatabaseClosed(Database* aDatabase); |
3091 | |
3092 | #ifdef DEBUG1 |
3093 | bool HasBlockedDatabases() const { return !mMaybeBlockedDatabases.IsEmpty(); } |
3094 | #endif |
3095 | |
3096 | void StringifyState(nsACString& aResult) const; |
3097 | |
3098 | void Stringify(nsACString& aResult) const; |
3099 | |
3100 | protected: |
3101 | FactoryOp(SafeRefPtr<Factory> aFactory, |
3102 | const Maybe<ContentParentId>& aContentParentId, |
3103 | const PersistenceType aPersistenceType, |
3104 | const PrincipalInfo& aPrincipalInfo, |
3105 | const Maybe<nsString>& aDatabaseName, bool aDeleting); |
3106 | |
3107 | ~FactoryOp() override { |
3108 | // Normally this would be out-of-line since it is a virtual function but |
3109 | // MSVC 2010 fails to link for some reason if it is not inlined here... |
3110 | MOZ_ASSERT_IF(OperationMayProceed(),do { if (OperationMayProceed()) { do { static_assert( mozilla ::detail::AssertionConditionType<decltype(mState == State:: Initial || mState == State::Completed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Initial || mState == State::Completed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mState == State::Initial || mState == State::Completed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3111); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial || mState == State::Completed" ")"); do { *((volatile int*)__null) = 3111; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3111 | mState == State::Initial || mState == State::Completed)do { if (OperationMayProceed()) { do { static_assert( mozilla ::detail::AssertionConditionType<decltype(mState == State:: Initial || mState == State::Completed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Initial || mState == State::Completed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mState == State::Initial || mState == State::Completed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3111); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial || mState == State::Completed" ")"); do { *((volatile int*)__null) = 3111; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
3112 | } |
3113 | |
3114 | nsresult Open(); |
3115 | |
3116 | nsresult DirectoryOpen(); |
3117 | |
3118 | nsresult DirectoryWorkDone(); |
3119 | |
3120 | nsresult SendToIOThread(); |
3121 | |
3122 | void WaitForTransactions(); |
3123 | |
3124 | void CleanupMetadata(); |
3125 | |
3126 | void FinishSendResults(); |
3127 | |
3128 | nsresult SendVersionChangeMessages(DatabaseActorInfo* aDatabaseActorInfo, |
3129 | Maybe<Database&> aOpeningDatabase, |
3130 | uint64_t aOldVersion, |
3131 | const Maybe<uint64_t>& aNewVersion); |
3132 | |
3133 | // Methods that subclasses must implement. |
3134 | virtual nsresult DoDirectoryWork() = 0; |
3135 | |
3136 | virtual nsresult DatabaseOpen() = 0; |
3137 | |
3138 | virtual nsresult DoDatabaseWork() = 0; |
3139 | |
3140 | virtual nsresult BeginVersionChange() = 0; |
3141 | |
3142 | virtual bool AreActorsAlive() = 0; |
3143 | |
3144 | virtual nsresult DispatchToWorkThread() = 0; |
3145 | |
3146 | virtual nsresult DoVersionUpdate() = 0; |
3147 | |
3148 | // Should only be called by Run(). |
3149 | virtual void SendResults() = 0; |
3150 | |
3151 | // Common nsIRunnable implementation that subclasses may not override. |
3152 | NS_IMETHODvirtual nsresult |
3153 | Run() final; |
3154 | |
3155 | void DirectoryLockAcquired(ClientDirectoryLock* aLock); |
3156 | |
3157 | void DirectoryLockFailed(); |
3158 | |
3159 | virtual void SendBlockedNotification() = 0; |
3160 | |
3161 | private: |
3162 | // Test whether this FactoryOp needs to wait for the given op. |
3163 | bool MustWaitFor(const FactoryOp& aExistingOp); |
3164 | |
3165 | void AddBlockingOp(FactoryOp& aOp) { |
3166 | AssertIsOnOwningThread(); |
3167 | |
3168 | mBlocking.AppendElement(WrapNotNull(&aOp)); |
3169 | } |
3170 | |
3171 | void AddBlockedOnOp(FactoryOp& aOp) { |
3172 | AssertIsOnOwningThread(); |
3173 | |
3174 | mBlockedOn.AppendElement(WrapNotNull(&aOp)); |
3175 | } |
3176 | |
3177 | void MaybeUnblock(FactoryOp& aOp) { |
3178 | AssertIsOnOwningThread(); |
3179 | |
3180 | mBlockedOn.RemoveElement(&aOp); |
3181 | if (mBlockedOn.IsEmpty()) { |
3182 | MOZ_ALWAYS_SUCCEEDS(NS_DispatchToCurrentThread(this))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (NS_DispatchToCurrentThread(this))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(NS_DispatchToCurrentThread(this))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3182); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(NS_DispatchToCurrentThread(this))" ")"); do { *((volatile int*)__null) = 3182; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
3183 | } |
3184 | } |
3185 | }; |
3186 | |
3187 | class FactoryRequestOp : public FactoryOp, |
3188 | public PBackgroundIDBFactoryRequestParent { |
3189 | protected: |
3190 | const CommonFactoryRequestParams mCommonParams; |
3191 | |
3192 | FactoryRequestOp(SafeRefPtr<Factory> aFactory, |
3193 | const Maybe<ContentParentId>& aContentParentId, |
3194 | const CommonFactoryRequestParams& aCommonParams, |
3195 | bool aDeleting) |
3196 | : FactoryOp(std::move(aFactory), aContentParentId, |
3197 | aCommonParams.metadata().persistenceType(), |
3198 | aCommonParams.principalInfo(), |
3199 | Some(aCommonParams.metadata().name()), aDeleting), |
3200 | mCommonParams(aCommonParams) {} |
3201 | |
3202 | nsresult DoDirectoryWork() override; |
3203 | |
3204 | // IPDL methods. |
3205 | void ActorDestroy(ActorDestroyReason aWhy) override; |
3206 | }; |
3207 | |
3208 | class OpenDatabaseOp final : public FactoryRequestOp { |
3209 | friend class Database; |
3210 | friend class VersionChangeTransaction; |
3211 | |
3212 | class VersionChangeOp; |
3213 | |
3214 | SafeRefPtr<FullDatabaseMetadata> mMetadata; |
3215 | |
3216 | uint64_t mRequestedVersion; |
3217 | SafeRefPtr<DatabaseFileManager> mFileManager; |
3218 | |
3219 | SafeRefPtr<Database> mDatabase; |
3220 | SafeRefPtr<VersionChangeTransaction> mVersionChangeTransaction; |
3221 | |
3222 | // This is only set while a VersionChangeOp is live. It holds a strong |
3223 | // reference to its OpenDatabaseOp object so this is a weak pointer to avoid |
3224 | // cycles. |
3225 | VersionChangeOp* mVersionChangeOp; |
3226 | |
3227 | MoveOnlyFunction<void()> mCompleteCallback; |
3228 | |
3229 | uint32_t mTelemetryId; |
3230 | |
3231 | public: |
3232 | OpenDatabaseOp(SafeRefPtr<Factory> aFactory, |
3233 | const Maybe<ContentParentId>& aContentParentId, |
3234 | const CommonFactoryRequestParams& aParams); |
3235 | |
3236 | private: |
3237 | ~OpenDatabaseOp() override { MOZ_ASSERT(!mVersionChangeOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mVersionChangeOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mVersionChangeOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mVersionChangeOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3237); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mVersionChangeOp" ")"); do { *((volatile int*)__null) = 3237; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } |
3238 | |
3239 | nsresult LoadDatabaseInformation(mozIStorageConnection& aConnection); |
3240 | |
3241 | nsresult SendUpgradeNeeded(); |
3242 | |
3243 | void EnsureDatabaseActor(); |
3244 | |
3245 | nsresult EnsureDatabaseActorIsAlive(); |
3246 | |
3247 | mozilla::Result<DatabaseSpec, nsresult> MetadataToSpec() const; |
3248 | |
3249 | void AssertMetadataConsistency(const FullDatabaseMetadata& aMetadata) |
3250 | #ifdef DEBUG1 |
3251 | ; |
3252 | #else |
3253 | { |
3254 | } |
3255 | #endif |
3256 | |
3257 | void ConnectionClosedCallback(); |
3258 | |
3259 | void ActorDestroy(ActorDestroyReason aWhy) override; |
3260 | |
3261 | nsresult DatabaseOpen() override; |
3262 | |
3263 | nsresult DoDatabaseWork() override; |
3264 | |
3265 | nsresult BeginVersionChange() override; |
3266 | |
3267 | bool AreActorsAlive() override; |
3268 | |
3269 | void SendBlockedNotification() override; |
3270 | |
3271 | nsresult DispatchToWorkThread() override; |
3272 | |
3273 | nsresult DoVersionUpdate() override; |
3274 | |
3275 | void SendResults() override; |
3276 | |
3277 | static nsresult UpdateLocaleAwareIndex(mozIStorageConnection& aConnection, |
3278 | const IndexMetadata& aIndexMetadata, |
3279 | const nsCString& aLocale); |
3280 | }; |
3281 | |
3282 | class OpenDatabaseOp::VersionChangeOp final |
3283 | : public TransactionDatabaseOperationBase { |
3284 | friend class OpenDatabaseOp; |
3285 | |
3286 | RefPtr<OpenDatabaseOp> mOpenDatabaseOp; |
3287 | const uint64_t mRequestedVersion; |
3288 | uint64_t mPreviousVersion; |
3289 | |
3290 | private: |
3291 | explicit VersionChangeOp(OpenDatabaseOp* aOpenDatabaseOp) |
3292 | : TransactionDatabaseOperationBase( |
3293 | aOpenDatabaseOp->mVersionChangeTransaction.clonePtr(), |
3294 | /* aRequestId */ 0, aOpenDatabaseOp->LoggingSerialNumber()), |
3295 | mOpenDatabaseOp(aOpenDatabaseOp), |
3296 | mRequestedVersion(aOpenDatabaseOp->mRequestedVersion), |
3297 | mPreviousVersion( |
3298 | aOpenDatabaseOp->mMetadata->mCommonMetadata.version()) { |
3299 | MOZ_ASSERT(aOpenDatabaseOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aOpenDatabaseOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aOpenDatabaseOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aOpenDatabaseOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3299); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aOpenDatabaseOp" ")"); do { *((volatile int*)__null) = 3299; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3300 | MOZ_ASSERT(mRequestedVersion)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mRequestedVersion)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mRequestedVersion))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mRequestedVersion" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3300); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mRequestedVersion" ")"); do { *((volatile int*)__null) = 3300; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3301 | } |
3302 | |
3303 | ~VersionChangeOp() override { MOZ_ASSERT(!mOpenDatabaseOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mOpenDatabaseOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mOpenDatabaseOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mOpenDatabaseOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3303); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mOpenDatabaseOp" ")"); do { *((volatile int*)__null) = 3303; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } |
3304 | |
3305 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3306 | |
3307 | nsresult SendSuccessResult() override; |
3308 | |
3309 | bool SendFailureResult(nsresult aResultCode) override; |
3310 | |
3311 | void Cleanup() override; |
3312 | }; |
3313 | |
3314 | class DeleteDatabaseOp final : public FactoryRequestOp { |
3315 | class VersionChangeOp; |
3316 | |
3317 | nsString mDatabaseDirectoryPath; |
3318 | nsString mDatabaseFilenameBase; |
3319 | uint64_t mPreviousVersion; |
3320 | |
3321 | public: |
3322 | DeleteDatabaseOp(SafeRefPtr<Factory> aFactory, |
3323 | const Maybe<ContentParentId>& aContentParentId, |
3324 | const CommonFactoryRequestParams& aParams) |
3325 | : FactoryRequestOp(std::move(aFactory), aContentParentId, aParams, |
3326 | /* aDeleting */ true), |
3327 | mPreviousVersion(0) {} |
3328 | |
3329 | private: |
3330 | ~DeleteDatabaseOp() override = default; |
3331 | |
3332 | void LoadPreviousVersion(nsIFile& aDatabaseFile); |
3333 | |
3334 | nsresult DatabaseOpen() override; |
3335 | |
3336 | nsresult DoDatabaseWork() override; |
3337 | |
3338 | nsresult BeginVersionChange() override; |
3339 | |
3340 | bool AreActorsAlive() override; |
3341 | |
3342 | void SendBlockedNotification() override; |
3343 | |
3344 | nsresult DispatchToWorkThread() override; |
3345 | |
3346 | nsresult DoVersionUpdate() override; |
3347 | |
3348 | void SendResults() override; |
3349 | }; |
3350 | |
3351 | class DeleteDatabaseOp::VersionChangeOp final : public DatabaseOperationBase { |
3352 | friend class DeleteDatabaseOp; |
3353 | |
3354 | RefPtr<DeleteDatabaseOp> mDeleteDatabaseOp; |
3355 | |
3356 | private: |
3357 | explicit VersionChangeOp(DeleteDatabaseOp* aDeleteDatabaseOp) |
3358 | : DatabaseOperationBase(aDeleteDatabaseOp->BackgroundChildLoggingId(), |
3359 | aDeleteDatabaseOp->LoggingSerialNumber()), |
3360 | mDeleteDatabaseOp(aDeleteDatabaseOp) { |
3361 | MOZ_ASSERT(aDeleteDatabaseOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDeleteDatabaseOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDeleteDatabaseOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDeleteDatabaseOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3361); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDeleteDatabaseOp" ")"); do { *((volatile int*)__null) = 3361; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3362 | MOZ_ASSERT(!aDeleteDatabaseOp->mDatabaseDirectoryPath.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDeleteDatabaseOp->mDatabaseDirectoryPath.IsEmpty ())>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!aDeleteDatabaseOp->mDatabaseDirectoryPath.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!aDeleteDatabaseOp->mDatabaseDirectoryPath.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3362); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDeleteDatabaseOp->mDatabaseDirectoryPath.IsEmpty()" ")"); do { *((volatile int*)__null) = 3362; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3363 | } |
3364 | |
3365 | ~VersionChangeOp() override = default; |
3366 | |
3367 | nsresult RunOnIOThread(); |
3368 | |
3369 | void RunOnOwningThread(); |
3370 | |
3371 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
3372 | }; |
3373 | |
3374 | class GetDatabasesOp final : public FactoryOp { |
3375 | nsTHashMap<nsStringHashKey, DatabaseMetadata> mDatabaseMetadataTable; |
3376 | nsTArray<DatabaseMetadata> mDatabaseMetadataArray; |
3377 | Factory::GetDatabasesResolver mResolver; |
3378 | |
3379 | public: |
3380 | GetDatabasesOp(SafeRefPtr<Factory> aFactory, |
3381 | const Maybe<ContentParentId>& aContentParentId, |
3382 | const PersistenceType aPersistenceType, |
3383 | const PrincipalInfo& aPrincipalInfo, |
3384 | Factory::GetDatabasesResolver&& aResolver) |
3385 | : FactoryOp(std::move(aFactory), aContentParentId, aPersistenceType, |
3386 | aPrincipalInfo, Nothing(), /* aDeleting */ false), |
3387 | mResolver(std::move(aResolver)) {} |
3388 | |
3389 | private: |
3390 | ~GetDatabasesOp() override = default; |
3391 | |
3392 | nsresult DatabasesNotAvailable(); |
3393 | |
3394 | nsresult DoDirectoryWork() override; |
3395 | |
3396 | nsresult DatabaseOpen() override; |
3397 | |
3398 | nsresult DoDatabaseWork() override; |
3399 | |
3400 | nsresult BeginVersionChange() override; |
3401 | |
3402 | bool AreActorsAlive() override; |
3403 | |
3404 | void SendBlockedNotification() override; |
3405 | |
3406 | nsresult DispatchToWorkThread() override; |
3407 | |
3408 | nsresult DoVersionUpdate() override; |
3409 | |
3410 | void SendResults() override; |
3411 | }; |
3412 | |
3413 | class VersionChangeTransactionOp : public TransactionDatabaseOperationBase { |
3414 | public: |
3415 | void Cleanup() override; |
3416 | |
3417 | protected: |
3418 | explicit VersionChangeTransactionOp( |
3419 | SafeRefPtr<VersionChangeTransaction> aTransaction) |
3420 | : TransactionDatabaseOperationBase(std::move(aTransaction), |
3421 | /* aRequestId */ 0) {} |
3422 | |
3423 | ~VersionChangeTransactionOp() override = default; |
3424 | |
3425 | private: |
3426 | nsresult SendSuccessResult() override; |
3427 | |
3428 | bool SendFailureResult(nsresult aResultCode) override; |
3429 | }; |
3430 | |
3431 | class CreateObjectStoreOp final : public VersionChangeTransactionOp { |
3432 | friend class VersionChangeTransaction; |
3433 | |
3434 | const ObjectStoreMetadata mMetadata; |
3435 | |
3436 | private: |
3437 | // Only created by VersionChangeTransaction. |
3438 | CreateObjectStoreOp(SafeRefPtr<VersionChangeTransaction> aTransaction, |
3439 | const ObjectStoreMetadata& aMetadata) |
3440 | : VersionChangeTransactionOp(std::move(aTransaction)), |
3441 | mMetadata(aMetadata) { |
3442 | MOZ_ASSERT(aMetadata.id())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMetadata.id())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMetadata.id()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aMetadata.id()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3442); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMetadata.id()" ")"); do { *((volatile int*)__null) = 3442; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3443 | } |
3444 | |
3445 | ~CreateObjectStoreOp() override = default; |
3446 | |
3447 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3448 | }; |
3449 | |
3450 | class DeleteObjectStoreOp final : public VersionChangeTransactionOp { |
3451 | friend class VersionChangeTransaction; |
3452 | |
3453 | const SafeRefPtr<FullObjectStoreMetadata> mMetadata; |
3454 | const bool mIsLastObjectStore; |
3455 | |
3456 | private: |
3457 | // Only created by VersionChangeTransaction. |
3458 | DeleteObjectStoreOp(SafeRefPtr<VersionChangeTransaction> aTransaction, |
3459 | SafeRefPtr<FullObjectStoreMetadata> aMetadata, |
3460 | const bool aIsLastObjectStore) |
3461 | : VersionChangeTransactionOp(std::move(aTransaction)), |
3462 | mMetadata(std::move(aMetadata)), |
3463 | mIsLastObjectStore(aIsLastObjectStore) { |
3464 | MOZ_ASSERT(mMetadata->mCommonMetadata.id())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mMetadata->mCommonMetadata.id())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mMetadata->mCommonMetadata .id()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mMetadata->mCommonMetadata.id()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3464); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mMetadata->mCommonMetadata.id()" ")"); do { *((volatile int*)__null) = 3464; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3465 | } |
3466 | |
3467 | ~DeleteObjectStoreOp() override = default; |
3468 | |
3469 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3470 | }; |
3471 | |
3472 | class RenameObjectStoreOp final : public VersionChangeTransactionOp { |
3473 | friend class VersionChangeTransaction; |
3474 | |
3475 | const int64_t mId; |
3476 | const nsString mNewName; |
3477 | |
3478 | private: |
3479 | // Only created by VersionChangeTransaction. |
3480 | RenameObjectStoreOp(SafeRefPtr<VersionChangeTransaction> aTransaction, |
3481 | FullObjectStoreMetadata& aMetadata) |
3482 | : VersionChangeTransactionOp(std::move(aTransaction)), |
3483 | mId(aMetadata.mCommonMetadata.id()), |
3484 | mNewName(aMetadata.mCommonMetadata.name()) { |
3485 | MOZ_ASSERT(mId)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mId)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(mId))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("mId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3485); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mId" ")"); do { *((volatile int*)__null) = 3485; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); |
3486 | } |
3487 | |
3488 | ~RenameObjectStoreOp() override = default; |
3489 | |
3490 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3491 | }; |
3492 | |
3493 | class CreateIndexOp final : public VersionChangeTransactionOp { |
3494 | friend class VersionChangeTransaction; |
3495 | |
3496 | class UpdateIndexDataValuesFunction; |
3497 | |
3498 | const IndexMetadata mMetadata; |
3499 | Maybe<UniqueIndexTable> mMaybeUniqueIndexTable; |
3500 | const SafeRefPtr<DatabaseFileManager> mFileManager; |
3501 | const nsCString mDatabaseId; |
3502 | const IndexOrObjectStoreId mObjectStoreId; |
3503 | |
3504 | private: |
3505 | // Only created by VersionChangeTransaction. |
3506 | CreateIndexOp(SafeRefPtr<VersionChangeTransaction> aTransaction, |
3507 | IndexOrObjectStoreId aObjectStoreId, |
3508 | const IndexMetadata& aMetadata); |
3509 | |
3510 | ~CreateIndexOp() override = default; |
3511 | |
3512 | nsresult InsertDataFromObjectStore(DatabaseConnection* aConnection); |
3513 | |
3514 | nsresult InsertDataFromObjectStoreInternal( |
3515 | DatabaseConnection* aConnection) const; |
3516 | |
3517 | bool Init(TransactionBase& aTransaction) override; |
3518 | |
3519 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3520 | }; |
3521 | |
3522 | class CreateIndexOp::UpdateIndexDataValuesFunction final |
3523 | : public mozIStorageFunction { |
3524 | RefPtr<CreateIndexOp> mOp; |
3525 | RefPtr<DatabaseConnection> mConnection; |
3526 | const NotNull<SafeRefPtr<Database>> mDatabase; |
3527 | |
3528 | public: |
3529 | UpdateIndexDataValuesFunction(CreateIndexOp* aOp, |
3530 | DatabaseConnection* aConnection, |
3531 | SafeRefPtr<Database> aDatabase) |
3532 | : mOp(aOp), |
3533 | mConnection(aConnection), |
3534 | mDatabase(WrapNotNull(std::move(aDatabase))) { |
3535 | MOZ_ASSERT(aOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aOp)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aOp))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("aOp", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3535); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aOp" ")"); do { *((volatile int*)__null) = 3535; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); |
3536 | MOZ_ASSERT(aConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3536); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aConnection" ")"); do { *((volatile int*)__null) = 3536; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3537 | aConnection->AssertIsOnConnectionThread(); |
3538 | } |
3539 | |
3540 | NS_DECL_ISUPPORTSpublic: virtual nsresult QueryInterface(const nsIID& aIID , void** aInstancePtr) override; virtual MozExternalRefCountType AddRef(void) override; virtual MozExternalRefCountType Release (void) override; using HasThreadSafeRefCnt = std::false_type; protected: nsAutoRefCnt mRefCnt; nsAutoOwningThread _mOwningThread ; public: |
3541 | |
3542 | private: |
3543 | ~UpdateIndexDataValuesFunction() = default; |
3544 | |
3545 | NS_DECL_MOZISTORAGEFUNCTIONvirtual nsresult OnFunctionCall(mozIStorageValueArray *aFunctionArguments , nsIVariant **_retval) override; |
3546 | }; |
3547 | |
3548 | class DeleteIndexOp final : public VersionChangeTransactionOp { |
3549 | friend class VersionChangeTransaction; |
3550 | |
3551 | const IndexOrObjectStoreId mObjectStoreId; |
3552 | const IndexOrObjectStoreId mIndexId; |
3553 | const bool mUnique; |
3554 | const bool mIsLastIndex; |
3555 | |
3556 | private: |
3557 | // Only created by VersionChangeTransaction. |
3558 | DeleteIndexOp(SafeRefPtr<VersionChangeTransaction> aTransaction, |
3559 | IndexOrObjectStoreId aObjectStoreId, |
3560 | IndexOrObjectStoreId aIndexId, const bool aUnique, |
3561 | const bool aIsLastIndex); |
3562 | |
3563 | ~DeleteIndexOp() override = default; |
3564 | |
3565 | nsresult RemoveReferencesToIndex( |
3566 | DatabaseConnection* aConnection, const Key& aObjectDataKey, |
3567 | nsTArray<IndexDataValue>& aIndexValues) const; |
3568 | |
3569 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3570 | }; |
3571 | |
3572 | class RenameIndexOp final : public VersionChangeTransactionOp { |
3573 | friend class VersionChangeTransaction; |
3574 | |
3575 | const IndexOrObjectStoreId mObjectStoreId; |
3576 | const IndexOrObjectStoreId mIndexId; |
3577 | const nsString mNewName; |
3578 | |
3579 | private: |
3580 | // Only created by VersionChangeTransaction. |
3581 | RenameIndexOp(SafeRefPtr<VersionChangeTransaction> aTransaction, |
3582 | FullIndexMetadata& aMetadata, |
3583 | IndexOrObjectStoreId aObjectStoreId) |
3584 | : VersionChangeTransactionOp(std::move(aTransaction)), |
3585 | mObjectStoreId(aObjectStoreId), |
3586 | mIndexId(aMetadata.mCommonMetadata.id()), |
3587 | mNewName(aMetadata.mCommonMetadata.name()) { |
3588 | MOZ_ASSERT(mIndexId)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIndexId)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mIndexId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mIndexId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3588); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIndexId" ")" ); do { *((volatile int*)__null) = 3588; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3589 | } |
3590 | |
3591 | ~RenameIndexOp() override = default; |
3592 | |
3593 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3594 | }; |
3595 | |
3596 | class NormalTransactionOp : public TransactionDatabaseOperationBase, |
3597 | public PBackgroundIDBRequestParent { |
3598 | #ifdef DEBUG1 |
3599 | bool mResponseSent; |
3600 | #endif |
3601 | |
3602 | public: |
3603 | void Cleanup() override; |
3604 | |
3605 | protected: |
3606 | NormalTransactionOp(SafeRefPtr<TransactionBase> aTransaction, |
3607 | const int64_t aRequestId) |
3608 | : TransactionDatabaseOperationBase(std::move(aTransaction), aRequestId) |
3609 | #ifdef DEBUG1 |
3610 | , |
3611 | mResponseSent(false) |
3612 | #endif |
3613 | { |
3614 | } |
3615 | |
3616 | ~NormalTransactionOp() override = default; |
3617 | |
3618 | // An overload of DatabaseOperationBase's function that can avoid doing extra |
3619 | // work on non-versionchange transactions. |
3620 | mozilla::Result<bool, nsresult> ObjectStoreHasIndexes( |
3621 | DatabaseConnection& aConnection, IndexOrObjectStoreId aObjectStoreId, |
3622 | bool aMayHaveIndexes); |
3623 | |
3624 | virtual mozilla::Result<PreprocessParams, nsresult> GetPreprocessParams(); |
3625 | |
3626 | // Subclasses use this override to set the IPDL response value. |
3627 | virtual void GetResponse(RequestResponse& aResponse, |
3628 | size_t* aResponseSize) = 0; |
3629 | |
3630 | private: |
3631 | nsresult SendPreprocessInfo() override; |
3632 | |
3633 | nsresult SendSuccessResult() override; |
3634 | |
3635 | bool SendFailureResult(nsresult aResultCode) override; |
3636 | |
3637 | // IPDL methods. |
3638 | void ActorDestroy(ActorDestroyReason aWhy) override; |
3639 | |
3640 | mozilla::ipc::IPCResult RecvContinue( |
3641 | const PreprocessResponse& aResponse) final; |
3642 | }; |
3643 | |
3644 | class ObjectStoreAddOrPutRequestOp final : public NormalTransactionOp { |
3645 | friend class TransactionBase; |
3646 | |
3647 | using PersistenceType = mozilla::dom::quota::PersistenceType; |
3648 | |
3649 | class StoredFileInfo final { |
3650 | InitializedOnce<const NotNull<SafeRefPtr<DatabaseFileInfo>>> mFileInfo; |
3651 | // Either nothing, a file actor or a non-Blob-backed inputstream to write to |
3652 | // disk. |
3653 | using FileActorOrInputStream = |
3654 | Variant<Nothing, RefPtr<DatabaseFile>, nsCOMPtr<nsIInputStream>>; |
3655 | InitializedOnce<const FileActorOrInputStream> mFileActorOrInputStream; |
3656 | #ifdef DEBUG1 |
3657 | const StructuredCloneFileBase::FileType mType; |
3658 | #endif |
3659 | void EnsureCipherKey(); |
3660 | void AssertInvariants() const; |
3661 | |
3662 | StoredFileInfo(SafeRefPtr<DatabaseFileInfo> aFileInfo, |
3663 | RefPtr<DatabaseFile> aFileActor); |
3664 | |
3665 | StoredFileInfo(SafeRefPtr<DatabaseFileInfo> aFileInfo, |
3666 | nsCOMPtr<nsIInputStream> aInputStream); |
3667 | |
3668 | public: |
3669 | #if defined(NS_BUILD_REFCNT_LOGGING1) |
3670 | // Only for MOZ_COUNT_CTOR. |
3671 | StoredFileInfo(StoredFileInfo&& aOther) |
3672 | : mFileInfo{std::move(aOther.mFileInfo)}, |
3673 | mFileActorOrInputStream{std::move(aOther.mFileActorOrInputStream)} |
3674 | # ifdef DEBUG1 |
3675 | , |
3676 | mType{aOther.mType} |
3677 | # endif |
3678 | { |
3679 | MOZ_COUNT_CTOR(ObjectStoreAddOrPutRequestOp::StoredFileInfo)do { static_assert(std::is_class_v<ObjectStoreAddOrPutRequestOp ::StoredFileInfo>, "Token '" "ObjectStoreAddOrPutRequestOp::StoredFileInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ObjectStoreAddOrPutRequestOp::StoredFileInfo> ::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ObjectStoreAddOrPutRequestOp::StoredFileInfo" , sizeof(*this)); } while (0); |
3680 | } |
3681 | #else |
3682 | StoredFileInfo(StoredFileInfo&&) = default; |
3683 | #endif |
3684 | |
3685 | static StoredFileInfo CreateForBlob(SafeRefPtr<DatabaseFileInfo> aFileInfo, |
3686 | RefPtr<DatabaseFile> aFileActor); |
3687 | static StoredFileInfo CreateForStructuredClone( |
3688 | SafeRefPtr<DatabaseFileInfo> aFileInfo, |
3689 | nsCOMPtr<nsIInputStream> aInputStream); |
3690 | |
3691 | #if defined(DEBUG1) || defined(NS_BUILD_REFCNT_LOGGING1) |
3692 | ~StoredFileInfo() { |
3693 | AssertIsOnBackgroundThread(); |
3694 | AssertInvariants(); |
3695 | |
3696 | MOZ_COUNT_DTOR(ObjectStoreAddOrPutRequestOp::StoredFileInfo)do { static_assert(std::is_class_v<ObjectStoreAddOrPutRequestOp ::StoredFileInfo>, "Token '" "ObjectStoreAddOrPutRequestOp::StoredFileInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ObjectStoreAddOrPutRequestOp::StoredFileInfo> ::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ObjectStoreAddOrPutRequestOp::StoredFileInfo" , sizeof(*this)); } while (0); |
3697 | } |
3698 | #endif |
3699 | |
3700 | bool IsValid() const { return static_cast<bool>(mFileInfo); } |
3701 | |
3702 | const DatabaseFileInfo& GetFileInfo() const { return **mFileInfo; } |
3703 | |
3704 | bool ShouldCompress() const; |
3705 | |
3706 | void NotifyWriteSucceeded() const; |
3707 | |
3708 | using InputStreamResult = |
3709 | mozilla::Result<nsCOMPtr<nsIInputStream>, nsresult>; |
3710 | InputStreamResult GetInputStream(); |
3711 | |
3712 | void Serialize(nsString& aText) const; |
3713 | }; |
3714 | class SCInputStream; |
3715 | |
3716 | ObjectStoreAddPutParams mParams; |
3717 | Maybe<UniqueIndexTable> mUniqueIndexTable; |
3718 | |
3719 | // This must be non-const so that we can update the mNextAutoIncrementId field |
3720 | // if we are modifying an autoIncrement objectStore. |
3721 | SafeRefPtr<FullObjectStoreMetadata> mMetadata; |
3722 | |
3723 | nsTArray<StoredFileInfo> mStoredFileInfos; |
3724 | |
3725 | Key mResponse; |
3726 | const OriginMetadata mOriginMetadata; |
3727 | const PersistenceType mPersistenceType; |
3728 | const bool mOverwrite; |
3729 | bool mObjectStoreMayHaveIndexes; |
3730 | bool mDataOverThreshold; |
3731 | |
3732 | private: |
3733 | // Only created by TransactionBase. |
3734 | ObjectStoreAddOrPutRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
3735 | const int64_t aRequestId, |
3736 | RequestParams&& aParams); |
3737 | |
3738 | ~ObjectStoreAddOrPutRequestOp() override = default; |
3739 | |
3740 | nsresult RemoveOldIndexDataValues(DatabaseConnection* aConnection); |
3741 | |
3742 | bool Init(TransactionBase& aTransaction) override; |
3743 | |
3744 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3745 | |
3746 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override; |
3747 | |
3748 | void Cleanup() override; |
3749 | }; |
3750 | |
3751 | void ObjectStoreAddOrPutRequestOp::StoredFileInfo::AssertInvariants() const { |
3752 | // The only allowed types are eStructuredClone, eBlob and eMutableFile. |
3753 | MOZ_ASSERT(StructuredCloneFileBase::eStructuredClone == mType ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase ::eMutableFile == mType)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase ::eMutableFile == mType))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase::eMutableFile == mType" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3755); AnnotateMozCrashReason("MOZ_ASSERT" "(" "StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase::eMutableFile == mType" ")"); do { *((volatile int*)__null) = 3755; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
3754 | StructuredCloneFileBase::eBlob == mType ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase ::eMutableFile == mType)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase ::eMutableFile == mType))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase::eMutableFile == mType" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3755); AnnotateMozCrashReason("MOZ_ASSERT" "(" "StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase::eMutableFile == mType" ")"); do { *((volatile int*)__null) = 3755; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
3755 | StructuredCloneFileBase::eMutableFile == mType)do { static_assert( mozilla::detail::AssertionConditionType< decltype(StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase ::eMutableFile == mType)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase ::eMutableFile == mType))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase::eMutableFile == mType" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3755); AnnotateMozCrashReason("MOZ_ASSERT" "(" "StructuredCloneFileBase::eStructuredClone == mType || StructuredCloneFileBase::eBlob == mType || StructuredCloneFileBase::eMutableFile == mType" ")"); do { *((volatile int*)__null) = 3755; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3756 | |
3757 | // mFileInfo and a file actor in mFileActorOrInputStream are present until |
3758 | // the object is moved away, but an inputStream in mFileActorOrInputStream |
3759 | // can be released early. |
3760 | MOZ_ASSERT_IF(static_cast<bool>(mFileActorOrInputStream) &&do { if (static_cast<bool>(mFileActorOrInputStream) && mFileActorOrInputStream->is<RefPtr<DatabaseFile>> ()) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(static_cast<bool>(mFileInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(static_cast<bool>(mFileInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("static_cast<bool>(mFileInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3762); AnnotateMozCrashReason("MOZ_ASSERT" "(" "static_cast<bool>(mFileInfo)" ")"); do { *((volatile int*)__null) = 3762; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3761 | mFileActorOrInputStream->is<RefPtr<DatabaseFile>>(),do { if (static_cast<bool>(mFileActorOrInputStream) && mFileActorOrInputStream->is<RefPtr<DatabaseFile>> ()) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(static_cast<bool>(mFileInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(static_cast<bool>(mFileInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("static_cast<bool>(mFileInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3762); AnnotateMozCrashReason("MOZ_ASSERT" "(" "static_cast<bool>(mFileInfo)" ")"); do { *((volatile int*)__null) = 3762; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3762 | static_cast<bool>(mFileInfo))do { if (static_cast<bool>(mFileActorOrInputStream) && mFileActorOrInputStream->is<RefPtr<DatabaseFile>> ()) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(static_cast<bool>(mFileInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(static_cast<bool>(mFileInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("static_cast<bool>(mFileInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3762); AnnotateMozCrashReason("MOZ_ASSERT" "(" "static_cast<bool>(mFileInfo)" ")"); do { *((volatile int*)__null) = 3762; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
3763 | |
3764 | if (mFileInfo) { |
3765 | // In a non-moved StoredFileInfo, one of the following is true: |
3766 | // - This was an overflow structured clone (eStructuredClone) and |
3767 | // storedFileInfo.mFileActorOrInputStream CAN be a non-nullptr input |
3768 | // stream (but that might have been release by ReleaseInputStream). |
3769 | MOZ_ASSERT_IF(do { if (StructuredCloneFileBase::eStructuredClone == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mFileActorOrInputStream || (mFileActorOrInputStream ->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>()))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mFileActorOrInputStream || (mFileActorOrInputStream->is <nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>())))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3773); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" ")"); do { *((volatile int*)__null) = 3773; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3770 | StructuredCloneFileBase::eStructuredClone == mType,do { if (StructuredCloneFileBase::eStructuredClone == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mFileActorOrInputStream || (mFileActorOrInputStream ->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>()))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mFileActorOrInputStream || (mFileActorOrInputStream->is <nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>())))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3773); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" ")"); do { *((volatile int*)__null) = 3773; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3771 | !mFileActorOrInputStream ||do { if (StructuredCloneFileBase::eStructuredClone == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mFileActorOrInputStream || (mFileActorOrInputStream ->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>()))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mFileActorOrInputStream || (mFileActorOrInputStream->is <nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>())))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3773); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" ")"); do { *((volatile int*)__null) = 3773; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3772 | (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() &&do { if (StructuredCloneFileBase::eStructuredClone == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mFileActorOrInputStream || (mFileActorOrInputStream ->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>()))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mFileActorOrInputStream || (mFileActorOrInputStream->is <nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>())))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3773); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" ")"); do { *((volatile int*)__null) = 3773; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3773 | mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>()))do { if (StructuredCloneFileBase::eStructuredClone == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mFileActorOrInputStream || (mFileActorOrInputStream ->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>()))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mFileActorOrInputStream || (mFileActorOrInputStream->is <nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream ->as<nsCOMPtr<nsIInputStream>>())))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3773); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mFileActorOrInputStream || (mFileActorOrInputStream->is<nsCOMPtr<nsIInputStream>>() && mFileActorOrInputStream->as<nsCOMPtr<nsIInputStream>>())" ")"); do { *((volatile int*)__null) = 3773; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
3774 | |
3775 | // - This is a reference to a Blob (eBlob) that may or may not have |
3776 | // already been written to disk. storedFileInfo.mFileActorOrInputStream |
3777 | // MUST be a non-null file actor, but its GetInputStream may return |
3778 | // nullptr (so don't assert on that). |
3779 | MOZ_ASSERT_IF(StructuredCloneFileBase::eBlob == mType,do { if (StructuredCloneFileBase::eBlob == mType) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(mFileActorOrInputStream ->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream ->as<RefPtr<DatabaseFile>>())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileActorOrInputStream-> is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream ->as<RefPtr<DatabaseFile>>()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream->as<RefPtr<DatabaseFile>>()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3781); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream->as<RefPtr<DatabaseFile>>()" ")"); do { *((volatile int*)__null) = 3781; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3780 | mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() &&do { if (StructuredCloneFileBase::eBlob == mType) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(mFileActorOrInputStream ->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream ->as<RefPtr<DatabaseFile>>())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileActorOrInputStream-> is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream ->as<RefPtr<DatabaseFile>>()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream->as<RefPtr<DatabaseFile>>()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3781); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream->as<RefPtr<DatabaseFile>>()" ")"); do { *((volatile int*)__null) = 3781; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3781 | mFileActorOrInputStream->as<RefPtr<DatabaseFile>>())do { if (StructuredCloneFileBase::eBlob == mType) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(mFileActorOrInputStream ->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream ->as<RefPtr<DatabaseFile>>())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileActorOrInputStream-> is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream ->as<RefPtr<DatabaseFile>>()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream->as<RefPtr<DatabaseFile>>()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3781); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileActorOrInputStream->is<RefPtr<DatabaseFile>>() && mFileActorOrInputStream->as<RefPtr<DatabaseFile>>()" ")"); do { *((volatile int*)__null) = 3781; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
3782 | |
3783 | // - It's a mutable file (eMutableFile). No writing will be performed, |
3784 | // and storedFileInfo.mFileActorOrInputStream is Nothing. |
3785 | MOZ_ASSERT_IF(StructuredCloneFileBase::eMutableFile == mType,do { if (StructuredCloneFileBase::eMutableFile == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileActorOrInputStream->is<Nothing>())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mFileActorOrInputStream->is<Nothing>()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mFileActorOrInputStream->is<Nothing>()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3786); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileActorOrInputStream->is<Nothing>()" ")"); do { *((volatile int*)__null) = 3786; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
3786 | mFileActorOrInputStream->is<Nothing>())do { if (StructuredCloneFileBase::eMutableFile == mType) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileActorOrInputStream->is<Nothing>())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mFileActorOrInputStream->is<Nothing>()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mFileActorOrInputStream->is<Nothing>()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3786); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileActorOrInputStream->is<Nothing>()" ")"); do { *((volatile int*)__null) = 3786; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
3787 | } |
3788 | } |
3789 | |
3790 | void ObjectStoreAddOrPutRequestOp::StoredFileInfo::EnsureCipherKey() { |
3791 | const auto& fileInfo = GetFileInfo(); |
3792 | const auto& fileManager = fileInfo.Manager(); |
3793 | |
3794 | // No need to generate cipher keys if we are not in PBM |
3795 | if (!fileManager.IsInPrivateBrowsingMode()) { |
3796 | return; |
3797 | } |
3798 | |
3799 | nsCString keyId; |
3800 | keyId.AppendInt(fileInfo.Id()); |
3801 | |
3802 | fileManager.MutableCipherKeyManagerRef().Ensure(keyId); |
3803 | } |
3804 | |
3805 | ObjectStoreAddOrPutRequestOp::StoredFileInfo::StoredFileInfo( |
3806 | SafeRefPtr<DatabaseFileInfo> aFileInfo, RefPtr<DatabaseFile> aFileActor) |
3807 | : mFileInfo{WrapNotNull(std::move(aFileInfo))}, |
3808 | mFileActorOrInputStream{std::move(aFileActor)} |
3809 | #ifdef DEBUG1 |
3810 | , |
3811 | mType{StructuredCloneFileBase::eBlob} |
3812 | #endif |
3813 | { |
3814 | AssertIsOnBackgroundThread(); |
3815 | AssertInvariants(); |
3816 | |
3817 | EnsureCipherKey(); |
3818 | MOZ_COUNT_CTOR(ObjectStoreAddOrPutRequestOp::StoredFileInfo)do { static_assert(std::is_class_v<ObjectStoreAddOrPutRequestOp ::StoredFileInfo>, "Token '" "ObjectStoreAddOrPutRequestOp::StoredFileInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ObjectStoreAddOrPutRequestOp::StoredFileInfo> ::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ObjectStoreAddOrPutRequestOp::StoredFileInfo" , sizeof(*this)); } while (0); |
3819 | } |
3820 | |
3821 | ObjectStoreAddOrPutRequestOp::StoredFileInfo::StoredFileInfo( |
3822 | SafeRefPtr<DatabaseFileInfo> aFileInfo, |
3823 | nsCOMPtr<nsIInputStream> aInputStream) |
3824 | : mFileInfo{WrapNotNull(std::move(aFileInfo))}, |
3825 | mFileActorOrInputStream{std::move(aInputStream)} |
3826 | #ifdef DEBUG1 |
3827 | , |
3828 | mType{StructuredCloneFileBase::eStructuredClone} |
3829 | #endif |
3830 | { |
3831 | AssertIsOnBackgroundThread(); |
3832 | AssertInvariants(); |
3833 | |
3834 | EnsureCipherKey(); |
3835 | MOZ_COUNT_CTOR(ObjectStoreAddOrPutRequestOp::StoredFileInfo)do { static_assert(std::is_class_v<ObjectStoreAddOrPutRequestOp ::StoredFileInfo>, "Token '" "ObjectStoreAddOrPutRequestOp::StoredFileInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ObjectStoreAddOrPutRequestOp::StoredFileInfo> ::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ObjectStoreAddOrPutRequestOp::StoredFileInfo" , sizeof(*this)); } while (0); |
3836 | } |
3837 | |
3838 | ObjectStoreAddOrPutRequestOp::StoredFileInfo |
3839 | ObjectStoreAddOrPutRequestOp::StoredFileInfo::CreateForBlob( |
3840 | SafeRefPtr<DatabaseFileInfo> aFileInfo, RefPtr<DatabaseFile> aFileActor) { |
3841 | return {std::move(aFileInfo), std::move(aFileActor)}; |
3842 | } |
3843 | |
3844 | ObjectStoreAddOrPutRequestOp::StoredFileInfo |
3845 | ObjectStoreAddOrPutRequestOp::StoredFileInfo::CreateForStructuredClone( |
3846 | SafeRefPtr<DatabaseFileInfo> aFileInfo, |
3847 | nsCOMPtr<nsIInputStream> aInputStream) { |
3848 | return {std::move(aFileInfo), std::move(aInputStream)}; |
3849 | } |
3850 | |
3851 | bool ObjectStoreAddOrPutRequestOp::StoredFileInfo::ShouldCompress() const { |
3852 | // Must not be called after moving. |
3853 | MOZ_ASSERT(IsValid())do { static_assert( mozilla::detail::AssertionConditionType< decltype(IsValid())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(IsValid()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("IsValid()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3853); AnnotateMozCrashReason("MOZ_ASSERT" "(" "IsValid()" ")" ); do { *((volatile int*)__null) = 3853; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3854 | |
3855 | // Compression is only necessary for eStructuredClone, i.e. when |
3856 | // mFileActorOrInputStream stored an input stream. However, this is only |
3857 | // called after GetInputStream, when mFileActorOrInputStream has been |
3858 | // cleared, which is only possible for this type. |
3859 | const bool res = !mFileActorOrInputStream; |
3860 | MOZ_ASSERT(res == (StructuredCloneFileBase::eStructuredClone == mType))do { static_assert( mozilla::detail::AssertionConditionType< decltype(res == (StructuredCloneFileBase::eStructuredClone == mType))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(res == (StructuredCloneFileBase::eStructuredClone == mType)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("res == (StructuredCloneFileBase::eStructuredClone == mType)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3860); AnnotateMozCrashReason("MOZ_ASSERT" "(" "res == (StructuredCloneFileBase::eStructuredClone == mType)" ")"); do { *((volatile int*)__null) = 3860; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3861 | return res; |
3862 | } |
3863 | |
3864 | void ObjectStoreAddOrPutRequestOp::StoredFileInfo::NotifyWriteSucceeded() |
3865 | const { |
3866 | MOZ_ASSERT(IsValid())do { static_assert( mozilla::detail::AssertionConditionType< decltype(IsValid())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(IsValid()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("IsValid()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3866); AnnotateMozCrashReason("MOZ_ASSERT" "(" "IsValid()" ")" ); do { *((volatile int*)__null) = 3866; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3867 | |
3868 | // For eBlob, clear the blob implementation. |
3869 | if (mFileActorOrInputStream && |
3870 | mFileActorOrInputStream->is<RefPtr<DatabaseFile>>()) { |
3871 | mFileActorOrInputStream->as<RefPtr<DatabaseFile>>() |
3872 | ->WriteSucceededClearBlobImpl(); |
3873 | } |
3874 | |
3875 | // For the other types, no action is necessary. |
3876 | } |
3877 | |
3878 | ObjectStoreAddOrPutRequestOp::StoredFileInfo::InputStreamResult |
3879 | ObjectStoreAddOrPutRequestOp::StoredFileInfo::GetInputStream() { |
3880 | if (!mFileActorOrInputStream) { |
3881 | MOZ_ASSERT(StructuredCloneFileBase::eStructuredClone == mType)do { static_assert( mozilla::detail::AssertionConditionType< decltype(StructuredCloneFileBase::eStructuredClone == mType)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(StructuredCloneFileBase::eStructuredClone == mType)) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("StructuredCloneFileBase::eStructuredClone == mType" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3881); AnnotateMozCrashReason("MOZ_ASSERT" "(" "StructuredCloneFileBase::eStructuredClone == mType" ")"); do { *((volatile int*)__null) = 3881; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3882 | return nsCOMPtr<nsIInputStream>{}; |
3883 | } |
3884 | |
3885 | // For the different cases, see also the comments in AssertInvariants. |
3886 | return mFileActorOrInputStream->match( |
3887 | [](const Nothing&) -> InputStreamResult { |
3888 | return nsCOMPtr<nsIInputStream>{}; |
3889 | }, |
3890 | [](const RefPtr<DatabaseFile>& databaseActor) -> InputStreamResult { |
3891 | ErrorResult rv; |
3892 | auto inputStream = databaseActor->GetInputStream(rv); |
3893 | if (NS_WARN_IF(rv.Failed())NS_warn_if_impl(rv.Failed(), "rv.Failed()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3893)) { |
3894 | return Err(rv.StealNSResult()); |
3895 | } |
3896 | |
3897 | return inputStream; |
3898 | }, |
3899 | [this](const nsCOMPtr<nsIInputStream>& inputStream) -> InputStreamResult { |
3900 | auto res = inputStream; |
3901 | // destroy() clears the inputStream parameter, so we needed to make a |
3902 | // copy before |
3903 | mFileActorOrInputStream.destroy(); |
3904 | AssertInvariants(); |
3905 | return res; |
3906 | }); |
3907 | } |
3908 | |
3909 | void ObjectStoreAddOrPutRequestOp::StoredFileInfo::Serialize( |
3910 | nsString& aText) const { |
3911 | AssertInvariants(); |
3912 | MOZ_ASSERT(IsValid())do { static_assert( mozilla::detail::AssertionConditionType< decltype(IsValid())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(IsValid()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("IsValid()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 3912); AnnotateMozCrashReason("MOZ_ASSERT" "(" "IsValid()" ")" ); do { *((volatile int*)__null) = 3912; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
3913 | |
3914 | const int64_t id = (*mFileInfo)->Id(); |
3915 | |
3916 | auto structuredCloneHandler = [&aText, id](const nsCOMPtr<nsIInputStream>&) { |
3917 | // eStructuredClone |
3918 | aText.Append('.'); |
3919 | aText.AppendInt(id); |
3920 | }; |
3921 | |
3922 | // If mFileActorOrInputStream was moved, we had an inputStream before. |
3923 | if (!mFileActorOrInputStream) { |
3924 | structuredCloneHandler(nullptr); |
3925 | return; |
3926 | } |
3927 | |
3928 | // This encoding is parsed in DeserializeStructuredCloneFile. |
3929 | mFileActorOrInputStream->match( |
3930 | [&aText, id](const Nothing&) { |
3931 | // eMutableFile |
3932 | aText.AppendInt(-id); |
3933 | }, |
3934 | [&aText, id](const RefPtr<DatabaseFile>&) { |
3935 | // eBlob |
3936 | aText.AppendInt(id); |
3937 | }, |
3938 | structuredCloneHandler); |
3939 | } |
3940 | |
3941 | class ObjectStoreAddOrPutRequestOp::SCInputStream final |
3942 | : public nsIInputStream { |
3943 | const JSStructuredCloneData& mData; |
3944 | JSStructuredCloneData::Iterator mIter; |
3945 | |
3946 | public: |
3947 | explicit SCInputStream(const JSStructuredCloneData& aData) |
3948 | : mData(aData), mIter(aData.Start()) {} |
3949 | |
3950 | private: |
3951 | virtual ~SCInputStream() = default; |
3952 | |
3953 | NS_DECL_THREADSAFE_ISUPPORTSpublic: virtual nsresult QueryInterface(const nsIID& aIID , void** aInstancePtr) override; virtual MozExternalRefCountType AddRef(void) override; virtual MozExternalRefCountType Release (void) override; using HasThreadSafeRefCnt = std::true_type; protected : ::mozilla::ThreadSafeAutoRefCnt mRefCnt; nsAutoOwningThread _mOwningThread; public: |
3954 | NS_DECL_NSIINPUTSTREAMvirtual nsresult Close(void) override; virtual nsresult Available (uint64_t *_retval) override; virtual nsresult StreamStatus(void ) override; virtual nsresult Read(char * aBuf, uint32_t aCount , uint32_t *_retval) override; virtual nsresult ReadSegments( nsWriteSegmentFun aWriter, void * aClosure, uint32_t aCount, uint32_t *_retval) override; virtual nsresult IsNonBlocking(bool *_retval ) override; |
3955 | }; |
3956 | |
3957 | class ObjectStoreGetRequestOp final : public NormalTransactionOp { |
3958 | friend class TransactionBase; |
3959 | |
3960 | const IndexOrObjectStoreId mObjectStoreId; |
3961 | SafeRefPtr<Database> mDatabase; |
3962 | const Maybe<SerializedKeyRange> mOptionalKeyRange; |
3963 | AutoTArray<StructuredCloneReadInfoParent, 1> mResponse; |
3964 | PBackgroundParent* mBackgroundParent; |
3965 | uint32_t mPreprocessInfoCount; |
3966 | const uint32_t mLimit; |
3967 | const bool mGetAll; |
3968 | |
3969 | private: |
3970 | // Only created by TransactionBase. |
3971 | ObjectStoreGetRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
3972 | const int64_t aRequestId, |
3973 | const RequestParams& aParams, bool aGetAll); |
3974 | |
3975 | ~ObjectStoreGetRequestOp() override = default; |
3976 | |
3977 | template <typename T> |
3978 | mozilla::Result<T, nsresult> ConvertResponse( |
3979 | StructuredCloneReadInfoParent&& aInfo); |
3980 | |
3981 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
3982 | |
3983 | bool HasPreprocessInfo() override; |
3984 | |
3985 | mozilla::Result<PreprocessParams, nsresult> GetPreprocessParams() override; |
3986 | |
3987 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override; |
3988 | }; |
3989 | |
3990 | class ObjectStoreGetKeyRequestOp final : public NormalTransactionOp { |
3991 | friend class TransactionBase; |
3992 | |
3993 | const IndexOrObjectStoreId mObjectStoreId; |
3994 | const Maybe<SerializedKeyRange> mOptionalKeyRange; |
3995 | const uint32_t mLimit; |
3996 | const bool mGetAll; |
3997 | nsTArray<Key> mResponse; |
3998 | |
3999 | private: |
4000 | // Only created by TransactionBase. |
4001 | ObjectStoreGetKeyRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4002 | const int64_t aRequestId, |
4003 | const RequestParams& aParams, bool aGetAll); |
4004 | |
4005 | ~ObjectStoreGetKeyRequestOp() override = default; |
4006 | |
4007 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4008 | |
4009 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override; |
4010 | }; |
4011 | |
4012 | class ObjectStoreDeleteRequestOp final : public NormalTransactionOp { |
4013 | friend class TransactionBase; |
4014 | |
4015 | const ObjectStoreDeleteParams mParams; |
4016 | ObjectStoreDeleteResponse mResponse; |
4017 | bool mObjectStoreMayHaveIndexes; |
4018 | |
4019 | private: |
4020 | ObjectStoreDeleteRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4021 | const int64_t aRequestId, |
4022 | const ObjectStoreDeleteParams& aParams); |
4023 | |
4024 | ~ObjectStoreDeleteRequestOp() override = default; |
4025 | |
4026 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4027 | |
4028 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override { |
4029 | aResponse = std::move(mResponse); |
4030 | *aResponseSize = 0; |
4031 | } |
4032 | }; |
4033 | |
4034 | class ObjectStoreClearRequestOp final : public NormalTransactionOp { |
4035 | friend class TransactionBase; |
4036 | |
4037 | const ObjectStoreClearParams mParams; |
4038 | ObjectStoreClearResponse mResponse; |
4039 | bool mObjectStoreMayHaveIndexes; |
4040 | |
4041 | private: |
4042 | ObjectStoreClearRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4043 | const int64_t aRequestId, |
4044 | const ObjectStoreClearParams& aParams); |
4045 | |
4046 | ~ObjectStoreClearRequestOp() override = default; |
4047 | |
4048 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4049 | |
4050 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override { |
4051 | aResponse = std::move(mResponse); |
4052 | *aResponseSize = 0; |
4053 | } |
4054 | }; |
4055 | |
4056 | class ObjectStoreCountRequestOp final : public NormalTransactionOp { |
4057 | friend class TransactionBase; |
4058 | |
4059 | const ObjectStoreCountParams mParams; |
4060 | ObjectStoreCountResponse mResponse; |
4061 | |
4062 | private: |
4063 | ObjectStoreCountRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4064 | const int64_t aRequestId, |
4065 | const ObjectStoreCountParams& aParams) |
4066 | : NormalTransactionOp(std::move(aTransaction), aRequestId), |
4067 | mParams(aParams) {} |
4068 | |
4069 | ~ObjectStoreCountRequestOp() override = default; |
4070 | |
4071 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4072 | |
4073 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override { |
4074 | aResponse = std::move(mResponse); |
4075 | *aResponseSize = sizeof(uint64_t); |
4076 | } |
4077 | }; |
4078 | |
4079 | class IndexRequestOpBase : public NormalTransactionOp { |
4080 | protected: |
4081 | const SafeRefPtr<FullIndexMetadata> mMetadata; |
4082 | |
4083 | protected: |
4084 | IndexRequestOpBase(SafeRefPtr<TransactionBase> aTransaction, |
4085 | const int64_t aRequestId, const RequestParams& aParams) |
4086 | : NormalTransactionOp(std::move(aTransaction), aRequestId), |
4087 | mMetadata(IndexMetadataForParams(Transaction(), aParams)) {} |
4088 | |
4089 | ~IndexRequestOpBase() override = default; |
4090 | |
4091 | private: |
4092 | static SafeRefPtr<FullIndexMetadata> IndexMetadataForParams( |
4093 | const TransactionBase& aTransaction, const RequestParams& aParams); |
4094 | }; |
4095 | |
4096 | class IndexGetRequestOp final : public IndexRequestOpBase { |
4097 | friend class TransactionBase; |
4098 | |
4099 | SafeRefPtr<Database> mDatabase; |
4100 | const Maybe<SerializedKeyRange> mOptionalKeyRange; |
4101 | AutoTArray<StructuredCloneReadInfoParent, 1> mResponse; |
4102 | PBackgroundParent* mBackgroundParent; |
4103 | const uint32_t mLimit; |
4104 | const bool mGetAll; |
4105 | |
4106 | private: |
4107 | // Only created by TransactionBase. |
4108 | IndexGetRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4109 | const int64_t aRequestId, const RequestParams& aParams, |
4110 | bool aGetAll); |
4111 | |
4112 | ~IndexGetRequestOp() override = default; |
4113 | |
4114 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4115 | |
4116 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override; |
4117 | }; |
4118 | |
4119 | class IndexGetKeyRequestOp final : public IndexRequestOpBase { |
4120 | friend class TransactionBase; |
4121 | |
4122 | const Maybe<SerializedKeyRange> mOptionalKeyRange; |
4123 | AutoTArray<Key, 1> mResponse; |
4124 | const uint32_t mLimit; |
4125 | const bool mGetAll; |
4126 | |
4127 | private: |
4128 | // Only created by TransactionBase. |
4129 | IndexGetKeyRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4130 | const int64_t aRequestId, const RequestParams& aParams, |
4131 | bool aGetAll); |
4132 | |
4133 | ~IndexGetKeyRequestOp() override = default; |
4134 | |
4135 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4136 | |
4137 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override; |
4138 | }; |
4139 | |
4140 | class IndexCountRequestOp final : public IndexRequestOpBase { |
4141 | friend class TransactionBase; |
4142 | |
4143 | const IndexCountParams mParams; |
4144 | IndexCountResponse mResponse; |
4145 | |
4146 | private: |
4147 | // Only created by TransactionBase. |
4148 | IndexCountRequestOp(SafeRefPtr<TransactionBase> aTransaction, |
4149 | const int64_t aRequestId, const RequestParams& aParams) |
4150 | : IndexRequestOpBase(std::move(aTransaction), aRequestId, aParams), |
4151 | mParams(aParams.get_IndexCountParams()) {} |
4152 | |
4153 | ~IndexCountRequestOp() override = default; |
4154 | |
4155 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4156 | |
4157 | void GetResponse(RequestResponse& aResponse, size_t* aResponseSize) override { |
4158 | aResponse = std::move(mResponse); |
4159 | *aResponseSize = sizeof(uint64_t); |
4160 | } |
4161 | }; |
4162 | |
4163 | template <IDBCursorType CursorType> |
4164 | class Cursor; |
4165 | |
4166 | constexpr IDBCursorType ToKeyOnlyType(const IDBCursorType aType) { |
4167 | MOZ_ASSERT(aType == IDBCursorType::ObjectStore ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aType == IDBCursorType::ObjectStore || aType == IDBCursorType ::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType ::Index || aType == IDBCursorType::IndexKey))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4169); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" ")"); do { *((volatile int*)__null) = 4169; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
4168 | aType == IDBCursorType::ObjectStoreKey ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aType == IDBCursorType::ObjectStore || aType == IDBCursorType ::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType ::Index || aType == IDBCursorType::IndexKey))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4169); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" ")"); do { *((volatile int*)__null) = 4169; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
4169 | aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aType == IDBCursorType::ObjectStore || aType == IDBCursorType ::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType ::Index || aType == IDBCursorType::IndexKey))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4169); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" ")"); do { *((volatile int*)__null) = 4169; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4170 | switch (aType) { |
4171 | case IDBCursorType::ObjectStore: |
4172 | [[fallthrough]]; |
4173 | case IDBCursorType::ObjectStoreKey: |
4174 | return IDBCursorType::ObjectStoreKey; |
4175 | case IDBCursorType::Index: |
4176 | [[fallthrough]]; |
4177 | case IDBCursorType::IndexKey: |
4178 | return IDBCursorType::IndexKey; |
4179 | } |
4180 | } |
4181 | |
4182 | template <IDBCursorType CursorType> |
4183 | using CursorPosition = CursorData<ToKeyOnlyType(CursorType)>; |
4184 | |
4185 | #ifdef DEBUG1 |
4186 | constexpr indexedDB::OpenCursorParams::Type ToOpenCursorParamsType( |
4187 | const IDBCursorType aType) { |
4188 | MOZ_ASSERT(aType == IDBCursorType::ObjectStore ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aType == IDBCursorType::ObjectStore || aType == IDBCursorType ::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType ::Index || aType == IDBCursorType::IndexKey))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4190); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" ")"); do { *((volatile int*)__null) = 4190; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
4189 | aType == IDBCursorType::ObjectStoreKey ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aType == IDBCursorType::ObjectStore || aType == IDBCursorType ::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType ::Index || aType == IDBCursorType::IndexKey))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4190); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" ")"); do { *((volatile int*)__null) = 4190; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
4190 | aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aType == IDBCursorType::ObjectStore || aType == IDBCursorType ::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType ::Index || aType == IDBCursorType::IndexKey))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4190); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aType == IDBCursorType::ObjectStore || aType == IDBCursorType::ObjectStoreKey || aType == IDBCursorType::Index || aType == IDBCursorType::IndexKey" ")"); do { *((volatile int*)__null) = 4190; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4191 | switch (aType) { |
4192 | case IDBCursorType::ObjectStore: |
4193 | return indexedDB::OpenCursorParams::TObjectStoreOpenCursorParams; |
4194 | case IDBCursorType::ObjectStoreKey: |
4195 | return indexedDB::OpenCursorParams::TObjectStoreOpenKeyCursorParams; |
4196 | case IDBCursorType::Index: |
4197 | return indexedDB::OpenCursorParams::TIndexOpenCursorParams; |
4198 | case IDBCursorType::IndexKey: |
4199 | return indexedDB::OpenCursorParams::TIndexOpenKeyCursorParams; |
4200 | } |
4201 | } |
4202 | #endif |
4203 | |
4204 | class CursorBase : public PBackgroundIDBCursorParent { |
4205 | friend class TransactionBase; |
4206 | template <IDBCursorType CursorType> |
4207 | friend class CommonOpenOpHelper; |
4208 | |
4209 | protected: |
4210 | const SafeRefPtr<TransactionBase> mTransaction; |
4211 | |
4212 | // This should only be touched on the PBackground thread to check whether |
4213 | // the objectStore has been deleted. Holding these saves a hash lookup for |
4214 | // every call to continue()/advance(). |
4215 | InitializedOnce<const NotNull<SafeRefPtr<FullObjectStoreMetadata>>> |
4216 | mObjectStoreMetadata; |
4217 | |
4218 | const IndexOrObjectStoreId mObjectStoreId; |
4219 | |
4220 | LazyInitializedOnce<const Key> |
4221 | mLocaleAwareRangeBound; ///< If the cursor is based on a key range, the |
4222 | ///< bound in the direction of iteration (e.g. |
4223 | ///< the upper bound in case of mDirection == |
4224 | ///< NEXT). If the cursor is based on a key, it |
4225 | ///< is unset. If mLocale is set, this was |
4226 | ///< converted to mLocale. |
4227 | |
4228 | const Direction mDirection; |
4229 | |
4230 | const int32_t mMaxExtraCount; |
4231 | |
4232 | const bool mIsSameProcessActor; |
4233 | |
4234 | struct ConstructFromTransactionBase {}; |
4235 | |
4236 | public: |
4237 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(mozilla::dom::indexedDB::CursorBase,public: MozExternalRefCountType AddRef(void) final { static_assert (!std::is_destructible_v<mozilla::dom::indexedDB::CursorBase >, "Reference-counted class " "mozilla::dom::indexedDB::CursorBase" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4238); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 4238; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("mozilla::dom::indexedDB::CursorBase"), (uint32_t )(sizeof(*this))); return (nsrefcnt)count; } MozExternalRefCountType Release(void) final { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4238); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 4238 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("mozilla::dom::indexedDB::CursorBase")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public: |
4238 | final)public: MozExternalRefCountType AddRef(void) final { static_assert (!std::is_destructible_v<mozilla::dom::indexedDB::CursorBase >, "Reference-counted class " "mozilla::dom::indexedDB::CursorBase" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4238); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 4238; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("mozilla::dom::indexedDB::CursorBase"), (uint32_t )(sizeof(*this))); return (nsrefcnt)count; } MozExternalRefCountType Release(void) final { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4238); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 4238 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("mozilla::dom::indexedDB::CursorBase")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public: |
4239 | |
4240 | CursorBase(SafeRefPtr<TransactionBase> aTransaction, |
4241 | SafeRefPtr<FullObjectStoreMetadata> aObjectStoreMetadata, |
4242 | Direction aDirection, |
4243 | ConstructFromTransactionBase aConstructionTag); |
4244 | |
4245 | protected: |
4246 | // Reference counted. |
4247 | ~CursorBase() override { MOZ_ASSERT(!mObjectStoreMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mObjectStoreMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mObjectStoreMetadata))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("!mObjectStoreMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4247); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mObjectStoreMetadata" ")"); do { *((volatile int*)__null) = 4247; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } |
4248 | |
4249 | private: |
4250 | virtual bool Start(const int64_t aRequestId, |
4251 | const OpenCursorParams& aParams) = 0; |
4252 | }; |
4253 | |
4254 | class IndexCursorBase : public CursorBase { |
4255 | public: |
4256 | bool IsLocaleAware() const { return !mLocale.IsEmpty(); } |
4257 | |
4258 | IndexCursorBase(SafeRefPtr<TransactionBase> aTransaction, |
4259 | SafeRefPtr<FullObjectStoreMetadata> aObjectStoreMetadata, |
4260 | SafeRefPtr<FullIndexMetadata> aIndexMetadata, |
4261 | Direction aDirection, |
4262 | ConstructFromTransactionBase aConstructionTag) |
4263 | : CursorBase{std::move(aTransaction), std::move(aObjectStoreMetadata), |
4264 | aDirection, aConstructionTag}, |
4265 | mIndexMetadata(WrapNotNull(std::move(aIndexMetadata))), |
4266 | mIndexId((*mIndexMetadata)->mCommonMetadata.id()), |
4267 | mUniqueIndex((*mIndexMetadata)->mCommonMetadata.unique()), |
4268 | mLocale((*mIndexMetadata)->mCommonMetadata.locale()) {} |
4269 | |
4270 | protected: |
4271 | IndexOrObjectStoreId Id() const { return mIndexId; } |
4272 | |
4273 | // This should only be touched on the PBackground thread to check whether |
4274 | // the index has been deleted. Holding these saves a hash lookup for every |
4275 | // call to continue()/advance(). |
4276 | InitializedOnce<const NotNull<SafeRefPtr<FullIndexMetadata>>> mIndexMetadata; |
4277 | const IndexOrObjectStoreId mIndexId; |
4278 | const bool mUniqueIndex; |
4279 | const nsCString |
4280 | mLocale; ///< The locale if the cursor is locale-aware, otherwise empty. |
4281 | |
4282 | struct ContinueQueries { |
4283 | nsCString mContinueQuery; |
4284 | nsCString mContinueToQuery; |
4285 | nsCString mContinuePrimaryKeyQuery; |
4286 | |
4287 | const nsACString& GetContinueQuery(const bool hasContinueKey, |
4288 | const bool hasContinuePrimaryKey) const { |
4289 | return hasContinuePrimaryKey ? mContinuePrimaryKeyQuery |
4290 | : hasContinueKey ? mContinueToQuery |
4291 | : mContinueQuery; |
4292 | } |
4293 | }; |
4294 | }; |
4295 | |
4296 | class ObjectStoreCursorBase : public CursorBase { |
4297 | public: |
4298 | using CursorBase::CursorBase; |
4299 | |
4300 | static constexpr bool IsLocaleAware() { return false; } |
4301 | |
4302 | protected: |
4303 | IndexOrObjectStoreId Id() const { return mObjectStoreId; } |
4304 | |
4305 | struct ContinueQueries { |
4306 | nsCString mContinueQuery; |
4307 | nsCString mContinueToQuery; |
4308 | |
4309 | const nsACString& GetContinueQuery(const bool hasContinueKey, |
4310 | const bool hasContinuePrimaryKey) const { |
4311 | MOZ_ASSERT(!hasContinuePrimaryKey)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!hasContinuePrimaryKey)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!hasContinuePrimaryKey))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!hasContinuePrimaryKey" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4311); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!hasContinuePrimaryKey" ")"); do { *((volatile int*)__null) = 4311; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4312 | return hasContinueKey ? mContinueToQuery : mContinueQuery; |
4313 | } |
4314 | }; |
4315 | }; |
4316 | |
4317 | using FilesArray = nsTArray<nsTArray<StructuredCloneFileParent>>; |
4318 | |
4319 | struct PseudoFilesArray { |
4320 | static constexpr bool IsEmpty() { return true; } |
4321 | |
4322 | static constexpr void Clear() {} |
4323 | }; |
4324 | |
4325 | template <IDBCursorType CursorType> |
4326 | using FilesArrayT = |
4327 | std::conditional_t<!CursorTypeTraits<CursorType>::IsKeyOnlyCursor, |
4328 | FilesArray, PseudoFilesArray>; |
4329 | |
4330 | class ValueCursorBase { |
4331 | friend struct ValuePopulateResponseHelper<true>; |
4332 | friend struct ValuePopulateResponseHelper<false>; |
4333 | |
4334 | protected: |
4335 | explicit ValueCursorBase(TransactionBase* const aTransaction) |
4336 | : mDatabase(aTransaction->GetDatabasePtr()), |
4337 | mFileManager(mDatabase->GetFileManagerPtr()), |
4338 | mBackgroundParent(WrapNotNull(aTransaction->GetBackgroundParent())) { |
4339 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4339); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 4339; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4340 | } |
4341 | |
4342 | void ProcessFiles(CursorResponse& aResponse, const FilesArray& aFiles); |
4343 | |
4344 | ~ValueCursorBase() { MOZ_ASSERT(!mBackgroundParent)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mBackgroundParent)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mBackgroundParent))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mBackgroundParent" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4344); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mBackgroundParent" ")"); do { *((volatile int*)__null) = 4344; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } |
4345 | |
4346 | const SafeRefPtr<Database> mDatabase; |
4347 | const NotNull<SafeRefPtr<DatabaseFileManager>> mFileManager; |
4348 | |
4349 | InitializedOnce<const NotNull<PBackgroundParent*>> mBackgroundParent; |
4350 | }; |
4351 | |
4352 | class KeyCursorBase { |
4353 | protected: |
4354 | explicit KeyCursorBase(TransactionBase* const /*aTransaction*/) {} |
4355 | |
4356 | static constexpr void ProcessFiles(CursorResponse& aResponse, |
4357 | const PseudoFilesArray& aFiles) {} |
4358 | }; |
4359 | |
4360 | template <IDBCursorType CursorType> |
4361 | class CursorOpBaseHelperBase; |
4362 | |
4363 | template <IDBCursorType CursorType> |
4364 | class Cursor final |
4365 | : public std::conditional_t< |
4366 | CursorTypeTraits<CursorType>::IsObjectStoreCursor, |
4367 | ObjectStoreCursorBase, IndexCursorBase>, |
4368 | public std::conditional_t<CursorTypeTraits<CursorType>::IsKeyOnlyCursor, |
4369 | KeyCursorBase, ValueCursorBase> { |
4370 | using Base = |
4371 | std::conditional_t<CursorTypeTraits<CursorType>::IsObjectStoreCursor, |
4372 | ObjectStoreCursorBase, IndexCursorBase>; |
4373 | |
4374 | using KeyValueBase = |
4375 | std::conditional_t<CursorTypeTraits<CursorType>::IsKeyOnlyCursor, |
4376 | KeyCursorBase, ValueCursorBase>; |
4377 | |
4378 | static constexpr bool IsIndexCursor = |
4379 | !CursorTypeTraits<CursorType>::IsObjectStoreCursor; |
4380 | |
4381 | static constexpr bool IsValueCursor = |
4382 | !CursorTypeTraits<CursorType>::IsKeyOnlyCursor; |
4383 | |
4384 | class CursorOpBase; |
4385 | class OpenOp; |
4386 | class ContinueOp; |
4387 | |
4388 | using Base::Id; |
4389 | using CursorBase::Manager; |
4390 | using CursorBase::mDirection; |
4391 | using CursorBase::mObjectStoreId; |
4392 | using CursorBase::mTransaction; |
4393 | using typename CursorBase::ActorDestroyReason; |
4394 | |
4395 | using TypedOpenOpHelper = |
4396 | std::conditional_t<IsIndexCursor, IndexOpenOpHelper<CursorType>, |
4397 | ObjectStoreOpenOpHelper<CursorType>>; |
4398 | |
4399 | friend class CursorOpBaseHelperBase<CursorType>; |
4400 | friend class CommonOpenOpHelper<CursorType>; |
4401 | friend TypedOpenOpHelper; |
4402 | friend class OpenOpHelper<CursorType>; |
4403 | |
4404 | CursorOpBase* mCurrentlyRunningOp = nullptr; |
4405 | |
4406 | LazyInitializedOnce<const typename Base::ContinueQueries> mContinueQueries; |
4407 | |
4408 | // Only called by TransactionBase. |
4409 | bool Start(const int64_t aRequestId, const OpenCursorParams& aParams) final; |
4410 | |
4411 | void SendResponseInternal(CursorResponse& aResponse, |
4412 | const FilesArrayT<CursorType>& aFiles); |
4413 | |
4414 | // Must call SendResponseInternal! |
4415 | bool SendResponse(const CursorResponse& aResponse) = delete; |
4416 | |
4417 | // IPDL methods. |
4418 | void ActorDestroy(ActorDestroyReason aWhy) override; |
4419 | |
4420 | mozilla::ipc::IPCResult RecvDeleteMe() override; |
4421 | |
4422 | mozilla::ipc::IPCResult RecvContinue( |
4423 | const int64_t& aRequestId, const CursorRequestParams& aParams, |
4424 | const Key& aCurrentKey, const Key& aCurrentObjectStoreKey) override; |
4425 | |
4426 | public: |
4427 | Cursor(SafeRefPtr<TransactionBase> aTransaction, |
4428 | SafeRefPtr<FullObjectStoreMetadata> aObjectStoreMetadata, |
4429 | SafeRefPtr<FullIndexMetadata> aIndexMetadata, |
4430 | typename Base::Direction aDirection, |
4431 | typename Base::ConstructFromTransactionBase aConstructionTag) |
4432 | : Base{std::move(aTransaction), std::move(aObjectStoreMetadata), |
4433 | std::move(aIndexMetadata), aDirection, aConstructionTag}, |
4434 | KeyValueBase{this->mTransaction.unsafeGetRawPtr()} {} |
4435 | |
4436 | Cursor(SafeRefPtr<TransactionBase> aTransaction, |
4437 | SafeRefPtr<FullObjectStoreMetadata> aObjectStoreMetadata, |
4438 | typename Base::Direction aDirection, |
4439 | typename Base::ConstructFromTransactionBase aConstructionTag) |
4440 | : Base{std::move(aTransaction), std::move(aObjectStoreMetadata), |
4441 | aDirection, aConstructionTag}, |
4442 | KeyValueBase{this->mTransaction.unsafeGetRawPtr()} {} |
4443 | |
4444 | private: |
4445 | void SetOptionalKeyRange(const Maybe<SerializedKeyRange>& aOptionalKeyRange, |
4446 | bool* aOpen); |
4447 | |
4448 | bool VerifyRequestParams(const CursorRequestParams& aParams, |
4449 | const CursorPosition<CursorType>& aPosition) const; |
4450 | |
4451 | ~Cursor() final = default; |
4452 | }; |
4453 | |
4454 | template <IDBCursorType CursorType> |
4455 | class Cursor<CursorType>::CursorOpBase |
4456 | : public TransactionDatabaseOperationBase { |
4457 | friend class CursorOpBaseHelperBase<CursorType>; |
4458 | |
4459 | protected: |
4460 | RefPtr<Cursor> mCursor; |
4461 | FilesArrayT<CursorType> mFiles; // TODO: Consider removing this member |
4462 | // entirely if we are no value cursor. |
4463 | |
4464 | CursorResponse mResponse; |
4465 | |
4466 | #ifdef DEBUG1 |
4467 | bool mResponseSent; |
4468 | #endif |
4469 | |
4470 | protected: |
4471 | explicit CursorOpBase(Cursor* aCursor, const int64_t aRequestId) |
4472 | : TransactionDatabaseOperationBase(aCursor->mTransaction.clonePtr(), |
4473 | /* aRequestId */ aRequestId), |
4474 | mCursor(aCursor) |
4475 | #ifdef DEBUG1 |
4476 | , |
4477 | mResponseSent(false) |
4478 | #endif |
4479 | { |
4480 | AssertIsOnBackgroundThread(); |
4481 | MOZ_ASSERT(aCursor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCursor)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCursor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aCursor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4481); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCursor" ")" ); do { *((volatile int*)__null) = 4481; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4482 | } |
4483 | |
4484 | ~CursorOpBase() override = default; |
4485 | |
4486 | bool SendFailureResult(nsresult aResultCode) final; |
4487 | nsresult SendSuccessResult() final; |
4488 | |
4489 | void Cleanup() override; |
4490 | }; |
4491 | |
4492 | template <IDBCursorType CursorType> |
4493 | class OpenOpHelper; |
4494 | |
4495 | using ResponseSizeOrError = Result<size_t, nsresult>; |
4496 | |
4497 | template <IDBCursorType CursorType> |
4498 | class CursorOpBaseHelperBase { |
4499 | public: |
4500 | explicit CursorOpBaseHelperBase( |
4501 | typename Cursor<CursorType>::CursorOpBase& aOp) |
4502 | : mOp{aOp} {} |
4503 | |
4504 | ResponseSizeOrError PopulateResponseFromStatement(mozIStorageStatement* aStmt, |
4505 | bool aInitializeResponse, |
4506 | Key* const aOptOutSortKey); |
4507 | |
4508 | void PopulateExtraResponses(mozIStorageStatement* aStmt, |
4509 | uint32_t aMaxExtraCount, |
4510 | const size_t aInitialResponseSize, |
4511 | const nsACString& aOperation, |
4512 | Key* const aOptPreviousSortKey); |
4513 | |
4514 | protected: |
4515 | Cursor<CursorType>& GetCursor() { |
4516 | MOZ_ASSERT(mOp.mCursor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOp.mCursor)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOp.mCursor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOp.mCursor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4516); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOp.mCursor" ")"); do { *((volatile int*)__null) = 4516; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4517 | return *mOp.mCursor; |
4518 | } |
4519 | |
4520 | void SetResponse(CursorResponse aResponse) { |
4521 | mOp.mResponse = std::move(aResponse); |
4522 | } |
4523 | |
4524 | protected: |
4525 | typename Cursor<CursorType>::CursorOpBase& mOp; |
4526 | }; |
4527 | |
4528 | class CommonOpenOpHelperBase { |
4529 | protected: |
4530 | static void AppendConditionClause(const nsACString& aColumnName, |
4531 | const nsACString& aStatementParameterName, |
4532 | bool aLessThan, bool aEquals, |
4533 | nsCString& aResult); |
4534 | }; |
4535 | |
4536 | template <IDBCursorType CursorType> |
4537 | class CommonOpenOpHelper : public CursorOpBaseHelperBase<CursorType>, |
4538 | protected CommonOpenOpHelperBase { |
4539 | public: |
4540 | explicit CommonOpenOpHelper(typename Cursor<CursorType>::OpenOp& aOp) |
4541 | : CursorOpBaseHelperBase<CursorType>{aOp} {} |
4542 | |
4543 | protected: |
4544 | using CursorOpBaseHelperBase<CursorType>::GetCursor; |
4545 | using CursorOpBaseHelperBase<CursorType>::PopulateExtraResponses; |
4546 | using CursorOpBaseHelperBase<CursorType>::PopulateResponseFromStatement; |
4547 | using CursorOpBaseHelperBase<CursorType>::SetResponse; |
4548 | |
4549 | const Maybe<SerializedKeyRange>& GetOptionalKeyRange() const { |
4550 | // This downcast is safe, since we initialized mOp from an OpenOp in the |
4551 | // ctor. |
4552 | return static_cast<typename Cursor<CursorType>::OpenOp&>(this->mOp) |
4553 | .mOptionalKeyRange; |
4554 | } |
4555 | |
4556 | nsresult ProcessStatementSteps(mozIStorageStatement* aStmt); |
4557 | }; |
4558 | |
4559 | template <IDBCursorType CursorType> |
4560 | class ObjectStoreOpenOpHelper : protected CommonOpenOpHelper<CursorType> { |
4561 | public: |
4562 | using CommonOpenOpHelper<CursorType>::CommonOpenOpHelper; |
4563 | |
4564 | protected: |
4565 | using CommonOpenOpHelper<CursorType>::GetCursor; |
4566 | using CommonOpenOpHelper<CursorType>::GetOptionalKeyRange; |
4567 | using CommonOpenOpHelper<CursorType>::AppendConditionClause; |
4568 | |
4569 | void PrepareKeyConditionClauses(const nsACString& aDirectionClause, |
4570 | const nsACString& aQueryStart); |
4571 | }; |
4572 | |
4573 | template <IDBCursorType CursorType> |
4574 | class IndexOpenOpHelper : protected CommonOpenOpHelper<CursorType> { |
4575 | public: |
4576 | using CommonOpenOpHelper<CursorType>::CommonOpenOpHelper; |
4577 | |
4578 | protected: |
4579 | using CommonOpenOpHelper<CursorType>::GetCursor; |
4580 | using CommonOpenOpHelper<CursorType>::GetOptionalKeyRange; |
4581 | using CommonOpenOpHelper<CursorType>::AppendConditionClause; |
4582 | |
4583 | void PrepareIndexKeyConditionClause( |
4584 | const nsACString& aDirectionClause, |
4585 | const nsLiteralCString& aObjectDataKeyPrefix, nsAutoCString aQueryStart); |
4586 | }; |
4587 | |
4588 | template <> |
4589 | class OpenOpHelper<IDBCursorType::ObjectStore> |
4590 | : public ObjectStoreOpenOpHelper<IDBCursorType::ObjectStore> { |
4591 | public: |
4592 | using ObjectStoreOpenOpHelper< |
4593 | IDBCursorType::ObjectStore>::ObjectStoreOpenOpHelper; |
4594 | |
4595 | nsresult DoDatabaseWork(DatabaseConnection* aConnection); |
4596 | }; |
4597 | |
4598 | template <> |
4599 | class OpenOpHelper<IDBCursorType::ObjectStoreKey> |
4600 | : public ObjectStoreOpenOpHelper<IDBCursorType::ObjectStoreKey> { |
4601 | public: |
4602 | using ObjectStoreOpenOpHelper< |
4603 | IDBCursorType::ObjectStoreKey>::ObjectStoreOpenOpHelper; |
4604 | |
4605 | nsresult DoDatabaseWork(DatabaseConnection* aConnection); |
4606 | }; |
4607 | |
4608 | template <> |
4609 | class OpenOpHelper<IDBCursorType::Index> |
4610 | : IndexOpenOpHelper<IDBCursorType::Index> { |
4611 | private: |
4612 | void PrepareKeyConditionClauses(const nsACString& aDirectionClause, |
4613 | nsAutoCString aQueryStart) { |
4614 | PrepareIndexKeyConditionClause(aDirectionClause, "index_table."_ns, |
4615 | std::move(aQueryStart)); |
4616 | } |
4617 | |
4618 | public: |
4619 | using IndexOpenOpHelper<IDBCursorType::Index>::IndexOpenOpHelper; |
4620 | |
4621 | nsresult DoDatabaseWork(DatabaseConnection* aConnection); |
4622 | }; |
4623 | |
4624 | template <> |
4625 | class OpenOpHelper<IDBCursorType::IndexKey> |
4626 | : IndexOpenOpHelper<IDBCursorType::IndexKey> { |
4627 | private: |
4628 | void PrepareKeyConditionClauses(const nsACString& aDirectionClause, |
4629 | nsAutoCString aQueryStart) { |
4630 | PrepareIndexKeyConditionClause(aDirectionClause, ""_ns, |
4631 | std::move(aQueryStart)); |
4632 | } |
4633 | |
4634 | public: |
4635 | using IndexOpenOpHelper<IDBCursorType::IndexKey>::IndexOpenOpHelper; |
4636 | |
4637 | nsresult DoDatabaseWork(DatabaseConnection* aConnection); |
4638 | }; |
4639 | |
4640 | template <IDBCursorType CursorType> |
4641 | class Cursor<CursorType>::OpenOp final : public CursorOpBase { |
4642 | friend class Cursor<CursorType>; |
4643 | friend class CommonOpenOpHelper<CursorType>; |
4644 | |
4645 | const Maybe<SerializedKeyRange> mOptionalKeyRange; |
4646 | |
4647 | using CursorOpBase::mCursor; |
4648 | using CursorOpBase::mResponse; |
4649 | |
4650 | // Only created by Cursor. |
4651 | OpenOp(Cursor* const aCursor, const int64_t aRequestId, |
4652 | const Maybe<SerializedKeyRange>& aOptionalKeyRange) |
4653 | : CursorOpBase(aCursor, aRequestId), |
4654 | mOptionalKeyRange(aOptionalKeyRange) {} |
4655 | |
4656 | // Reference counted. |
4657 | ~OpenOp() override = default; |
4658 | |
4659 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4660 | }; |
4661 | |
4662 | template <IDBCursorType CursorType> |
4663 | class Cursor<CursorType>::ContinueOp final |
4664 | : public Cursor<CursorType>::CursorOpBase { |
4665 | friend class Cursor<CursorType>; |
4666 | |
4667 | using CursorOpBase::mCursor; |
4668 | using CursorOpBase::mResponse; |
4669 | const CursorRequestParams mParams; |
4670 | |
4671 | // Only created by Cursor. |
4672 | ContinueOp(Cursor* const aCursor, int64_t aRequestId, |
4673 | CursorRequestParams aParams, CursorPosition<CursorType> aPosition) |
4674 | : CursorOpBase(aCursor, aRequestId), |
4675 | mParams(std::move(aParams)), |
4676 | mCurrentPosition{std::move(aPosition)} { |
4677 | MOZ_ASSERT(mParams.type() != CursorRequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mParams.type() != CursorRequestParams::T__None)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mParams.type() != CursorRequestParams::T__None))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mParams.type() != CursorRequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4677); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mParams.type() != CursorRequestParams::T__None" ")"); do { *((volatile int*)__null) = 4677; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4678 | } |
4679 | |
4680 | // Reference counted. |
4681 | ~ContinueOp() override = default; |
4682 | |
4683 | nsresult DoDatabaseWork(DatabaseConnection* aConnection) override; |
4684 | |
4685 | const CursorPosition<CursorType> mCurrentPosition; |
4686 | }; |
4687 | |
4688 | class Utils final : public PBackgroundIndexedDBUtilsParent { |
4689 | #ifdef DEBUG1 |
4690 | bool mActorDestroyed; |
4691 | #endif |
4692 | |
4693 | public: |
4694 | Utils(); |
4695 | |
4696 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(mozilla::dom::indexedDB::Utils)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<mozilla::dom::indexedDB::Utils> , "Reference-counted class " "mozilla::dom::indexedDB::Utils" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4696); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 4696; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("mozilla::dom::indexedDB::Utils"), (uint32_t)(sizeof (*this))); return (nsrefcnt)count; } MozExternalRefCountType Release (void) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4696); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 4696 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("mozilla::dom::indexedDB::Utils")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public: |
4697 | |
4698 | private: |
4699 | // Reference counted. |
4700 | ~Utils() override; |
4701 | |
4702 | // IPDL methods are only called by IPDL. |
4703 | void ActorDestroy(ActorDestroyReason aWhy) override; |
4704 | |
4705 | mozilla::ipc::IPCResult RecvDeleteMe() override; |
4706 | |
4707 | mozilla::ipc::IPCResult RecvGetFileReferences( |
4708 | const PersistenceType& aPersistenceType, const nsACString& aOrigin, |
4709 | const nsAString& aDatabaseName, const int64_t& aFileId, int32_t* aRefCnt, |
4710 | int32_t* aDBRefCnt, bool* aResult) override; |
4711 | |
4712 | mozilla::ipc::IPCResult RecvDoMaintenance( |
4713 | DoMaintenanceResolver&& aResolver) override; |
4714 | }; |
4715 | |
4716 | /******************************************************************************* |
4717 | * Other class declarations |
4718 | ******************************************************************************/ |
4719 | |
4720 | struct DatabaseActorInfo final { |
4721 | friend class mozilla::DefaultDelete<DatabaseActorInfo>; |
4722 | |
4723 | SafeRefPtr<FullDatabaseMetadata> mMetadata; |
4724 | nsTArray<NotNull<CheckedUnsafePtr<Database>>> mLiveDatabases; |
4725 | RefPtr<FactoryOp> mWaitingFactoryOp; |
4726 | |
4727 | DatabaseActorInfo(SafeRefPtr<FullDatabaseMetadata> aMetadata, |
4728 | NotNull<Database*> aDatabase) |
4729 | : mMetadata(std::move(aMetadata)) { |
4730 | MOZ_COUNT_CTOR(DatabaseActorInfo)do { static_assert(std::is_class_v<DatabaseActorInfo>, "Token '" "DatabaseActorInfo" "' is not a class type."); static_assert (!std::is_base_of<nsISupports, DatabaseActorInfo>::value , "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "DatabaseActorInfo" , sizeof(*this)); } while (0); |
4731 | |
4732 | mLiveDatabases.AppendElement(aDatabase); |
4733 | } |
4734 | |
4735 | private: |
4736 | ~DatabaseActorInfo() { |
4737 | MOZ_ASSERT(mLiveDatabases.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLiveDatabases.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mLiveDatabases.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mLiveDatabases.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4737); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLiveDatabases.IsEmpty()" ")"); do { *((volatile int*)__null) = 4737; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4738 | MOZ_ASSERT(!mWaitingFactoryOp || !mWaitingFactoryOp->HasBlockedDatabases())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mWaitingFactoryOp || !mWaitingFactoryOp->HasBlockedDatabases ())>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!mWaitingFactoryOp || !mWaitingFactoryOp->HasBlockedDatabases ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mWaitingFactoryOp || !mWaitingFactoryOp->HasBlockedDatabases()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4738); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mWaitingFactoryOp || !mWaitingFactoryOp->HasBlockedDatabases()" ")"); do { *((volatile int*)__null) = 4738; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4739 | |
4740 | MOZ_COUNT_DTOR(DatabaseActorInfo)do { static_assert(std::is_class_v<DatabaseActorInfo>, "Token '" "DatabaseActorInfo" "' is not a class type."); static_assert (!std::is_base_of<nsISupports, DatabaseActorInfo>::value , "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "DatabaseActorInfo" , sizeof(*this)); } while (0); |
4741 | } |
4742 | }; |
4743 | |
4744 | class DatabaseLoggingInfo final { |
4745 | #ifdef DEBUG1 |
4746 | // Just for potential warnings. |
4747 | friend class Factory; |
4748 | #endif |
4749 | |
4750 | LoggingInfo mLoggingInfo; |
4751 | |
4752 | public: |
4753 | explicit DatabaseLoggingInfo(const LoggingInfo& aLoggingInfo) |
4754 | : mLoggingInfo(aLoggingInfo) { |
4755 | AssertIsOnBackgroundThread(); |
4756 | MOZ_ASSERT(aLoggingInfo.nextTransactionSerialNumber())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aLoggingInfo.nextTransactionSerialNumber())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aLoggingInfo.nextTransactionSerialNumber()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aLoggingInfo.nextTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4756); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aLoggingInfo.nextTransactionSerialNumber()" ")"); do { *((volatile int*)__null) = 4756; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4757 | MOZ_ASSERT(aLoggingInfo.nextVersionChangeTransactionSerialNumber())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aLoggingInfo.nextVersionChangeTransactionSerialNumber ())>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aLoggingInfo.nextVersionChangeTransactionSerialNumber ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aLoggingInfo.nextVersionChangeTransactionSerialNumber()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4757); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aLoggingInfo.nextVersionChangeTransactionSerialNumber()" ")"); do { *((volatile int*)__null) = 4757; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4758 | MOZ_ASSERT(aLoggingInfo.nextRequestSerialNumber())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aLoggingInfo.nextRequestSerialNumber())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aLoggingInfo.nextRequestSerialNumber()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aLoggingInfo.nextRequestSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4758); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aLoggingInfo.nextRequestSerialNumber()" ")"); do { *((volatile int*)__null) = 4758; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4759 | } |
4760 | |
4761 | const nsID& Id() const { |
4762 | AssertIsOnBackgroundThread(); |
4763 | |
4764 | return mLoggingInfo.backgroundChildLoggingId(); |
4765 | } |
4766 | |
4767 | int64_t NextTransactionSN(IDBTransaction::Mode aMode) { |
4768 | AssertIsOnBackgroundThread(); |
4769 | MOZ_ASSERT(mLoggingInfo.nextTransactionSerialNumber() < INT64_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLoggingInfo.nextTransactionSerialNumber() < (9223372036854775807L ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mLoggingInfo.nextTransactionSerialNumber() < (9223372036854775807L )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mLoggingInfo.nextTransactionSerialNumber() < (9223372036854775807L)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4769); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLoggingInfo.nextTransactionSerialNumber() < (9223372036854775807L)" ")"); do { *((volatile int*)__null) = 4769; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4770 | MOZ_ASSERT(mLoggingInfo.nextVersionChangeTransactionSerialNumber() >do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLoggingInfo.nextVersionChangeTransactionSerialNumber () > (-9223372036854775807L -1))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mLoggingInfo.nextVersionChangeTransactionSerialNumber () > (-9223372036854775807L -1)))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("mLoggingInfo.nextVersionChangeTransactionSerialNumber() > (-9223372036854775807L-1)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4771); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLoggingInfo.nextVersionChangeTransactionSerialNumber() > (-9223372036854775807L-1)" ")"); do { *((volatile int*)__null) = 4771; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
4771 | INT64_MIN)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLoggingInfo.nextVersionChangeTransactionSerialNumber () > (-9223372036854775807L -1))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mLoggingInfo.nextVersionChangeTransactionSerialNumber () > (-9223372036854775807L -1)))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("mLoggingInfo.nextVersionChangeTransactionSerialNumber() > (-9223372036854775807L-1)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4771); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLoggingInfo.nextVersionChangeTransactionSerialNumber() > (-9223372036854775807L-1)" ")"); do { *((volatile int*)__null) = 4771; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4772 | |
4773 | if (aMode == IDBTransaction::Mode::VersionChange) { |
4774 | return mLoggingInfo.nextVersionChangeTransactionSerialNumber()--; |
4775 | } |
4776 | |
4777 | return mLoggingInfo.nextTransactionSerialNumber()++; |
4778 | } |
4779 | |
4780 | uint64_t NextRequestSN() { |
4781 | AssertIsOnBackgroundThread(); |
4782 | MOZ_ASSERT(mLoggingInfo.nextRequestSerialNumber() < UINT64_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLoggingInfo.nextRequestSerialNumber() < (18446744073709551615UL ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mLoggingInfo.nextRequestSerialNumber() < (18446744073709551615UL )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mLoggingInfo.nextRequestSerialNumber() < (18446744073709551615UL)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4782); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLoggingInfo.nextRequestSerialNumber() < (18446744073709551615UL)" ")"); do { *((volatile int*)__null) = 4782; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4783 | |
4784 | return mLoggingInfo.nextRequestSerialNumber()++; |
4785 | } |
4786 | |
4787 | NS_INLINE_DECL_REFCOUNTING(DatabaseLoggingInfo)public: MozExternalRefCountType AddRef(void) { static_assert( !std::is_destructible_v<DatabaseLoggingInfo>, "Reference-counted class " "DatabaseLoggingInfo" " should not have a public destructor. " "Make this class's destructor non-public"); do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4787); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 4787; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); _mOwningThread.AssertOwnership("DatabaseLoggingInfo" " not thread-safe"); ++mRefCnt; NS_LogAddRef((this), (mRefCnt ), ("DatabaseLoggingInfo"), (uint32_t)(sizeof(*this))); return mRefCnt; } MozExternalRefCountType Release(void) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(int32_t (mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4787); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 4787 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); _mOwningThread.AssertOwnership("DatabaseLoggingInfo" " not thread-safe"); --mRefCnt; NS_LogRelease((this), (mRefCnt ), ("DatabaseLoggingInfo")); if (mRefCnt == 0) { mRefCnt = 1; delete (this); return 0; } return mRefCnt; } using HasThreadSafeRefCnt = std::false_type; protected: nsAutoRefCnt mRefCnt; nsAutoOwningThread _mOwningThread; public: |
4788 | |
4789 | private: |
4790 | ~DatabaseLoggingInfo(); |
4791 | }; |
4792 | |
4793 | class QuotaClient final : public mozilla::dom::quota::Client { |
4794 | friend class GetDatabasesOp; |
4795 | |
4796 | static QuotaClient* sInstance; |
4797 | |
4798 | nsCOMPtr<nsIEventTarget> mBackgroundThread; |
4799 | nsCOMPtr<nsITimer> mDeleteTimer; |
4800 | nsTArray<RefPtr<Maintenance>> mMaintenanceQueue; |
4801 | RefPtr<Maintenance> mCurrentMaintenance; |
4802 | RefPtr<nsThreadPool> mMaintenanceThreadPool; |
4803 | nsClassHashtable<nsRefPtrHashKey<DatabaseFileManager>, nsTArray<int64_t>> |
4804 | mPendingDeleteInfos; |
4805 | |
4806 | public: |
4807 | QuotaClient(); |
4808 | |
4809 | static QuotaClient* GetInstance() { |
4810 | AssertIsOnBackgroundThread(); |
4811 | |
4812 | return sInstance; |
4813 | } |
4814 | |
4815 | nsIEventTarget* BackgroundThread() const { |
4816 | MOZ_ASSERT(mBackgroundThread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mBackgroundThread)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mBackgroundThread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mBackgroundThread" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4816); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mBackgroundThread" ")"); do { *((volatile int*)__null) = 4816; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4817 | return mBackgroundThread; |
4818 | } |
4819 | |
4820 | nsresult AsyncDeleteFile(DatabaseFileManager* aFileManager, int64_t aFileId); |
4821 | |
4822 | nsresult FlushPendingFileDeletions(); |
4823 | |
4824 | RefPtr<BoolPromise> DoMaintenance(); |
4825 | |
4826 | RefPtr<Maintenance> GetCurrentMaintenance() const { |
4827 | return mCurrentMaintenance; |
4828 | } |
4829 | |
4830 | void NoteFinishedMaintenance(Maintenance* aMaintenance) { |
4831 | AssertIsOnBackgroundThread(); |
4832 | MOZ_ASSERT(aMaintenance)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMaintenance)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMaintenance))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aMaintenance", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4832); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMaintenance" ")"); do { *((volatile int*)__null) = 4832; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4833 | MOZ_ASSERT(mCurrentMaintenance == aMaintenance)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mCurrentMaintenance == aMaintenance)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mCurrentMaintenance == aMaintenance ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "mCurrentMaintenance == aMaintenance", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4833); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCurrentMaintenance == aMaintenance" ")"); do { *((volatile int*)__null) = 4833; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
4834 | |
4835 | mCurrentMaintenance = nullptr; |
4836 | |
4837 | QuotaManager::MaybeRecordQuotaClientShutdownStep(quota::Client::IDB, |
4838 | "Maintenance finished"_ns); |
4839 | |
4840 | ProcessMaintenanceQueue(); |
4841 | } |
4842 | |
4843 | nsThreadPool* GetOrCreateThreadPool(); |
4844 | |
4845 | NS_INLINE_DECL_THREADSAFE_REFCOUNTING(mozilla::dom::indexedDB::QuotaClient,public: MozExternalRefCountType AddRef(void) override { static_assert (!std::is_destructible_v<mozilla::dom::indexedDB::QuotaClient >, "Reference-counted class " "mozilla::dom::indexedDB::QuotaClient" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4846); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 4846; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("mozilla::dom::indexedDB::QuotaClient"), (uint32_t )(sizeof(*this))); return (nsrefcnt)count; } MozExternalRefCountType Release(void) override { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(int32_t(mRefCnt) > 0) >::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(int32_t(mRefCnt) > 0))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4846); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 4846 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("mozilla::dom::indexedDB::QuotaClient")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public: |
4846 | override)public: MozExternalRefCountType AddRef(void) override { static_assert (!std::is_destructible_v<mozilla::dom::indexedDB::QuotaClient >, "Reference-counted class " "mozilla::dom::indexedDB::QuotaClient" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4846); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 4846; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = ++mRefCnt; NS_LogAddRef((this ), (count), ("mozilla::dom::indexedDB::QuotaClient"), (uint32_t )(sizeof(*this))); return (nsrefcnt)count; } MozExternalRefCountType Release(void) override { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(int32_t(mRefCnt) > 0) >::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(int32_t(mRefCnt) > 0))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 4846); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 4846 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); nsrefcnt count = --mRefCnt; NS_LogRelease((this), ( count), ("mozilla::dom::indexedDB::QuotaClient")); if (count == 0) { delete (this); return 0; } return count; } using HasThreadSafeRefCnt = std::true_type; protected: ::mozilla::ThreadSafeAutoRefCnt mRefCnt; public: |
4847 | |
4848 | mozilla::dom::quota::Client::Type GetType() override; |
4849 | |
4850 | nsresult UpgradeStorageFrom1_0To2_0(nsIFile* aDirectory) override; |
4851 | |
4852 | nsresult UpgradeStorageFrom2_1To2_2(nsIFile* aDirectory) override; |
4853 | |
4854 | Result<UsageInfo, nsresult> InitOrigin(PersistenceType aPersistenceType, |
4855 | const OriginMetadata& aOriginMetadata, |
4856 | const AtomicBool& aCanceled) override; |
4857 | |
4858 | nsresult InitOriginWithoutTracking(PersistenceType aPersistenceType, |
4859 | const OriginMetadata& aOriginMetadata, |
4860 | const AtomicBool& aCanceled) override; |
4861 | |
4862 | Result<UsageInfo, nsresult> GetUsageForOrigin( |
4863 | PersistenceType aPersistenceType, const OriginMetadata& aOriginMetadata, |
4864 | const AtomicBool& aCanceled) override; |
4865 | |
4866 | void OnOriginClearCompleted(const OriginMetadata& aOriginMetadata) override; |
4867 | |
4868 | void OnRepositoryClearCompleted(PersistenceType aPersistenceType) override; |
4869 | |
4870 | void ReleaseIOThreadObjects() override; |
4871 | |
4872 | void AbortOperationsForLocks( |
4873 | const DirectoryLockIdTable& aDirectoryLockIds) override; |
4874 | |
4875 | void AbortOperationsForProcess(ContentParentId aContentParentId) override; |
4876 | |
4877 | void AbortAllOperations() override; |
4878 | |
4879 | void StartIdleMaintenance() override; |
4880 | |
4881 | void StopIdleMaintenance() override; |
4882 | |
4883 | private: |
4884 | ~QuotaClient() override; |
4885 | |
4886 | void InitiateShutdown() override; |
4887 | bool IsShutdownCompleted() const override; |
4888 | nsCString GetShutdownStatus() const override; |
4889 | void ForceKillActors() override; |
4890 | void FinalizeShutdown() override; |
4891 | |
4892 | static void DeleteTimerCallback(nsITimer* aTimer, void* aClosure); |
4893 | |
4894 | void AbortAllMaintenances(); |
4895 | |
4896 | Result<nsCOMPtr<nsIFile>, nsresult> GetDirectory( |
4897 | const OriginMetadata& aOriginMetadata); |
4898 | |
4899 | struct SubdirectoriesToProcessAndDatabaseFilenames { |
4900 | AutoTArray<nsString, 20> subdirsToProcess; |
4901 | nsTHashSet<nsString> databaseFilenames{20}; |
4902 | }; |
4903 | |
4904 | struct SubdirectoriesToProcessAndDatabaseFilenamesAndObsoleteFilenames { |
4905 | AutoTArray<nsString, 20> subdirsToProcess; |
4906 | nsTHashSet<nsString> databaseFilenames{20}; |
4907 | nsTHashSet<nsString> obsoleteFilenames{20}; |
4908 | }; |
4909 | |
4910 | enum class ObsoleteFilenamesHandling { Include, Omit }; |
4911 | |
4912 | template <ObsoleteFilenamesHandling ObsoleteFilenames> |
4913 | using GetDatabaseFilenamesResult = std::conditional_t< |
4914 | ObsoleteFilenames == ObsoleteFilenamesHandling::Include, |
4915 | SubdirectoriesToProcessAndDatabaseFilenamesAndObsoleteFilenames, |
4916 | SubdirectoriesToProcessAndDatabaseFilenames>; |
4917 | |
4918 | // Returns a two-part or three-part structure: |
4919 | // |
4920 | // The first part is an array of subdirectories to process. |
4921 | // |
4922 | // The second part is a hashtable of database filenames. |
4923 | // |
4924 | // When ObsoleteFilenames is ObsoleteFilenamesHandling::Include, will also |
4925 | // collect files based on the marker files. For now, |
4926 | // GetUsageForOriginInternal() is the only consumer of this result because it |
4927 | // checks those unfinished deletion and clean them up after that. |
4928 | template <ObsoleteFilenamesHandling ObsoleteFilenames = |
4929 | ObsoleteFilenamesHandling::Omit> |
4930 | Result<GetDatabaseFilenamesResult<ObsoleteFilenames>, |
4931 | nsresult> static GetDatabaseFilenames(nsIFile& aDirectory, |
4932 | const AtomicBool& aCanceled); |
4933 | |
4934 | nsresult GetUsageForOriginInternal(PersistenceType aPersistenceType, |
4935 | const OriginMetadata& aOriginMetadata, |
4936 | const AtomicBool& aCanceled, |
4937 | bool aInitializing, UsageInfo* aUsageInfo); |
4938 | |
4939 | // Runs on the PBackground thread. Checks to see if there's a queued |
4940 | // Maintenance to run. |
4941 | void ProcessMaintenanceQueue(); |
4942 | }; |
4943 | |
4944 | class DeleteFilesRunnable final : public Runnable { |
4945 | using ClientDirectoryLock = mozilla::dom::quota::ClientDirectoryLock; |
4946 | |
4947 | enum State { |
4948 | // Just created on the PBackground thread. Next step is |
4949 | // State_DirectoryOpenPending. |
4950 | State_Initial, |
4951 | |
4952 | // Waiting for directory open allowed on the main thread. The next step is |
4953 | // State_DatabaseWorkOpen. |
4954 | State_DirectoryOpenPending, |
4955 | |
4956 | // Waiting to do/doing work on the QuotaManager IO thread. The next step is |
4957 | // State_UnblockingOpen. |
4958 | State_DatabaseWorkOpen, |
4959 | |
4960 | // Notifying the QuotaManager that it can proceed to the next operation on |
4961 | // the main thread. Next step is State_Completed. |
4962 | State_UnblockingOpen, |
4963 | |
4964 | // All done. |
4965 | State_Completed |
4966 | }; |
4967 | |
4968 | nsCOMPtr<nsIEventTarget> mOwningEventTarget; |
4969 | SafeRefPtr<DatabaseFileManager> mFileManager; |
4970 | RefPtr<ClientDirectoryLock> mDirectoryLock; |
4971 | nsTArray<int64_t> mFileIds; |
4972 | State mState; |
4973 | DEBUGONLY(bool mDEBUGCountsAsPending = false)bool mDEBUGCountsAsPending = false; |
4974 | |
4975 | static uint64_t sPendingRunnables; |
4976 | |
4977 | public: |
4978 | DeleteFilesRunnable(SafeRefPtr<DatabaseFileManager> aFileManager, |
4979 | nsTArray<int64_t>&& aFileIds); |
4980 | |
4981 | void RunImmediately(); |
4982 | |
4983 | static bool IsDeletionPending() { return sPendingRunnables > 0; } |
4984 | |
4985 | private: |
4986 | #ifdef DEBUG1 |
4987 | ~DeleteFilesRunnable(); |
4988 | #else |
4989 | ~DeleteFilesRunnable() = default; |
4990 | #endif |
4991 | |
4992 | void Open(); |
4993 | |
4994 | void DoDatabaseWork(); |
4995 | |
4996 | void Finish(); |
4997 | |
4998 | void UnblockOpen(); |
4999 | |
5000 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
5001 | |
5002 | void DirectoryLockAcquired(ClientDirectoryLock* aLock); |
5003 | |
5004 | void DirectoryLockFailed(); |
5005 | }; |
5006 | |
5007 | class Maintenance final : public Runnable { |
5008 | struct DirectoryInfo final { |
5009 | InitializedOnce<const OriginMetadata> mOriginMetadata; |
5010 | InitializedOnce<const nsTArray<nsString>> mDatabasePaths; |
5011 | const PersistenceType mPersistenceType; |
5012 | |
5013 | DirectoryInfo(PersistenceType aPersistenceType, |
5014 | OriginMetadata aOriginMetadata, |
5015 | nsTArray<nsString>&& aDatabasePaths); |
5016 | |
5017 | DirectoryInfo(const DirectoryInfo& aOther) = delete; |
5018 | DirectoryInfo(DirectoryInfo&& aOther) = delete; |
5019 | |
5020 | ~DirectoryInfo() { MOZ_COUNT_DTOR(Maintenance::DirectoryInfo)do { static_assert(std::is_class_v<Maintenance::DirectoryInfo >, "Token '" "Maintenance::DirectoryInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, Maintenance ::DirectoryInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "Maintenance::DirectoryInfo" , sizeof(*this)); } while (0); } |
5021 | }; |
5022 | |
5023 | enum class State { |
5024 | // Newly created on the PBackground thread. Will proceed immediately or be |
5025 | // added to the maintenance queue. The next step is either |
5026 | // DirectoryOpenPending if IndexedDatabaseManager is running, or |
5027 | // CreateIndexedDatabaseManager if not. |
5028 | Initial = 0, |
5029 | |
5030 | // Create IndexedDatabaseManager on the main thread. The next step is either |
5031 | // Finishing if IndexedDatabaseManager initialization fails, or |
5032 | // IndexedDatabaseManagerOpen if initialization succeeds. |
5033 | CreateIndexedDatabaseManager, |
5034 | |
5035 | // Call OpenDirectory() on the PBackground thread. The next step is |
5036 | // DirectoryOpenPending. |
5037 | IndexedDatabaseManagerOpen, |
5038 | |
5039 | // Waiting for directory open allowed on the PBackground thread. The next |
5040 | // step is either Finishing if directory lock failed to acquire, or |
5041 | // DirectoryWorkOpen if directory lock is acquired. |
5042 | DirectoryOpenPending, |
5043 | |
5044 | // Waiting to do/doing work on the QuotaManager IO thread. The next step is |
5045 | // BeginDatabaseMaintenance. |
5046 | DirectoryWorkOpen, |
5047 | |
5048 | // Dispatching a runnable for each database on the PBackground thread. The |
5049 | // next state is either WaitingForDatabaseMaintenancesToComplete if at least |
5050 | // one runnable has been dispatched, or Finishing otherwise. |
5051 | BeginDatabaseMaintenance, |
5052 | |
5053 | // Waiting for DatabaseMaintenance to finish on maintenance thread pool. |
5054 | // The next state is Finishing if the last runnable has finished. |
5055 | WaitingForDatabaseMaintenancesToComplete, |
5056 | |
5057 | // Waiting to finish/finishing on the PBackground thread. The next step is |
5058 | // Completed. |
5059 | Finishing, |
5060 | |
5061 | // All done. |
5062 | Complete |
5063 | }; |
5064 | |
5065 | RefPtr<QuotaClient> mQuotaClient; |
5066 | MozPromiseHolder<BoolPromise> mPromiseHolder; |
5067 | PRTime mStartTime; |
5068 | RefPtr<UniversalDirectoryLock> mPendingDirectoryLock; |
5069 | // The directory lock is normally dropped by BeginDatabaseMaintenance, but if |
5070 | // something fails (in any method), the Finish method will do the cleanup. |
5071 | RefPtr<UniversalDirectoryLock> mDirectoryLock; |
5072 | nsTArray<nsCOMPtr<nsIRunnable>> mCompleteCallbacks; |
5073 | nsTArray<DirectoryInfo> mDirectoryInfos; |
5074 | nsTHashMap<nsStringHashKey, DatabaseMaintenance*> mDatabaseMaintenances; |
5075 | nsresult mResultCode; |
5076 | Atomic<bool> mAborted; |
5077 | bool mOpenStorageForAllRepositoriesFailed; |
5078 | State mState; |
5079 | |
5080 | public: |
5081 | explicit Maintenance(QuotaClient* aQuotaClient) |
5082 | : Runnable("dom::indexedDB::Maintenance"), |
5083 | mQuotaClient(aQuotaClient), |
5084 | mStartTime(PR_Now()), |
5085 | mResultCode(NS_OK), |
5086 | mAborted(false), |
5087 | mOpenStorageForAllRepositoriesFailed(false), |
5088 | mState(State::Initial) { |
5089 | AssertIsOnBackgroundThread(); |
5090 | MOZ_ASSERT(aQuotaClient)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aQuotaClient)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aQuotaClient))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aQuotaClient", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5090); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aQuotaClient" ")"); do { *((volatile int*)__null) = 5090; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5091 | MOZ_ASSERT(QuotaClient::GetInstance() == aQuotaClient)do { static_assert( mozilla::detail::AssertionConditionType< decltype(QuotaClient::GetInstance() == aQuotaClient)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(QuotaClient::GetInstance() == aQuotaClient))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("QuotaClient::GetInstance() == aQuotaClient" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5091); AnnotateMozCrashReason("MOZ_ASSERT" "(" "QuotaClient::GetInstance() == aQuotaClient" ")"); do { *((volatile int*)__null) = 5091; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5092 | MOZ_ASSERT(mStartTime)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mStartTime)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mStartTime))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mStartTime", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5092); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mStartTime" ")"); do { *((volatile int*)__null) = 5092; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5093 | } |
5094 | |
5095 | nsIEventTarget* BackgroundThread() const { |
5096 | MOZ_ASSERT(mQuotaClient)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mQuotaClient)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mQuotaClient))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mQuotaClient", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5096); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mQuotaClient" ")"); do { *((volatile int*)__null) = 5096; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5097 | return mQuotaClient->BackgroundThread(); |
5098 | } |
5099 | |
5100 | PRTime StartTime() const { return mStartTime; } |
5101 | |
5102 | bool IsAborted() const { return mAborted; } |
5103 | |
5104 | void RunImmediately() { |
5105 | MOZ_ASSERT(mState == State::Initial)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Initial)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Initial))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mState == State::Initial" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5105); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial" ")"); do { *((volatile int*)__null) = 5105; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5106 | |
5107 | Unused << this->Run(); |
5108 | } |
5109 | |
5110 | RefPtr<BoolPromise> OnResults() { |
5111 | AssertIsOnBackgroundThread(); |
5112 | |
5113 | return mPromiseHolder.Ensure(__func__); |
5114 | } |
5115 | |
5116 | void Abort(); |
5117 | |
5118 | void RegisterDatabaseMaintenance(DatabaseMaintenance* aDatabaseMaintenance); |
5119 | |
5120 | void UnregisterDatabaseMaintenance(DatabaseMaintenance* aDatabaseMaintenance); |
5121 | |
5122 | bool HasDatabaseMaintenances() const { return mDatabaseMaintenances.Count(); } |
5123 | |
5124 | RefPtr<DatabaseMaintenance> GetDatabaseMaintenance( |
5125 | const nsAString& aDatabasePath) const { |
5126 | AssertIsOnBackgroundThread(); |
5127 | |
5128 | return mDatabaseMaintenances.Get(aDatabasePath); |
5129 | } |
5130 | |
5131 | void WaitForCompletion(nsIRunnable* aCallback) { |
5132 | AssertIsOnBackgroundThread(); |
5133 | MOZ_ASSERT(mDatabaseMaintenances.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabaseMaintenances.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabaseMaintenances.Count( )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mDatabaseMaintenances.Count()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5133); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabaseMaintenances.Count()" ")"); do { *((volatile int*)__null) = 5133; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5134 | |
5135 | mCompleteCallbacks.AppendElement(aCallback); |
5136 | } |
5137 | |
5138 | void Stringify(nsACString& aResult) const; |
5139 | |
5140 | private: |
5141 | ~Maintenance() override { |
5142 | MOZ_ASSERT(mState == State::Complete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Complete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Complete))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("mState == State::Complete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5142); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Complete" ")"); do { *((volatile int*)__null) = 5142; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5143 | MOZ_ASSERT(!mDatabaseMaintenances.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabaseMaintenances.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDatabaseMaintenances.Count ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mDatabaseMaintenances.Count()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5143); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabaseMaintenances.Count()" ")"); do { *((volatile int*)__null) = 5143; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5144 | } |
5145 | |
5146 | // Runs on the PBackground thread. Checks if IndexedDatabaseManager is |
5147 | // running. Calls OpenDirectory() or dispatches to the main thread on which |
5148 | // CreateIndexedDatabaseManager() is called. |
5149 | nsresult Start(); |
5150 | |
5151 | // Runs on the main thread. Once IndexedDatabaseManager is created it will |
5152 | // dispatch to the PBackground thread on which OpenDirectory() is called. |
5153 | nsresult CreateIndexedDatabaseManager(); |
5154 | |
5155 | RefPtr<UniversalDirectoryLockPromise> OpenStorageDirectory( |
5156 | const PersistenceScope& aPersistenceScope, bool aInitializeOrigins); |
5157 | |
5158 | // Runs on the PBackground thread. Once QuotaManager has given a lock it will |
5159 | // call DirectoryOpen(). |
5160 | nsresult OpenDirectory(); |
5161 | |
5162 | // Runs on the PBackground thread. Dispatches to the QuotaManager I/O thread. |
5163 | nsresult DirectoryOpen(); |
5164 | |
5165 | // Runs on the QuotaManager I/O thread. Once it finds databases it will |
5166 | // dispatch to the PBackground thread on which BeginDatabaseMaintenance() |
5167 | // is called. |
5168 | nsresult DirectoryWork(); |
5169 | |
5170 | // Runs on the PBackground thread. It dispatches a runnable for each database. |
5171 | nsresult BeginDatabaseMaintenance(); |
5172 | |
5173 | // Runs on the PBackground thread. Called when the maintenance is finished or |
5174 | // if any of above methods fails. |
5175 | void Finish(); |
5176 | |
5177 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
5178 | |
5179 | void DirectoryLockAcquired(UniversalDirectoryLock* aLock); |
5180 | |
5181 | void DirectoryLockFailed(); |
5182 | }; |
5183 | |
5184 | Maintenance::DirectoryInfo::DirectoryInfo(PersistenceType aPersistenceType, |
5185 | OriginMetadata aOriginMetadata, |
5186 | nsTArray<nsString>&& aDatabasePaths) |
5187 | : mOriginMetadata(std::move(aOriginMetadata)), |
5188 | mDatabasePaths(std::move(aDatabasePaths)), |
5189 | mPersistenceType(aPersistenceType) { |
5190 | MOZ_ASSERT(aPersistenceType != PERSISTENCE_TYPE_INVALID)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aPersistenceType != PERSISTENCE_TYPE_INVALID)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aPersistenceType != PERSISTENCE_TYPE_INVALID))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aPersistenceType != PERSISTENCE_TYPE_INVALID" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5190); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aPersistenceType != PERSISTENCE_TYPE_INVALID" ")"); do { *((volatile int*)__null) = 5190; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5191 | MOZ_ASSERT(!mOriginMetadata->mGroup.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mOriginMetadata->mGroup.IsEmpty())>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(! !(!mOriginMetadata->mGroup.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mOriginMetadata->mGroup.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5191); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mOriginMetadata->mGroup.IsEmpty()" ")"); do { *((volatile int*)__null) = 5191; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5192 | MOZ_ASSERT(!mOriginMetadata->mOrigin.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mOriginMetadata->mOrigin.IsEmpty())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mOriginMetadata->mOrigin.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mOriginMetadata->mOrigin.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5192); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mOriginMetadata->mOrigin.IsEmpty()" ")"); do { *((volatile int*)__null) = 5192; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5193 | #ifdef DEBUG1 |
5194 | MOZ_ASSERT(!mDatabasePaths->IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabasePaths->IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDatabasePaths->IsEmpty( )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mDatabasePaths->IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5194); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabasePaths->IsEmpty()" ")"); do { *((volatile int*)__null) = 5194; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5195 | for (const nsAString& databasePath : *mDatabasePaths) { |
5196 | MOZ_ASSERT(!databasePath.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!databasePath.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!databasePath.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!databasePath.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5196); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!databasePath.IsEmpty()" ")"); do { *((volatile int*)__null) = 5196; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5197 | } |
5198 | #endif |
5199 | |
5200 | MOZ_COUNT_CTOR(Maintenance::DirectoryInfo)do { static_assert(std::is_class_v<Maintenance::DirectoryInfo >, "Token '" "Maintenance::DirectoryInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, Maintenance ::DirectoryInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "Maintenance::DirectoryInfo" , sizeof(*this)); } while (0); |
5201 | } |
5202 | |
5203 | class DatabaseMaintenance final : public Runnable { |
5204 | // The minimum amount of time that has passed since the last vacuum before we |
5205 | // will attempt to analyze the database for fragmentation. |
5206 | static const PRTime kMinVacuumAge = |
5207 | PRTime(PR_USEC_PER_SEC1000000L) * 60 * 60 * 24 * 7; |
5208 | |
5209 | // If the percent of database pages that are not in contiguous order is higher |
5210 | // than this percentage we will attempt a vacuum. |
5211 | static const int32_t kPercentUnorderedThreshold = 30; |
5212 | |
5213 | // If the percent of file size growth since the last vacuum is higher than |
5214 | // this percentage we will attempt a vacuum. |
5215 | static const int32_t kPercentFileSizeGrowthThreshold = 10; |
5216 | |
5217 | // The number of freelist pages beyond which we will favor an incremental |
5218 | // vacuum over a full vacuum. |
5219 | static const int32_t kMaxFreelistThreshold = 5; |
5220 | |
5221 | // If the percent of unused file bytes in the database exceeds this percentage |
5222 | // then we will attempt a full vacuum. |
5223 | static const int32_t kPercentUnusedThreshold = 20; |
5224 | |
5225 | enum class MaintenanceAction { Nothing = 0, IncrementalVacuum, FullVacuum }; |
5226 | |
5227 | RefPtr<Maintenance> mMaintenance; |
5228 | // The directory lock is dropped in RunOnOwningThread which serves as a |
5229 | // cleanup method and is always called. |
5230 | RefPtr<ClientDirectoryLock> mDirectoryLock; |
5231 | const OriginMetadata mOriginMetadata; |
5232 | const nsString mDatabasePath; |
5233 | int64_t mDirectoryLockId; |
5234 | nsCOMPtr<nsIRunnable> mCompleteCallback; |
5235 | const PersistenceType mPersistenceType; |
5236 | const Maybe<CipherKey> mMaybeKey; |
5237 | Atomic<bool> mAborted; |
5238 | DataMutex<nsCOMPtr<mozIStorageConnection>> mSharedStorageConnection; |
5239 | |
5240 | public: |
5241 | DatabaseMaintenance(Maintenance* aMaintenance, |
5242 | RefPtr<ClientDirectoryLock> aDirectoryLock, |
5243 | PersistenceType aPersistenceType, |
5244 | const OriginMetadata& aOriginMetadata, |
5245 | const nsAString& aDatabasePath, |
5246 | const Maybe<CipherKey>& aMaybeKey) |
5247 | : Runnable("dom::indexedDB::DatabaseMaintenance"), |
5248 | mMaintenance(aMaintenance), |
5249 | mDirectoryLock(std::move(aDirectoryLock)), |
5250 | mOriginMetadata(aOriginMetadata), |
5251 | mDatabasePath(aDatabasePath), |
5252 | mPersistenceType(aPersistenceType), |
5253 | mMaybeKey{aMaybeKey}, |
5254 | mAborted(false), |
5255 | mSharedStorageConnection("sharedStorageConnection") { |
5256 | MOZ_ASSERT(mDirectoryLock)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDirectoryLock)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDirectoryLock))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDirectoryLock" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDirectoryLock" ")"); do { *((volatile int*)__null) = 5256; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5257 | |
5258 | MOZ_ASSERT(mDirectoryLock->Id() >= 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDirectoryLock->Id() >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDirectoryLock->Id() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mDirectoryLock->Id() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5258); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDirectoryLock->Id() >= 0" ")"); do { *((volatile int*)__null) = 5258; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5259 | mDirectoryLockId = mDirectoryLock->Id(); |
5260 | } |
5261 | |
5262 | const nsAString& DatabasePath() const { return mDatabasePath; } |
5263 | |
5264 | void WaitForCompletion(nsIRunnable* aCallback) { |
5265 | AssertIsOnBackgroundThread(); |
5266 | MOZ_ASSERT(!mCompleteCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mCompleteCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mCompleteCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mCompleteCallback" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5266); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mCompleteCallback" ")"); do { *((volatile int*)__null) = 5266; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5267 | |
5268 | mCompleteCallback = aCallback; |
5269 | } |
5270 | |
5271 | void Stringify(nsACString& aResult) const; |
5272 | |
5273 | nsresult Abort(); |
5274 | |
5275 | private: |
5276 | ~DatabaseMaintenance() override = default; |
5277 | |
5278 | // Runs on maintenance thread pool. Does maintenance on the database. |
5279 | void PerformMaintenanceOnDatabase(); |
5280 | |
5281 | // Runs on maintenance thread pool as part of PerformMaintenanceOnDatabase. |
5282 | nsresult CheckIntegrity(mozIStorageConnection& aConnection, bool* aOk); |
5283 | |
5284 | // Runs on maintenance thread pool as part of PerformMaintenanceOnDatabase. |
5285 | nsresult DetermineMaintenanceAction(mozIStorageConnection& aConnection, |
5286 | nsIFile* aDatabaseFile, |
5287 | MaintenanceAction* aMaintenanceAction); |
5288 | |
5289 | // Runs on maintenance thread pool as part of PerformMaintenanceOnDatabase. |
5290 | void IncrementalVacuum(mozIStorageConnection& aConnection); |
5291 | |
5292 | // Runs on maintenance thread pool as part of PerformMaintenanceOnDatabase. |
5293 | void FullVacuum(mozIStorageConnection& aConnection, nsIFile* aDatabaseFile); |
5294 | |
5295 | // Runs on the PBackground thread. It dispatches a complete callback and |
5296 | // unregisters from Maintenance. |
5297 | void RunOnOwningThread(); |
5298 | |
5299 | // Runs on maintenance thread pool. Once it performs database maintenance |
5300 | // it will dispatch to the PBackground thread on which RunOnOwningThread() |
5301 | // is called. |
5302 | void RunOnConnectionThread(); |
5303 | |
5304 | // TODO: Could QuotaClient::IsShuttingDownOnNonBackgroundThread() call |
5305 | // be part of mMaintenance::IsAborted() ? |
5306 | inline bool IsAborted() const { |
5307 | return mMaintenance->IsAborted() || mAborted || |
5308 | NS_WARN_IF(QuotaClient::IsShuttingDownOnNonBackgroundThread())NS_warn_if_impl(QuotaClient::IsShuttingDownOnNonBackgroundThread (), "QuotaClient::IsShuttingDownOnNonBackgroundThread()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5308); |
5309 | } |
5310 | |
5311 | NS_DECL_NSIRUNNABLEvirtual nsresult Run(void) override; |
5312 | }; |
5313 | |
5314 | #ifdef DEBUG1 |
5315 | |
5316 | class DEBUGThreadSlower final : public nsIThreadObserver { |
5317 | public: |
5318 | DEBUGThreadSlower() { |
5319 | AssertIsOnBackgroundThread(); |
5320 | MOZ_ASSERT(kDEBUGThreadSleepMS)do { static_assert( mozilla::detail::AssertionConditionType< decltype(kDEBUGThreadSleepMS)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(kDEBUGThreadSleepMS))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("kDEBUGThreadSleepMS" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5320); AnnotateMozCrashReason("MOZ_ASSERT" "(" "kDEBUGThreadSleepMS" ")"); do { *((volatile int*)__null) = 5320; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5321 | } |
5322 | |
5323 | NS_DECL_ISUPPORTSpublic: virtual nsresult QueryInterface(const nsIID& aIID , void** aInstancePtr) override; virtual MozExternalRefCountType AddRef(void) override; virtual MozExternalRefCountType Release (void) override; using HasThreadSafeRefCnt = std::false_type; protected: nsAutoRefCnt mRefCnt; nsAutoOwningThread _mOwningThread ; public: |
5324 | |
5325 | private: |
5326 | ~DEBUGThreadSlower() { AssertIsOnBackgroundThread(); } |
5327 | |
5328 | NS_DECL_NSITHREADOBSERVERvirtual nsresult OnDispatchedEvent(void) override; virtual nsresult OnProcessNextEvent(nsIThreadInternal *thread, bool mayWait) override ; virtual nsresult AfterProcessNextEvent(nsIThreadInternal *thread , bool eventWasProcessed) override; |
5329 | }; |
5330 | |
5331 | #endif // DEBUG |
5332 | |
5333 | /******************************************************************************* |
5334 | * Helper classes |
5335 | ******************************************************************************/ |
5336 | |
5337 | // XXX Get rid of FileHelper and move the functions into DatabaseFileManager. |
5338 | // Then, DatabaseFileManager::Get(Journal)Directory and |
5339 | // DatabaseFileManager::GetFileForId might eventually be made private. |
5340 | class MOZ_STACK_CLASS FileHelper final { |
5341 | const SafeRefPtr<DatabaseFileManager> mFileManager; |
5342 | |
5343 | LazyInitializedOnce<const NotNull<nsCOMPtr<nsIFile>>> mFileDirectory; |
5344 | LazyInitializedOnce<const NotNull<nsCOMPtr<nsIFile>>> mJournalDirectory; |
5345 | |
5346 | class ReadCallback; |
5347 | LazyInitializedOnce<const NotNull<RefPtr<ReadCallback>>> mReadCallback; |
5348 | |
5349 | public: |
5350 | explicit FileHelper(SafeRefPtr<DatabaseFileManager>&& aFileManager) |
5351 | : mFileManager(std::move(aFileManager)) { |
5352 | MOZ_ASSERT(mFileManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5352); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileManager" ")"); do { *((volatile int*)__null) = 5352; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5353 | } |
5354 | |
5355 | nsresult Init(); |
5356 | |
5357 | [[nodiscard]] nsCOMPtr<nsIFile> GetFile(const DatabaseFileInfo& aFileInfo); |
5358 | |
5359 | [[nodiscard]] nsCOMPtr<nsIFile> GetJournalFile( |
5360 | const DatabaseFileInfo& aFileInfo); |
5361 | |
5362 | nsresult CreateFileFromStream(nsIFile& aFile, nsIFile& aJournalFile, |
5363 | nsIInputStream& aInputStream, bool aCompress, |
5364 | const Maybe<CipherKey>& aMaybeKey); |
5365 | |
5366 | private: |
5367 | nsresult SyncCopy(nsIInputStream& aInputStream, |
5368 | nsIOutputStream& aOutputStream, char* aBuffer, |
5369 | uint32_t aBufferSize); |
5370 | |
5371 | nsresult SyncRead(nsIInputStream& aInputStream, char* aBuffer, |
5372 | uint32_t aBufferSize, uint32_t* aRead); |
5373 | }; |
5374 | |
5375 | /******************************************************************************* |
5376 | * Helper Functions |
5377 | ******************************************************************************/ |
5378 | |
5379 | bool GetFilenameBase(const nsAString& aFilename, const nsAString& aSuffix, |
5380 | nsDependentSubstring& aFilenameBase) { |
5381 | MOZ_ASSERT(!aFilename.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aFilename.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aFilename.IsEmpty()))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!aFilename.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5381); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aFilename.IsEmpty()" ")"); do { *((volatile int*)__null) = 5381; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5382 | MOZ_ASSERT(aFilenameBase.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aFilenameBase.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aFilenameBase.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aFilenameBase.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5382); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFilenameBase.IsEmpty()" ")"); do { *((volatile int*)__null) = 5382; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5383 | |
5384 | if (!StringEndsWith(aFilename, aSuffix) || |
5385 | aFilename.Length() == aSuffix.Length()) { |
5386 | return false; |
5387 | } |
5388 | |
5389 | MOZ_ASSERT(aFilename.Length() > aSuffix.Length())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aFilename.Length() > aSuffix.Length())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aFilename.Length() > aSuffix.Length()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFilename.Length() > aSuffix.Length()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5389); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFilename.Length() > aSuffix.Length()" ")"); do { *((volatile int*)__null) = 5389; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5390 | |
5391 | aFilenameBase.Rebind(aFilename, 0, aFilename.Length() - aSuffix.Length()); |
5392 | return true; |
5393 | } |
5394 | |
5395 | class EncryptedFileBlobImpl final : public FileBlobImpl { |
5396 | public: |
5397 | EncryptedFileBlobImpl(const nsCOMPtr<nsIFile>& aNativeFile, |
5398 | const DatabaseFileInfo::IdType aId, |
5399 | const CipherKey& aKey) |
5400 | : FileBlobImpl{aNativeFile}, mKey{aKey} { |
5401 | SetFileId(aId); |
5402 | } |
5403 | |
5404 | uint64_t GetSize(ErrorResult& aRv) override { |
5405 | nsCOMPtr<nsIInputStream> inputStream; |
5406 | CreateInputStream(getter_AddRefs(inputStream), aRv); |
5407 | |
5408 | if (aRv.Failed()) { |
5409 | return 0; |
5410 | } |
5411 | |
5412 | MOZ_ASSERT(inputStream)do { static_assert( mozilla::detail::AssertionConditionType< decltype(inputStream)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(inputStream))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("inputStream", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5412); AnnotateMozCrashReason("MOZ_ASSERT" "(" "inputStream" ")"); do { *((volatile int*)__null) = 5412; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5413 | |
5414 | QM_TRY_RETURN(MOZ_TO_RESULT_INVOKE_MEMBER(inputStream, Available), 0,{auto tryResult847 = (::mozilla::ToResultInvokeMember( (inputStream ), &::mozilla::detail::DerefedType<decltype(inputStream )>::Available)); if ((__builtin_expect(!!(tryResult847.isErr ()), 0))) { auto tryTempError = tryResult847.unwrapErr(); mozilla ::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (inputStream), &::mozilla::detail::DerefedType<decltype(inputStream)>::Available)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5415, mozilla::dom::quota::Severity::Error); [&aRv](const nsresult rv) { aRv = rv; }(tryTempError); constexpr const auto & func __attribute__((__unused__)) = __func__; return mozilla ::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (inputStream), &::mozilla::detail::DerefedType<decltype(inputStream)>::Available)" , tryTempError, 0); } return tryResult847.unwrap();} |
5415 | [&aRv](const nsresult rv) { aRv = rv; }){auto tryResult847 = (::mozilla::ToResultInvokeMember( (inputStream ), &::mozilla::detail::DerefedType<decltype(inputStream )>::Available)); if ((__builtin_expect(!!(tryResult847.isErr ()), 0))) { auto tryTempError = tryResult847.unwrapErr(); mozilla ::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (inputStream), &::mozilla::detail::DerefedType<decltype(inputStream)>::Available)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5415, mozilla::dom::quota::Severity::Error); [&aRv](const nsresult rv) { aRv = rv; }(tryTempError); constexpr const auto & func __attribute__((__unused__)) = __func__; return mozilla ::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (inputStream), &::mozilla::detail::DerefedType<decltype(inputStream)>::Available)" , tryTempError, 0); } return tryResult847.unwrap();}; |
5416 | } |
5417 | |
5418 | void CreateInputStream(nsIInputStream** aInputStream, |
5419 | ErrorResult& aRv) const override { |
5420 | nsCOMPtr<nsIInputStream> baseInputStream; |
5421 | FileBlobImpl::CreateInputStream(getter_AddRefs(baseInputStream), aRv); |
5422 | if (NS_WARN_IF(aRv.Failed())NS_warn_if_impl(aRv.Failed(), "aRv.Failed()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5422)) { |
5423 | return; |
5424 | } |
5425 | |
5426 | *aInputStream = |
5427 | MakeAndAddRef<DecryptingInputStream<IndexedDBCipherStrategy>>( |
5428 | WrapNotNull(std::move(baseInputStream)), kEncryptedStreamBlockSize, |
5429 | mKey) |
5430 | .take(); |
5431 | } |
5432 | |
5433 | void GetBlobImplType(nsAString& aBlobImplType) const override { |
5434 | aBlobImplType = u"EncryptedFileBlobImpl"_ns; |
5435 | } |
5436 | |
5437 | already_AddRefed<BlobImpl> CreateSlice(uint64_t aStart, uint64_t aLength, |
5438 | const nsAString& aContentType, |
5439 | ErrorResult& aRv) const override { |
5440 | MOZ_CRASH("Not implemented because this should be unreachable.")do { do { } while (false); MOZ_ReportCrash("" "Not implemented because this should be unreachable." , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5440); AnnotateMozCrashReason("MOZ_CRASH(" "Not implemented because this should be unreachable." ")"); do { *((volatile int*)__null) = 5440; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
5441 | } |
5442 | |
5443 | private: |
5444 | const CipherKey mKey; |
5445 | }; |
5446 | |
5447 | RefPtr<BlobImpl> CreateFileBlobImpl(const Database& aDatabase, |
5448 | const nsCOMPtr<nsIFile>& aNativeFile, |
5449 | const DatabaseFileInfo::IdType aId) { |
5450 | if (aDatabase.IsInPrivateBrowsing()) { |
5451 | nsCString keyId; |
5452 | keyId.AppendInt(aId); |
5453 | |
5454 | const auto& key = |
5455 | aDatabase.GetFileManager().MutableCipherKeyManagerRef().Get(keyId); |
5456 | |
5457 | MOZ_RELEASE_ASSERT(key.isSome())do { static_assert( mozilla::detail::AssertionConditionType< decltype(key.isSome())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(key.isSome()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("key.isSome()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5457); AnnotateMozCrashReason("MOZ_RELEASE_ASSERT" "(" "key.isSome()" ")"); do { *((volatile int*)__null) = 5457; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5458 | return MakeRefPtr<EncryptedFileBlobImpl>(aNativeFile, aId, *key); |
5459 | } |
5460 | |
5461 | auto impl = MakeRefPtr<FileBlobImpl>(aNativeFile); |
5462 | impl->SetFileId(aId); |
5463 | |
5464 | return impl; |
5465 | } |
5466 | |
5467 | Result<nsTArray<SerializedStructuredCloneFile>, nsresult> |
5468 | SerializeStructuredCloneFiles(const SafeRefPtr<Database>& aDatabase, |
5469 | const nsTArray<StructuredCloneFileParent>& aFiles, |
5470 | bool aForPreprocess) { |
5471 | AssertIsOnBackgroundThread(); |
5472 | MOZ_ASSERT(aDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5472); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabase" ")" ); do { *((volatile int*)__null) = 5472; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5473 | |
5474 | if (aFiles.IsEmpty()) { |
5475 | return nsTArray<SerializedStructuredCloneFile>{}; |
5476 | } |
5477 | |
5478 | const nsCOMPtr<nsIFile> directory = |
5479 | aDatabase->GetFileManager().GetCheckedDirectory(); |
5480 | QM_TRY(OkIf(directory), Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR),{auto tryResult848 = (OkIf(directory)); static_assert(std::is_empty_v <typename decltype(tryResult848)::ok_type>); if ((__builtin_expect (!!(tryResult848.isErr()), 0))) { auto tryTempError = tryResult848 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(directory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5481, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5481, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(directory)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }} |
5481 | IDB_REPORT_INTERNAL_ERR_LAMBDA){auto tryResult848 = (OkIf(directory)); static_assert(std::is_empty_v <typename decltype(tryResult848)::ok_type>); if ((__builtin_expect (!!(tryResult848.isErr()), 0))) { auto tryTempError = tryResult848 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(directory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5481, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5481, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(directory)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; |
5482 | |
5483 | nsTArray<SerializedStructuredCloneFile> serializedStructuredCloneFiles; |
5484 | QM_TRY(OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(),{auto tryResult849 = (OkIf(serializedStructuredCloneFiles.SetCapacity (aFiles.Length(), fallible))); static_assert(std::is_empty_v< typename decltype(tryResult849)::ok_type>); if ((__builtin_expect (!!(tryResult849.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult849.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(), fallible))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5486, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(), fallible))" , tryTempError, Err(NS_ERROR_OUT_OF_MEMORY)); }} |
5485 | fallible)),{auto tryResult849 = (OkIf(serializedStructuredCloneFiles.SetCapacity (aFiles.Length(), fallible))); static_assert(std::is_empty_v< typename decltype(tryResult849)::ok_type>); if ((__builtin_expect (!!(tryResult849.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult849.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(), fallible))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5486, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(), fallible))" , tryTempError, Err(NS_ERROR_OUT_OF_MEMORY)); }} |
5486 | Err(NS_ERROR_OUT_OF_MEMORY)){auto tryResult849 = (OkIf(serializedStructuredCloneFiles.SetCapacity (aFiles.Length(), fallible))); static_assert(std::is_empty_v< typename decltype(tryResult849)::ok_type>); if ((__builtin_expect (!!(tryResult849.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult849.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(), fallible))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5486, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(serializedStructuredCloneFiles.SetCapacity(aFiles.Length(), fallible))" , tryTempError, Err(NS_ERROR_OUT_OF_MEMORY)); }}; |
5487 | |
5488 | QM_TRY(TransformIfAbortOnErr({auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5489 | aFiles, MakeBackInserter(serializedStructuredCloneFiles),{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5490 | [aForPreprocess](const auto& file) {{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5491 | return !aForPreprocess ||{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5492 | file.Type() == StructuredCloneFileBase::eStructuredClone;{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5493 | },{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5494 | [&directory, &aDatabase, aForPreprocess]({auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5495 | const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> {{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5496 | const int64_t fileId = file.FileInfo().Id();{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5497 | MOZ_ASSERT(fileId > 0);{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5498 | |
5499 | const nsCOMPtr<nsIFile> nativeFile ={auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5500 | mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId({auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5501 | directory, fileId);{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5502 | QM_TRY(OkIf(nativeFile), Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR),{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5503 | IDB_REPORT_INTERNAL_ERR_LAMBDA);{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5504 | |
5505 | switch (file.Type()) {{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5506 | case StructuredCloneFileBase::eStructuredClone:{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5507 | if (!aForPreprocess) {{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5508 | return SerializedStructuredCloneFile{{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5509 | null_t(), StructuredCloneFileBase::eStructuredClone};{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5510 | }{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5511 | |
5512 | [[fallthrough]];{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5513 | |
5514 | case StructuredCloneFileBase::eBlob: {{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5515 | const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile,{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5516 | file.FileInfo().Id());{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5517 | |
5518 | IPCBlob ipcBlob;{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5519 | |
5520 | // This can only fail if the child has crashed.{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5521 | QM_TRY(MOZ_TO_RESULT(IPCBlobUtils::Serialize(impl, ipcBlob)),{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5522 | Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR),{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5523 | IDB_REPORT_INTERNAL_ERR_LAMBDA);{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5524 | |
5525 | aDatabase->MapBlob(ipcBlob, file.FileInfoPtr());{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5526 | |
5527 | return SerializedStructuredCloneFile{ipcBlob, file.Type()};{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5528 | }{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5529 | |
5530 | case StructuredCloneFileBase::eMutableFile:{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5531 | case StructuredCloneFileBase::eWasmBytecode:{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5532 | case StructuredCloneFileBase::eWasmCompiled: {{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5533 | // Set file() to null, support for storing WebAssembly.Modules has{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5534 | // been removed in bug 1469395. Support for de-serialization of{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5535 | // WebAssembly.Modules modules has been removed in bug 1561876.{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5536 | // Support for MutableFile has been removed in bug 1500343. Full{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5537 | // removal is tracked in bug 1487479.{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5538 | |
5539 | return SerializedStructuredCloneFile{null_t(), file.Type()};{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5540 | }{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5541 | |
5542 | default:{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5543 | MOZ_CRASH("Should never get here!");{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5544 | }{auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }} |
5545 | })){auto tryResult852 = (TransformIfAbortOnErr( aFiles, MakeBackInserter (serializedStructuredCloneFiles), [aForPreprocess](const auto & file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase ::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess ]( const auto& file) -> Result<SerializedStructuredCloneFile , nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileId > 0" ")"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); const nsCOMPtr <nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager ::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect( !!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(nativeFile)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5503, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "OkIf(nativeFile)", tryTempError , Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file. Type()) { case StructuredCloneFileBase::eStructuredClone: if ( !aForPreprocess) { return SerializedStructuredCloneFile{ null_t (), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough ]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl (*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob ; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl , ipcBlob))); static_assert(std::is_empty_v<typename decltype (tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851 .isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, mozilla::dom::quota::Severity::Error); [](const auto& ) { mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5523, "UnknownErr"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla:: dom::quota::HandleCustomRetVal(func, "ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))" , tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile {ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile : case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase ::eWasmCompiled: { return SerializedStructuredCloneFile{null_t (), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash ("" "Should never get here!", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } })); static_assert (std::is_empty_v<typename decltype(tryResult852)::ok_type> ); if ((__builtin_expect(!!(tryResult852.isErr()), 0))) { mozilla ::dom::quota::HandleError("TransformIfAbortOnErr( aFiles, MakeBackInserter(serializedStructuredCloneFiles), [aForPreprocess](const auto& file) { return !aForPreprocess || file.Type() == StructuredCloneFileBase::eStructuredClone; }, [&directory, &aDatabase, aForPreprocess]( const auto& file) -> Result<SerializedStructuredCloneFile, nsresult> { const int64_t fileId = file.FileInfo().Id(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(fileId > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(fileId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"fileId > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5497); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"fileId > 0\" \")\"); do { *((volatile int*)__null) = 5497; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); const nsCOMPtr<nsIFile> nativeFile = mozilla::dom::indexedDB::DatabaseFileManager::GetCheckedFileForId( directory, fileId); {auto tryResult850 = (OkIf(nativeFile)); static_assert(std::is_empty_v<typename decltype(tryResult850)::ok_type>); if ((__builtin_expect(!!(tryResult850.isErr()), 0))) { auto tryTempError = tryResult850.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(nativeFile)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5503, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(nativeFile)\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; switch (file.Type()) { case StructuredCloneFileBase::eStructuredClone: if (!aForPreprocess) { return SerializedStructuredCloneFile{ null_t(), StructuredCloneFileBase::eStructuredClone}; } [[fallthrough]]; case StructuredCloneFileBase::eBlob: { const auto impl = CreateFileBlobImpl(*aDatabase, nativeFile, file.FileInfo().Id()); IPCBlob ipcBlob; {auto tryResult851 = (ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))); static_assert(std::is_empty_v<typename decltype(tryResult851)::ok_type>); if ((__builtin_expect(!!(tryResult851.isErr()), 0))) { auto tryTempError = tryResult851.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, mozilla::dom::quota::Severity::Error); [](const auto&) { mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5523, \"UnknownErr\"); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(IPCBlobUtils::Serialize(impl, ipcBlob))\", tryTempError, Err(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR)); }}; aDatabase->MapBlob(ipcBlob, file.FileInfoPtr()); return SerializedStructuredCloneFile{ipcBlob, file.Type()}; } case StructuredCloneFileBase::eMutableFile: case StructuredCloneFileBase::eWasmBytecode: case StructuredCloneFileBase::eWasmCompiled: { return SerializedStructuredCloneFile{null_t(), file.Type()}; } default: do { do { } while (false); MOZ_ReportCrash(\"\" \"Should never get here!\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5543); AnnotateMozCrashReason(\"MOZ_CRASH(\" \"Should never get here!\" \")\"); do { *((volatile int*)__null) = 5543; __attribute__((nomerge)) ::abort(); } while (false); } while (false); } })" , tryResult852.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5545, mozilla::dom::quota::Severity::Error); return tryResult852 .propagateErr(); }}; |
5546 | |
5547 | return std::move(serializedStructuredCloneFiles); |
5548 | } |
5549 | |
5550 | bool IsFileNotFoundError(const nsresult aRv) { |
5551 | return aRv == NS_ERROR_FILE_NOT_FOUND; |
5552 | } |
5553 | |
5554 | enum struct Idempotency { Yes, No }; |
5555 | |
5556 | // Delete a file, decreasing the quota usage as appropriate. If the file no |
5557 | // longer exists but aIdempotency is Idempotency::Yes, success is returned, |
5558 | // although quota usage can't be decreased. (With the assumption being that the |
5559 | // file was already deleted prior to this logic running, and the non-existent |
5560 | // file was no longer tracked by quota because it didn't exist at |
5561 | // initialization time or a previous deletion call updated the usage.) |
5562 | nsresult DeleteFile(nsIFile& aFile, QuotaManager* const aQuotaManager, |
5563 | const PersistenceType aPersistenceType, |
5564 | const OriginMetadata& aOriginMetadata, |
5565 | const Idempotency aIdempotency) { |
5566 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5566); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 5566; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5567 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5567); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 5567; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5568 | |
5569 | // Callers which pass Idempotency::Yes call this function without checking if |
5570 | // the file already exists (idempotent usage). QM_OR_ELSE_WARN_IF is not used |
5571 | // here since we just want to log NS_ERROR_FILE_NOT_FOUND results and not spam |
5572 | // the reports. |
5573 | // Theoretically, there should be no QM_OR_ELSE_(WARN|LOG_VERBOSE)_IF when a |
5574 | // caller passes Idempotency::No, but it's simpler when the predicate just |
5575 | // always returns false in that case. |
5576 | |
5577 | const auto isIgnorableError = [&aIdempotency]() -> bool (*)(nsresult) { |
5578 | if (aIdempotency == Idempotency::Yes) { |
5579 | return IsFileNotFoundError; |
5580 | } |
5581 | |
5582 | return [](const nsresult rv) { return false; }; |
5583 | }(); |
5584 | |
5585 | QM_TRY_INSPECT(auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5586 | const auto& fileSize,auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5587 | ([aQuotaManager, &aFile,auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5588 | isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> {auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5589 | if (aQuotaManager) {auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5590 | QM_TRY_INSPECT(auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5591 | const Maybe<int64_t>& fileSize,auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5592 | QM_OR_ELSE_LOG_VERBOSE_IF(auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5593 | // Expression.auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5594 | MOZ_TO_RESULT_INVOKE_MEMBER(aFile, GetFileSize)auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5595 | .map([](const int64_t val) { return Some(val); }),auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5596 | // Predicate.auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5597 | isIgnorableError,auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5598 | // Fallback.auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5599 | ErrToDefaultOk<Maybe<int64_t>>));auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5600 | |
5601 | // XXX Can we really assert that the file size is not 0 ifauto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5602 | // it existed? This might be violated by externalauto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5603 | // influences.auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5604 | MOZ_ASSERT(!fileSize || fileSize.value() >= 0);auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5605 | |
5606 | return fileSize;auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5607 | }auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5608 | |
5609 | return Some(int64_t(0));auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect (); |
5610 | }()))auto tryResult854 = (([aQuotaManager, &aFile, isIgnorableError ]() -> Result<Maybe<int64_t>, nsresult> { if ( aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf ( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla:: detail::DerefedType<decltype(aFile)>::GetFileSize) .map ([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)" , tryResult853.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5599, mozilla::dom::quota::Severity::Error); return tryResult853 .propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!fileSize || fileSize.value () >= 0)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!fileSize || fileSize.value() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5604); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!fileSize || fileSize.value() >= 0" ")"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return fileSize ; } return Some(int64_t(0)); }())); if ((__builtin_expect(!!( tryResult854.isErr()), 0))) { mozilla::dom::quota::HandleError ("([aQuotaManager, &aFile, isIgnorableError]() -> Result<Maybe<int64_t>, nsresult> { if (aQuotaManager) { auto tryResult853 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)); if ((__builtin_expect(!!(tryResult853.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (aFile), &::mozilla::detail::DerefedType<decltype(aFile)>::GetFileSize) .map([](const int64_t val) { return Some(val); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 5599, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<int64_t>>)\", tryResult853.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5599, mozilla::dom::quota::Severity::Error); return tryResult853.propagateErr(); } const Maybe<int64_t>& fileSize = tryResult853.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(!fileSize || fileSize.value() >= 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(!fileSize || fileSize.value() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"!fileSize || fileSize.value() >= 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5604); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"!fileSize || fileSize.value() >= 0\" \")\"); do { *((volatile int*)__null) = 5604; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return fileSize; } return Some(int64_t(0)); }())" , tryResult854.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5610, mozilla::dom::quota::Severity::Error); return tryResult854 .propagateErr(); } const auto& fileSize = tryResult854.inspect ();; |
5611 | |
5612 | if (!fileSize) { |
5613 | return NS_OK; |
5614 | } |
5615 | |
5616 | QM_TRY_INSPECT(const auto& didExist,auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5617 | QM_OR_ELSE_LOG_VERBOSE_IF(auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5618 | // Expression.auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5619 | MOZ_TO_RESULT(aFile.Remove(false)).map(Some<Ok>),auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5620 | // Predicate.auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5621 | isIgnorableError,auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5622 | // Fallback.auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect (); |
5623 | ErrToDefaultOk<Maybe<Ok>>))auto tryResult855 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(false)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = isIgnorableError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(false)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult855 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(false)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = isIgnorableError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(false)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5623, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult855.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5623, mozilla::dom::quota::Severity::Error); return tryResult855 .propagateErr(); } const auto& didExist = tryResult855.inspect ();; |
5624 | |
5625 | if (!didExist) { |
5626 | // XXX If we get here, this means that the file still existed when we |
5627 | // queried its size, but no longer when we tried to remove it. Not sure if |
5628 | // this should really be silently accepted in idempotent mode. |
5629 | return NS_OK; |
5630 | } |
5631 | |
5632 | if (fileSize.value() > 0) { |
5633 | MOZ_ASSERT(aQuotaManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aQuotaManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aQuotaManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aQuotaManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5633); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aQuotaManager" ")"); do { *((volatile int*)__null) = 5633; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5634 | |
5635 | aQuotaManager->DecreaseUsageForClient( |
5636 | ClientMetadata{aOriginMetadata, Client::IDB}, fileSize.value()); |
5637 | } |
5638 | |
5639 | return NS_OK; |
5640 | } |
5641 | |
5642 | nsresult DeleteFile(nsIFile& aDirectory, const nsAString& aFilename, |
5643 | QuotaManager* const aQuotaManager, |
5644 | const PersistenceType aPersistenceType, |
5645 | const OriginMetadata& aOriginMetadata, |
5646 | const Idempotency aIdempotent) { |
5647 | AssertIsOnIOThread(); |
5648 | MOZ_ASSERT(!aFilename.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aFilename.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aFilename.IsEmpty()))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!aFilename.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5648); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aFilename.IsEmpty()" ")"); do { *((volatile int*)__null) = 5648; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5649 | |
5650 | QM_TRY_INSPECT(const auto& file, CloneFileAndAppend(aDirectory, aFilename))auto tryResult856 = (CloneFileAndAppend(aDirectory, aFilename )); if ((__builtin_expect(!!(tryResult856.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(aDirectory, aFilename)" , tryResult856.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5650, mozilla::dom::quota::Severity::Error); return tryResult856 .propagateErr(); } const auto& file = tryResult856.inspect ();; |
5651 | |
5652 | return DeleteFile(*file, aQuotaManager, aPersistenceType, aOriginMetadata, |
5653 | aIdempotent); |
5654 | } |
5655 | |
5656 | // Delete files in a directory that you think exists. If the directory doesn't |
5657 | // exist, an error will not be returned, but warning telemetry will be |
5658 | // generated! So only call this on directories that you know exist (idempotent |
5659 | // usage, but it's not recommended). |
5660 | nsresult DeleteFilesNoQuota(nsIFile& aFile) { |
5661 | AssertIsOnIOThread(); |
5662 | |
5663 | QM_TRY_INSPECT(const auto& didExist,auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5664 | QM_OR_ELSE_WARN_IF(auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5665 | // Expression.auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5666 | MOZ_TO_RESULT(aFile.Remove(true)).map(Some<Ok>),auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5667 | // Predicate.auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5668 | IsFileNotFoundError,auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5669 | // Fallback.auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect (); |
5670 | ErrToDefaultOk<Maybe<Ok>>))auto tryResult857 = (mozilla::dom::quota::OrElseIf( (ToResult (aFile.Remove(true)).map(Some<Ok>)), [&](const auto & firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla ::dom::quota::HandleError("\"ToResult(aFile.Remove(true)).map(Some<Ok>)\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <Maybe<Ok>>)); if ((__builtin_expect(!!(tryResult857 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(aFile.Remove(true)).map(Some<Ok>)), [&](const auto& firstRes) { bool res = IsFileNotFoundError(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(aFile.Remove(true)).map(Some<Ok>)\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5670, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<Maybe<Ok>>)" , tryResult857.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5670, mozilla::dom::quota::Severity::Error); return tryResult857 .propagateErr(); } const auto& didExist = tryResult857.inspect ();; |
5671 | |
5672 | Unused << didExist; |
5673 | |
5674 | return NS_OK; |
5675 | } |
5676 | |
5677 | nsresult DeleteFilesNoQuota(nsIFile* aDirectory, const nsAString& aFilename) { |
5678 | AssertIsOnIOThread(); |
5679 | MOZ_ASSERT(aDirectory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5679); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectory" ")"); do { *((volatile int*)__null) = 5679; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5680 | MOZ_ASSERT(!aFilename.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aFilename.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aFilename.IsEmpty()))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!aFilename.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5680); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aFilename.IsEmpty()" ")"); do { *((volatile int*)__null) = 5680; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5681 | |
5682 | // The current using function hasn't initialized the origin, so in here we |
5683 | // don't update the size of origin. Adding this assertion for preventing from |
5684 | // misusing. |
5685 | DebugOnly<QuotaManager*> quotaManager = QuotaManager::Get(); |
5686 | MOZ_ASSERT(!quotaManager->IsTemporaryStorageInitializedInternal())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!quotaManager->IsTemporaryStorageInitializedInternal ())>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!quotaManager->IsTemporaryStorageInitializedInternal ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!quotaManager->IsTemporaryStorageInitializedInternal()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5686); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!quotaManager->IsTemporaryStorageInitializedInternal()" ")"); do { *((volatile int*)__null) = 5686; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5687 | |
5688 | QM_TRY_INSPECT(const auto& file, CloneFileAndAppend(*aDirectory, aFilename))auto tryResult858 = (CloneFileAndAppend(*aDirectory, aFilename )); if ((__builtin_expect(!!(tryResult858.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, aFilename)" , tryResult858.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5688, mozilla::dom::quota::Severity::Error); return tryResult858 .propagateErr(); } const auto& file = tryResult858.inspect ();; |
5689 | |
5690 | QM_TRY(MOZ_TO_RESULT(DeleteFilesNoQuota(*file))){auto tryResult859 = (ToResult(DeleteFilesNoQuota(*file))); static_assert (std::is_empty_v<typename decltype(tryResult859)::ok_type> ); if ((__builtin_expect(!!(tryResult859.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(*file))" , tryResult859.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5690, mozilla::dom::quota::Severity::Error); return tryResult859 .propagateErr(); }}; |
5691 | |
5692 | return NS_OK; |
5693 | } |
5694 | |
5695 | // CreateMarkerFile and RemoveMarkerFile are a pair of functions to indicate |
5696 | // whether having removed all the files successfully. The marker file should |
5697 | // be checked before executing the next operation or initialization. |
5698 | Result<nsCOMPtr<nsIFile>, nsresult> CreateMarkerFile( |
5699 | nsIFile& aBaseDirectory, const nsAString& aDatabaseNameBase) { |
5700 | AssertIsOnIOThread(); |
5701 | MOZ_ASSERT(!aDatabaseNameBase.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseNameBase.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseNameBase.IsEmpty() ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "!aDatabaseNameBase.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5701); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseNameBase.IsEmpty()" ")"); do { *((volatile int*)__null) = 5701; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5702 | |
5703 | QM_TRY_INSPECT(auto tryResult860 = (CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)); if ((__builtin_expect(!!(tryResult860 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)" , tryResult860.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5706, mozilla::dom::quota::Severity::Error); return tryResult860 .propagateErr(); } const auto& markerFile = tryResult860. inspect(); |
5704 | const auto& markerFile,auto tryResult860 = (CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)); if ((__builtin_expect(!!(tryResult860 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)" , tryResult860.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5706, mozilla::dom::quota::Severity::Error); return tryResult860 .propagateErr(); } const auto& markerFile = tryResult860. inspect(); |
5705 | CloneFileAndAppend(aBaseDirectory,auto tryResult860 = (CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)); if ((__builtin_expect(!!(tryResult860 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)" , tryResult860.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5706, mozilla::dom::quota::Severity::Error); return tryResult860 .propagateErr(); } const auto& markerFile = tryResult860. inspect(); |
5706 | kIdbDeletionMarkerFilePrefix + aDatabaseNameBase))auto tryResult860 = (CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)); if ((__builtin_expect(!!(tryResult860 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(aBaseDirectory, kIdbDeletionMarkerFilePrefix + aDatabaseNameBase)" , tryResult860.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5706, mozilla::dom::quota::Severity::Error); return tryResult860 .propagateErr(); } const auto& markerFile = tryResult860. inspect();; |
5707 | |
5708 | // Callers call this function without checking if the file already exists |
5709 | // (idempotent usage). QM_OR_ELSE_WARN_IF is not used here since we just want |
5710 | // to log NS_ERROR_FILE_ALREADY_EXISTS result and not spam the reports. |
5711 | // |
5712 | // TODO: In theory if this file exists, then RemoveDatabaseFilesAndDirectory |
5713 | // should have cleaned it up, but obviously we can crash and not clean it up, |
5714 | // which is the whole point of the marker file. In that case, we'll realize |
5715 | // the marker file exists in OpenDatabaseOp::DoDatabaseWork or |
5716 | // GetUsageForOriginInternal and resume the removal by calling |
5717 | // RemoveDatabaseFilesAndDirectory again, but we will also try to create the |
5718 | // marker file again, so if we see this marker file, it is part |
5719 | // of our standard operating procedure to redundantly try and create the |
5720 | // marker here. We currently treat this as idempotent usage, but we could |
5721 | // add an additional argument to RemoveDatabaseFilesAndDirectory which would |
5722 | // indicate that we are resuming an unfinished removal, so the marker already |
5723 | // exists and doesn't have to be created, and change |
5724 | // QM_OR_ELSE_LOG_VERBOSE_IF to QM_OR_ELSE_WARN_IF in the end. |
5725 | QM_TRY(QM_OR_ELSE_LOG_VERBOSE_IF({auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }} |
5726 | // Expression.{auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }} |
5727 | MOZ_TO_RESULT(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644)),{auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }} |
5728 | // Predicate.{auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }} |
5729 | IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>,{auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }} |
5730 | // Fallback.{auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }} |
5731 | ErrToDefaultOk<>)){auto tryResult861 = (mozilla::dom::quota::OrElseIf( (ToResult (markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [& ](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS >(firstRes); mozilla::dom::quota::HandleError("\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <>)); static_assert(std::is_empty_v<typename decltype (tryResult861)::ok_type>); if ((__builtin_expect(!!(tryResult861 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_FILE_ALREADY_EXISTS>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(markerFile->Create(nsIFile::NORMAL_FILE_TYPE, 0644))\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5731, res ? mozilla::dom::quota::Severity::Verbose : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<>)" , tryResult861.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5731, mozilla::dom::quota::Severity::Error); return tryResult861 .propagateErr(); }}; |
5732 | |
5733 | return markerFile; |
5734 | } |
5735 | |
5736 | nsresult RemoveMarkerFile(nsIFile* aMarkerFile) { |
5737 | AssertIsOnIOThread(); |
5738 | MOZ_ASSERT(aMarkerFile)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMarkerFile)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMarkerFile))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aMarkerFile", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5738); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMarkerFile" ")"); do { *((volatile int*)__null) = 5738; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5739 | |
5740 | DebugOnly<bool> exists; |
5741 | MOZ_ASSERT(NS_SUCCEEDED(aMarkerFile->Exists(&exists)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(aMarkerFile ->Exists(&exists))), 1))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( !NS_FAILED_impl(aMarkerFile->Exists(&exists))), 1))))) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(aMarkerFile->Exists(&exists))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5741); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(aMarkerFile->Exists(&exists))), 1)))" ")"); do { *((volatile int*)__null) = 5741; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5742 | MOZ_ASSERT(exists)do { static_assert( mozilla::detail::AssertionConditionType< decltype(exists)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(exists))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("exists", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5742); AnnotateMozCrashReason("MOZ_ASSERT" "(" "exists" ")" ); do { *((volatile int*)__null) = 5742; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5743 | |
5744 | QM_TRY(MOZ_TO_RESULT(aMarkerFile->Remove(false))){auto tryResult862 = (ToResult(aMarkerFile->Remove(false)) ); static_assert(std::is_empty_v<typename decltype(tryResult862 )::ok_type>); if ((__builtin_expect(!!(tryResult862.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(aMarkerFile->Remove(false))" , tryResult862.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5744, mozilla::dom::quota::Severity::Error); return tryResult862 .propagateErr(); }}; |
5745 | |
5746 | return NS_OK; |
5747 | } |
5748 | |
5749 | Result<Ok, nsresult> DeleteFileManagerDirectory( |
5750 | nsIFile& aFileManagerDirectory, QuotaManager* aQuotaManager, |
5751 | const PersistenceType aPersistenceType, |
5752 | const OriginMetadata& aOriginMetadata) { |
5753 | // XXX In theory, deleting can continue for other files in case of a failure, |
5754 | // leaving only those files behind that cause the problem actually. However, |
5755 | // the current architecture doesn't allow having more databases (for the same |
5756 | // name) on disk, so trying to delete as much as possible won't help much |
5757 | // because we need to delete entire .files directory in the end anyway. |
5758 | QM_TRY(DatabaseFileManager::TraverseFiles({auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5759 | aFileManagerDirectory,{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5760 | // KnownDirEntryOp{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5761 | [&aQuotaManager, aPersistenceType, &aOriginMetadata]({auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5762 | nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> {{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5763 | if (isDirectory) {{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5764 | // The journal directory doesn't count towards quota.{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5765 | QM_TRY_RETURN(MOZ_TO_RESULT(DeleteFilesNoQuota(file)));{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5766 | }{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5767 | |
5768 | // Stored files do count towards quota.{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5769 | QM_TRY_RETURN({auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5770 | MOZ_TO_RESULT(DeleteFile(file, aQuotaManager, aPersistenceType,{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5771 | aOriginMetadata, Idempotency::Yes)));{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5772 | },{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5773 | // UnknownDirEntryOp{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5774 | [aPersistenceType, &aOriginMetadata]({auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5775 | nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> {{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5776 | // Unknown files and directories don't count towards quota.{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5777 | |
5778 | if (isDirectory) {{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5779 | QM_TRY_RETURN(MOZ_TO_RESULT(DeleteFilesNoQuota(file)));{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5780 | }{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5781 | |
5782 | QM_TRY_RETURN(MOZ_TO_RESULT({auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5783 | DeleteFile(file, /* doesn't count */ nullptr, aPersistenceType,{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5784 | aOriginMetadata, Idempotency::Yes)));{auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }} |
5785 | })){auto tryResult867 = (DatabaseFileManager::TraverseFiles( aFileManagerDirectory , [&aQuotaManager, aPersistenceType, &aOriginMetadata ]( nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult (DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult863.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5765, mozilla::dom::quota::Severity::Error); } return tryResult863 ;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult864.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5771, mozilla::dom::quota::Severity::Error); } return tryResult864 ;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota (file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0)) ) { mozilla::dom::quota::HandleError("ToResult(DeleteFilesNoQuota(file))" , tryResult865.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5779, mozilla::dom::quota::Severity::Error); } return tryResult865 ;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr , aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ( (__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom ::quota::HandleError("ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult866.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5784, mozilla::dom::quota::Severity::Error); } return tryResult866 ;}; })); static_assert(std::is_empty_v<typename decltype(tryResult867 )::ok_type>); if ((__builtin_expect(!!(tryResult867.isErr( )), 0))) { mozilla::dom::quota::HandleError("DatabaseFileManager::TraverseFiles( aFileManagerDirectory, [&aQuotaManager, aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult863 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult863.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult863.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5765, mozilla::dom::quota::Severity::Error); } return tryResult863;}; } {auto tryResult864 = (ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult864.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult864.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5771, mozilla::dom::quota::Severity::Error); } return tryResult864;}; }, [aPersistenceType, &aOriginMetadata]( nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { {auto tryResult865 = (ToResult(DeleteFilesNoQuota(file))); if ((__builtin_expect(!!(tryResult865.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFilesNoQuota(file))\", tryResult865.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5779, mozilla::dom::quota::Severity::Error); } return tryResult865;}; } {auto tryResult866 = (ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))); if ((__builtin_expect(!!(tryResult866.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(DeleteFile(file, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))\", tryResult866.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 5784, mozilla::dom::quota::Severity::Error); } return tryResult866;}; })" , tryResult867.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5785, mozilla::dom::quota::Severity::Error); return tryResult867 .propagateErr(); }}; |
5786 | |
5787 | QM_TRY_RETURN(MOZ_TO_RESULT(aFileManagerDirectory.Remove(false))){auto tryResult868 = (ToResult(aFileManagerDirectory.Remove(false ))); if ((__builtin_expect(!!(tryResult868.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(aFileManagerDirectory.Remove(false))" , tryResult868.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5787, mozilla::dom::quota::Severity::Error); } return tryResult868 ;}; |
5788 | } |
5789 | |
5790 | // Idempotently delete all the parts of an IndexedDB database including its |
5791 | // SQLite database file, its WAL journal, it's shared-memory file, and its |
5792 | // Blob/Files sub-directory. A marker file is created prior to performing the |
5793 | // deletion so that in the event we crash or fail to successfully delete the |
5794 | // database and its files, we will re-attempt the deletion the next time the |
5795 | // origin is initialized using this method. Because this means the method may be |
5796 | // called on a partially deleted database, this method uses DeleteFile which |
5797 | // succeeds when the file we ask it to delete does not actually exist. The |
5798 | // marker file is removed once deletion has successfully completed. |
5799 | nsresult RemoveDatabaseFilesAndDirectory(nsIFile& aBaseDirectory, |
5800 | const nsAString& aDatabaseFilenameBase, |
5801 | QuotaManager* aQuotaManager, |
5802 | const PersistenceType aPersistenceType, |
5803 | const OriginMetadata& aOriginMetadata, |
5804 | const nsAString& aDatabaseName) { |
5805 | AssertIsOnIOThread(); |
5806 | MOZ_ASSERT(!aDatabaseFilenameBase.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseFilenameBase.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseFilenameBase.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!aDatabaseFilenameBase.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5806); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseFilenameBase.IsEmpty()" ")"); do { *((volatile int*)__null) = 5806; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5807 | |
5808 | AUTO_PROFILER_LABEL("RemoveDatabaseFilesAndDirectory", DOM)mozilla::AutoProfilerLabel raiiObject5808( "RemoveDatabaseFilesAndDirectory" , nullptr, JS::ProfilingCategoryPair::DOM); |
5809 | |
5810 | QM_TRY_UNWRAP(auto markerFile,auto tryResult869 = (CreateMarkerFile(aBaseDirectory, aDatabaseFilenameBase )); if ((__builtin_expect(!!(tryResult869.isErr()), 0))) { mozilla ::dom::quota::HandleError("CreateMarkerFile(aBaseDirectory, aDatabaseFilenameBase)" , tryResult869.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5811, mozilla::dom::quota::Severity::Error); return tryResult869 .propagateErr(); } auto markerFile = tryResult869.unwrap(); |
5811 | CreateMarkerFile(aBaseDirectory, aDatabaseFilenameBase))auto tryResult869 = (CreateMarkerFile(aBaseDirectory, aDatabaseFilenameBase )); if ((__builtin_expect(!!(tryResult869.isErr()), 0))) { mozilla ::dom::quota::HandleError("CreateMarkerFile(aBaseDirectory, aDatabaseFilenameBase)" , tryResult869.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5811, mozilla::dom::quota::Severity::Error); return tryResult869 .propagateErr(); } auto markerFile = tryResult869.unwrap();; |
5812 | |
5813 | // The database file counts towards quota. |
5814 | QM_TRY(MOZ_TO_RESULT(DeleteFile({auto tryResult870 = (ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult870)::ok_type>); if ((__builtin_expect( !!(tryResult870.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult870.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5816, mozilla::dom::quota::Severity::Error); return tryResult870 .propagateErr(); }} |
5815 | aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager,{auto tryResult870 = (ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult870)::ok_type>); if ((__builtin_expect( !!(tryResult870.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult870.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5816, mozilla::dom::quota::Severity::Error); return tryResult870 .propagateErr(); }} |
5816 | aPersistenceType, aOriginMetadata, Idempotency::Yes))){auto tryResult870 = (ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult870)::ok_type>); if ((__builtin_expect( !!(tryResult870.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteSuffix, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult870.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5816, mozilla::dom::quota::Severity::Error); return tryResult870 .propagateErr(); }}; |
5817 | |
5818 | // .sqlite-journal files don't count towards quota. |
5819 | QM_TRY(MOZ_TO_RESULT(DeleteFile(aBaseDirectory,{auto tryResult871 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult871)::ok_type>); if ((__builtin_expect( !!(tryResult871.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult871.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5822, mozilla::dom::quota::Severity::Error); return tryResult871 .propagateErr(); }} |
5820 | aDatabaseFilenameBase + kSQLiteJournalSuffix,{auto tryResult871 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult871)::ok_type>); if ((__builtin_expect( !!(tryResult871.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult871.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5822, mozilla::dom::quota::Severity::Error); return tryResult871 .propagateErr(); }} |
5821 | /* doesn't count */ nullptr, aPersistenceType,{auto tryResult871 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult871)::ok_type>); if ((__builtin_expect( !!(tryResult871.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult871.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5822, mozilla::dom::quota::Severity::Error); return tryResult871 .propagateErr(); }} |
5822 | aOriginMetadata, Idempotency::Yes))){auto tryResult871 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult871)::ok_type>); if ((__builtin_expect( !!(tryResult871.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteJournalSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult871.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5822, mozilla::dom::quota::Severity::Error); return tryResult871 .propagateErr(); }}; |
5823 | |
5824 | // .sqlite-shm files don't count towards quota. |
5825 | QM_TRY(MOZ_TO_RESULT(DeleteFile(aBaseDirectory,{auto tryResult872 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult872)::ok_type>); if ((__builtin_expect( !!(tryResult872.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult872.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5828, mozilla::dom::quota::Severity::Error); return tryResult872 .propagateErr(); }} |
5826 | aDatabaseFilenameBase + kSQLiteSHMSuffix,{auto tryResult872 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult872)::ok_type>); if ((__builtin_expect( !!(tryResult872.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult872.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5828, mozilla::dom::quota::Severity::Error); return tryResult872 .propagateErr(); }} |
5827 | /* doesn't count */ nullptr, aPersistenceType,{auto tryResult872 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult872)::ok_type>); if ((__builtin_expect( !!(tryResult872.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult872.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5828, mozilla::dom::quota::Severity::Error); return tryResult872 .propagateErr(); }} |
5828 | aOriginMetadata, Idempotency::Yes))){auto tryResult872 = (ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult872)::ok_type>); if ((__builtin_expect( !!(tryResult872.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile(aBaseDirectory, aDatabaseFilenameBase + kSQLiteSHMSuffix, nullptr, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult872.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5828, mozilla::dom::quota::Severity::Error); return tryResult872 .propagateErr(); }}; |
5829 | |
5830 | // .sqlite-wal files do count towards quota. |
5831 | QM_TRY(MOZ_TO_RESULT(DeleteFile({auto tryResult873 = (ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult873)::ok_type>); if ((__builtin_expect( !!(tryResult873.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult873.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5833, mozilla::dom::quota::Severity::Error); return tryResult873 .propagateErr(); }} |
5832 | aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager,{auto tryResult873 = (ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult873)::ok_type>); if ((__builtin_expect( !!(tryResult873.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult873.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5833, mozilla::dom::quota::Severity::Error); return tryResult873 .propagateErr(); }} |
5833 | aPersistenceType, aOriginMetadata, Idempotency::Yes))){auto tryResult873 = (ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager, aPersistenceType, aOriginMetadata , Idempotency::Yes))); static_assert(std::is_empty_v<typename decltype(tryResult873)::ok_type>); if ((__builtin_expect( !!(tryResult873.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(DeleteFile( aBaseDirectory, aDatabaseFilenameBase + kSQLiteWALSuffix, aQuotaManager, aPersistenceType, aOriginMetadata, Idempotency::Yes))" , tryResult873.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5833, mozilla::dom::quota::Severity::Error); return tryResult873 .propagateErr(); }}; |
5834 | |
5835 | // The files directory counts towards quota. |
5836 | QM_TRY_INSPECT(auto tryResult874 = (CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)); if ((__builtin_expect(! !(tryResult874.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)" , tryResult874.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5839, mozilla::dom::quota::Severity::Error); return tryResult874 .propagateErr(); } const auto& fmDirectory = tryResult874 .inspect(); |
5837 | const auto& fmDirectory,auto tryResult874 = (CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)); if ((__builtin_expect(! !(tryResult874.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)" , tryResult874.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5839, mozilla::dom::quota::Severity::Error); return tryResult874 .propagateErr(); } const auto& fmDirectory = tryResult874 .inspect(); |
5838 | CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase +auto tryResult874 = (CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)); if ((__builtin_expect(! !(tryResult874.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)" , tryResult874.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5839, mozilla::dom::quota::Severity::Error); return tryResult874 .propagateErr(); } const auto& fmDirectory = tryResult874 .inspect(); |
5839 | kFileManagerDirectoryNameSuffix))auto tryResult874 = (CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)); if ((__builtin_expect(! !(tryResult874.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aBaseDirectory, aDatabaseFilenameBase + kFileManagerDirectoryNameSuffix)" , tryResult874.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5839, mozilla::dom::quota::Severity::Error); return tryResult874 .propagateErr(); } const auto& fmDirectory = tryResult874 .inspect();; |
5840 | |
5841 | QM_TRY_INSPECT(const bool& exists,auto tryResult875 = (::mozilla::ToResultInvokeMember( (fmDirectory ), &::mozilla::detail::DerefedType<decltype(fmDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult875.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (fmDirectory), &::mozilla::detail::DerefedType<decltype(fmDirectory)>::Exists)" , tryResult875.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5842, mozilla::dom::quota::Severity::Error); return tryResult875 .propagateErr(); } const bool& exists = tryResult875.inspect (); |
5842 | MOZ_TO_RESULT_INVOKE_MEMBER(fmDirectory, Exists))auto tryResult875 = (::mozilla::ToResultInvokeMember( (fmDirectory ), &::mozilla::detail::DerefedType<decltype(fmDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult875.isErr( )), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (fmDirectory), &::mozilla::detail::DerefedType<decltype(fmDirectory)>::Exists)" , tryResult875.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5842, mozilla::dom::quota::Severity::Error); return tryResult875 .propagateErr(); } const bool& exists = tryResult875.inspect ();; |
5843 | |
5844 | if (exists) { |
5845 | QM_TRY_INSPECT(const bool& isDirectory,auto tryResult876 = (::mozilla::ToResultInvokeMember( (fmDirectory ), &::mozilla::detail::DerefedType<decltype(fmDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult876.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (fmDirectory), &::mozilla::detail::DerefedType<decltype(fmDirectory)>::IsDirectory)" , tryResult876.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5846, mozilla::dom::quota::Severity::Error); return tryResult876 .propagateErr(); } const bool& isDirectory = tryResult876 .inspect(); |
5846 | MOZ_TO_RESULT_INVOKE_MEMBER(fmDirectory, IsDirectory))auto tryResult876 = (::mozilla::ToResultInvokeMember( (fmDirectory ), &::mozilla::detail::DerefedType<decltype(fmDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult876.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (fmDirectory), &::mozilla::detail::DerefedType<decltype(fmDirectory)>::IsDirectory)" , tryResult876.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5846, mozilla::dom::quota::Severity::Error); return tryResult876 .propagateErr(); } const bool& isDirectory = tryResult876 .inspect();; |
5847 | |
5848 | QM_TRY(OkIf(isDirectory), NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR){auto tryResult877 = (OkIf(isDirectory)); static_assert(std:: is_empty_v<typename decltype(tryResult877)::ok_type>); if ((__builtin_expect(!!(tryResult877.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult877.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(isDirectory)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5848, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(isDirectory)" , tryTempError, NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR); }}; |
5849 | |
5850 | QM_TRY(DeleteFileManagerDirectory(*fmDirectory, aQuotaManager,{auto tryResult878 = (DeleteFileManagerDirectory(*fmDirectory , aQuotaManager, aPersistenceType, aOriginMetadata)); static_assert (std::is_empty_v<typename decltype(tryResult878)::ok_type> ); if ((__builtin_expect(!!(tryResult878.isErr()), 0))) { mozilla ::dom::quota::HandleError("DeleteFileManagerDirectory(*fmDirectory, aQuotaManager, aPersistenceType, aOriginMetadata)" , tryResult878.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5851, mozilla::dom::quota::Severity::Error); return tryResult878 .propagateErr(); }} |
5851 | aPersistenceType, aOriginMetadata)){auto tryResult878 = (DeleteFileManagerDirectory(*fmDirectory , aQuotaManager, aPersistenceType, aOriginMetadata)); static_assert (std::is_empty_v<typename decltype(tryResult878)::ok_type> ); if ((__builtin_expect(!!(tryResult878.isErr()), 0))) { mozilla ::dom::quota::HandleError("DeleteFileManagerDirectory(*fmDirectory, aQuotaManager, aPersistenceType, aOriginMetadata)" , tryResult878.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5851, mozilla::dom::quota::Severity::Error); return tryResult878 .propagateErr(); }}; |
5852 | } |
5853 | |
5854 | IndexedDatabaseManager* mgr = IndexedDatabaseManager::Get(); |
5855 | MOZ_ASSERT_IF(aQuotaManager, mgr)do { if (aQuotaManager) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(mgr)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mgr))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("mgr", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5855); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mgr" ")"); do { *((volatile int*)__null) = 5855; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } } while (false ); |
5856 | |
5857 | if (mgr) { |
5858 | mgr->InvalidateFileManager(aPersistenceType, aOriginMetadata.mOrigin, |
5859 | aDatabaseName); |
5860 | } |
5861 | |
5862 | QM_TRY(MOZ_TO_RESULT(RemoveMarkerFile(markerFile))){auto tryResult879 = (ToResult(RemoveMarkerFile(markerFile))) ; static_assert(std::is_empty_v<typename decltype(tryResult879 )::ok_type>); if ((__builtin_expect(!!(tryResult879.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(RemoveMarkerFile(markerFile))" , tryResult879.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5862, mozilla::dom::quota::Severity::Error); return tryResult879 .propagateErr(); }}; |
5863 | |
5864 | return NS_OK; |
5865 | } |
5866 | |
5867 | /******************************************************************************* |
5868 | * Globals |
5869 | ******************************************************************************/ |
5870 | |
5871 | // Counts the number of "live" Factory, FactoryOp and Database instances. |
5872 | uint64_t gBusyCount = 0; |
5873 | |
5874 | using FactoryOpArray = nsTArray<CheckedUnsafePtr<FactoryOp>>; |
5875 | |
5876 | StaticAutoPtr<FactoryOpArray> gFactoryOps; |
5877 | |
5878 | // Maps a database id to information about live database actors. |
5879 | using DatabaseActorHashtable = |
5880 | nsClassHashtable<nsCStringHashKey, DatabaseActorInfo>; |
5881 | |
5882 | StaticAutoPtr<DatabaseActorHashtable> gLiveDatabaseHashtable; |
5883 | |
5884 | StaticRefPtr<ConnectionPool> gConnectionPool; |
5885 | |
5886 | using DatabaseLoggingInfoHashtable = |
5887 | nsTHashMap<nsIDHashKey, DatabaseLoggingInfo*>; |
5888 | |
5889 | StaticAutoPtr<DatabaseLoggingInfoHashtable> gLoggingInfoHashtable; |
5890 | |
5891 | using TelemetryIdHashtable = nsTHashMap<nsUint32HashKey, uint32_t>; |
5892 | |
5893 | StaticAutoPtr<TelemetryIdHashtable> gTelemetryIdHashtable; |
5894 | |
5895 | // Protects all reads and writes to gTelemetryIdHashtable. |
5896 | StaticAutoPtr<Mutex> gTelemetryIdMutex; |
5897 | |
5898 | // For private browsing, maps the raw database names provided by content to a |
5899 | // replacement UUID in order to avoid exposing the name of the database on |
5900 | // disk or a directly derived value, such as the non-private-browsing |
5901 | // representation. This mapping will be the same for all databases with the |
5902 | // same name across all storage keys/origins for the lifetime of the IDB |
5903 | // QuotaClient. In tests, the QuotaClient may be created and destroyed multiple |
5904 | // times, but for normal browser use the QuotaClient will last until the |
5905 | // browser shuts down. Bug 1831835 will improve this implementation to avoid |
5906 | // using the same mapping across storage keys and to deal with the resulting |
5907 | // lifecycle issues of the additional memory use. |
5908 | using StorageDatabaseNameHashtable = nsTHashMap<nsString, nsString>; |
5909 | |
5910 | StaticAutoPtr<StorageDatabaseNameHashtable> gStorageDatabaseNameHashtable; |
5911 | |
5912 | // Protects all reads and writes to gStorageDatabaseNameHashtable. |
5913 | StaticAutoPtr<Mutex> gStorageDatabaseNameMutex; |
5914 | |
5915 | #ifdef DEBUG1 |
5916 | |
5917 | StaticRefPtr<DEBUGThreadSlower> gDEBUGThreadSlower; |
5918 | |
5919 | #endif // DEBUG |
5920 | |
5921 | void IncreaseBusyCount() { |
5922 | AssertIsOnBackgroundThread(); |
5923 | |
5924 | // If this is the first instance then we need to do some initialization. |
5925 | if (!gBusyCount) { |
5926 | MOZ_ASSERT(!gFactoryOps)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!gFactoryOps)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!gFactoryOps))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!gFactoryOps", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5926); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!gFactoryOps" ")"); do { *((volatile int*)__null) = 5926; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5927 | gFactoryOps = new FactoryOpArray(); |
5928 | |
5929 | MOZ_ASSERT(!gLiveDatabaseHashtable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!gLiveDatabaseHashtable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!gLiveDatabaseHashtable))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!gLiveDatabaseHashtable" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5929); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!gLiveDatabaseHashtable" ")"); do { *((volatile int*)__null) = 5929; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5930 | gLiveDatabaseHashtable = new DatabaseActorHashtable(); |
5931 | |
5932 | MOZ_ASSERT(!gLoggingInfoHashtable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!gLoggingInfoHashtable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!gLoggingInfoHashtable))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!gLoggingInfoHashtable" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5932); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!gLoggingInfoHashtable" ")"); do { *((volatile int*)__null) = 5932; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5933 | gLoggingInfoHashtable = new DatabaseLoggingInfoHashtable(); |
5934 | |
5935 | #ifdef DEBUG1 |
5936 | if (kDEBUGThreadPriority != nsISupportsPriority::PRIORITY_NORMAL) { |
5937 | NS_WARNING(NS_DebugBreak(NS_DEBUG_WARNING, "PBackground thread debugging enabled, priority has been " "modified!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5939) |
5938 | "PBackground thread debugging enabled, priority has been "NS_DebugBreak(NS_DEBUG_WARNING, "PBackground thread debugging enabled, priority has been " "modified!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5939) |
5939 | "modified!")NS_DebugBreak(NS_DEBUG_WARNING, "PBackground thread debugging enabled, priority has been " "modified!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5939); |
5940 | nsCOMPtr<nsISupportsPriority> thread = |
5941 | do_QueryInterface(NS_GetCurrentThread()); |
5942 | MOZ_ASSERT(thread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(thread)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(thread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("thread", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5942); AnnotateMozCrashReason("MOZ_ASSERT" "(" "thread" ")" ); do { *((volatile int*)__null) = 5942; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5943 | |
5944 | MOZ_ALWAYS_SUCCEEDS(thread->SetPriority(kDEBUGThreadPriority))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (thread->SetPriority(kDEBUGThreadPriority))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(thread->SetPriority(kDEBUGThreadPriority))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5944); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(thread->SetPriority(kDEBUGThreadPriority))" ")"); do { *((volatile int*)__null) = 5944; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
5945 | } |
5946 | |
5947 | if (kDEBUGThreadSleepMS) { |
5948 | NS_WARNING(NS_DebugBreak(NS_DEBUG_WARNING, "PBackground thread debugging enabled, sleeping after every " "event!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5950) |
5949 | "PBackground thread debugging enabled, sleeping after every "NS_DebugBreak(NS_DEBUG_WARNING, "PBackground thread debugging enabled, sleeping after every " "event!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5950) |
5950 | "event!")NS_DebugBreak(NS_DEBUG_WARNING, "PBackground thread debugging enabled, sleeping after every " "event!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5950); |
5951 | nsCOMPtr<nsIThreadInternal> thread = |
5952 | do_QueryInterface(NS_GetCurrentThread()); |
5953 | MOZ_ASSERT(thread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(thread)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(thread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("thread", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5953); AnnotateMozCrashReason("MOZ_ASSERT" "(" "thread" ")" ); do { *((volatile int*)__null) = 5953; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5954 | |
5955 | gDEBUGThreadSlower = new DEBUGThreadSlower(); |
5956 | |
5957 | MOZ_ALWAYS_SUCCEEDS(thread->AddObserver(gDEBUGThreadSlower))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (thread->AddObserver(gDEBUGThreadSlower))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(thread->AddObserver(gDEBUGThreadSlower))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5957); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(thread->AddObserver(gDEBUGThreadSlower))" ")"); do { *((volatile int*)__null) = 5957; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
5958 | } |
5959 | #endif // DEBUG |
5960 | } |
5961 | |
5962 | gBusyCount++; |
5963 | } |
5964 | |
5965 | void DecreaseBusyCount() { |
5966 | AssertIsOnBackgroundThread(); |
5967 | MOZ_ASSERT(gBusyCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gBusyCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gBusyCount))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("gBusyCount", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5967); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gBusyCount" ")"); do { *((volatile int*)__null) = 5967; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5968 | |
5969 | // Clean up if there are no more instances. |
5970 | if (--gBusyCount == 0) { |
5971 | MOZ_ASSERT(gLoggingInfoHashtable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gLoggingInfoHashtable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gLoggingInfoHashtable))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("gLoggingInfoHashtable" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5971); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gLoggingInfoHashtable" ")"); do { *((volatile int*)__null) = 5971; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5972 | gLoggingInfoHashtable = nullptr; |
5973 | |
5974 | MOZ_ASSERT(gLiveDatabaseHashtable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gLiveDatabaseHashtable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gLiveDatabaseHashtable))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("gLiveDatabaseHashtable" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5974); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gLiveDatabaseHashtable" ")"); do { *((volatile int*)__null) = 5974; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5975 | MOZ_ASSERT(!gLiveDatabaseHashtable->Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!gLiveDatabaseHashtable->Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!gLiveDatabaseHashtable-> Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!gLiveDatabaseHashtable->Count()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5975); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!gLiveDatabaseHashtable->Count()" ")"); do { *((volatile int*)__null) = 5975; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5976 | gLiveDatabaseHashtable = nullptr; |
5977 | |
5978 | MOZ_ASSERT(gFactoryOps)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gFactoryOps)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gFactoryOps))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("gFactoryOps", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5978); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gFactoryOps" ")"); do { *((volatile int*)__null) = 5978; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5979 | MOZ_ASSERT(gFactoryOps->IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(gFactoryOps->IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gFactoryOps->IsEmpty()))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("gFactoryOps->IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5979); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gFactoryOps->IsEmpty()" ")"); do { *((volatile int*)__null) = 5979; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5980 | gFactoryOps = nullptr; |
5981 | |
5982 | #ifdef DEBUG1 |
5983 | if (kDEBUGThreadPriority != nsISupportsPriority::PRIORITY_NORMAL) { |
5984 | nsCOMPtr<nsISupportsPriority> thread = |
5985 | do_QueryInterface(NS_GetCurrentThread()); |
5986 | MOZ_ASSERT(thread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(thread)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(thread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("thread", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5986); AnnotateMozCrashReason("MOZ_ASSERT" "(" "thread" ")" ); do { *((volatile int*)__null) = 5986; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5987 | |
5988 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL) )), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5989); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL))" ")"); do { *((volatile int*)__null) = 5989; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
5989 | thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL) )), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5989); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(thread->SetPriority(nsISupportsPriority::PRIORITY_NORMAL))" ")"); do { *((volatile int*)__null) = 5989; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
5990 | } |
5991 | |
5992 | if (kDEBUGThreadSleepMS) { |
5993 | MOZ_ASSERT(gDEBUGThreadSlower)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gDEBUGThreadSlower)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gDEBUGThreadSlower))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("gDEBUGThreadSlower" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5993); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gDEBUGThreadSlower" ")"); do { *((volatile int*)__null) = 5993; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5994 | |
5995 | nsCOMPtr<nsIThreadInternal> thread = |
5996 | do_QueryInterface(NS_GetCurrentThread()); |
5997 | MOZ_ASSERT(thread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(thread)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(thread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("thread", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5997); AnnotateMozCrashReason("MOZ_ASSERT" "(" "thread" ")" ); do { *((volatile int*)__null) = 5997; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
5998 | |
5999 | MOZ_ALWAYS_SUCCEEDS(thread->RemoveObserver(gDEBUGThreadSlower))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (thread->RemoveObserver(gDEBUGThreadSlower))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(thread->RemoveObserver(gDEBUGThreadSlower))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 5999); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(thread->RemoveObserver(gDEBUGThreadSlower))" ")"); do { *((volatile int*)__null) = 5999; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6000 | |
6001 | gDEBUGThreadSlower = nullptr; |
6002 | } |
6003 | #endif // DEBUG |
6004 | } |
6005 | } |
6006 | |
6007 | template <typename Condition> |
6008 | void InvalidateLiveDatabasesMatching(const Condition& aCondition) { |
6009 | AssertIsOnBackgroundThread(); |
6010 | |
6011 | if (!gLiveDatabaseHashtable) { |
6012 | return; |
6013 | } |
6014 | |
6015 | // Invalidating a Database will cause it to be removed from the |
6016 | // gLiveDatabaseHashtable entries' mLiveDatabases, and, if it was the last |
6017 | // element in mLiveDatabases, to remove the whole hashtable entry. Therefore, |
6018 | // we need to make a temporary list of the databases to invalidate to avoid |
6019 | // iterator invalidation. |
6020 | |
6021 | nsTArray<SafeRefPtr<Database>> databases; |
6022 | |
6023 | for (const auto& liveDatabasesEntry : gLiveDatabaseHashtable->Values()) { |
6024 | for (const auto& database : liveDatabasesEntry->mLiveDatabases) { |
6025 | if (aCondition(*database)) { |
6026 | databases.AppendElement( |
6027 | SafeRefPtr{database.get(), AcquireStrongRefFromRawPtr{}}); |
6028 | } |
6029 | } |
6030 | } |
6031 | |
6032 | for (const auto& database : databases) { |
6033 | database->Invalidate(); |
6034 | } |
6035 | } |
6036 | |
6037 | uint32_t TelemetryIdForFile(nsIFile* aFile) { |
6038 | // May be called on any thread! |
6039 | |
6040 | MOZ_ASSERT(aFile)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aFile)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(aFile))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("aFile", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6040); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFile" ")") ; do { *((volatile int*)__null) = 6040; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6041 | MOZ_ASSERT(gTelemetryIdMutex)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gTelemetryIdMutex)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gTelemetryIdMutex))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("gTelemetryIdMutex" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6041); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gTelemetryIdMutex" ")"); do { *((volatile int*)__null) = 6041; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6042 | |
6043 | // The storage directory is structured like this: |
6044 | // |
6045 | // <profile>/storage/<persistence>/<origin>/idb/<filename>.sqlite |
6046 | // |
6047 | // For the purposes of this function we're only concerned with the |
6048 | // <persistence>, <origin>, and <filename> pieces. |
6049 | |
6050 | nsString filename; |
6051 | MOZ_ALWAYS_SUCCEEDS(aFile->GetLeafName(filename))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aFile->GetLeafName(filename))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aFile->GetLeafName(filename))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6051); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aFile->GetLeafName(filename))" ")"); do { *((volatile int*)__null) = 6051; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6052 | |
6053 | // Make sure we were given a database file. |
6054 | MOZ_ASSERT(StringEndsWith(filename, kSQLiteSuffix))do { static_assert( mozilla::detail::AssertionConditionType< decltype(StringEndsWith(filename, kSQLiteSuffix))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(StringEndsWith(filename, kSQLiteSuffix)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("StringEndsWith(filename, kSQLiteSuffix)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6054); AnnotateMozCrashReason("MOZ_ASSERT" "(" "StringEndsWith(filename, kSQLiteSuffix)" ")"); do { *((volatile int*)__null) = 6054; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6055 | |
6056 | filename.Truncate(filename.Length() - kSQLiteSuffix.Length()); |
6057 | |
6058 | // Get the "idb" directory. |
6059 | nsCOMPtr<nsIFile> idbDirectory; |
6060 | MOZ_ALWAYS_SUCCEEDS(aFile->GetParent(getter_AddRefs(idbDirectory)))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aFile->GetParent(getter_AddRefs(idbDirectory)))), 1)))), 1 ))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aFile->GetParent(getter_AddRefs(idbDirectory)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6060); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aFile->GetParent(getter_AddRefs(idbDirectory)))" ")"); do { *((volatile int*)__null) = 6060; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6061 | |
6062 | DebugOnly<nsString> idbLeafName; |
6063 | MOZ_ASSERT(NS_SUCCEEDED(idbDirectory->GetLeafName(idbLeafName)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(idbDirectory ->GetLeafName(idbLeafName))), 1))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( !NS_FAILED_impl(idbDirectory->GetLeafName(idbLeafName))), 1 )))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("((bool)(__builtin_expect(!!(!NS_FAILED_impl(idbDirectory->GetLeafName(idbLeafName))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6063); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(idbDirectory->GetLeafName(idbLeafName))), 1)))" ")"); do { *((volatile int*)__null) = 6063; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6064 | MOZ_ASSERT(static_cast<nsString&>(idbLeafName).EqualsLiteral("idb"))do { static_assert( mozilla::detail::AssertionConditionType< decltype(static_cast<nsString&>(idbLeafName).EqualsLiteral ("idb"))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(static_cast<nsString&>(idbLeafName).EqualsLiteral ("idb")))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("static_cast<nsString&>(idbLeafName).EqualsLiteral(\"idb\")" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6064); AnnotateMozCrashReason("MOZ_ASSERT" "(" "static_cast<nsString&>(idbLeafName).EqualsLiteral(\"idb\")" ")"); do { *((volatile int*)__null) = 6064; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6065 | |
6066 | // Get the <origin> directory. |
6067 | nsCOMPtr<nsIFile> originDirectory; |
6068 | MOZ_ALWAYS_SUCCEEDS(idbDirectory->GetParent(getter_AddRefs(originDirectory)))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (idbDirectory->GetParent(getter_AddRefs(originDirectory))) ), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(idbDirectory->GetParent(getter_AddRefs(originDirectory)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6068); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(idbDirectory->GetParent(getter_AddRefs(originDirectory)))" ")"); do { *((volatile int*)__null) = 6068; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6069 | |
6070 | nsString origin; |
6071 | MOZ_ALWAYS_SUCCEEDS(originDirectory->GetLeafName(origin))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (originDirectory->GetLeafName(origin))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(originDirectory->GetLeafName(origin))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6071); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(originDirectory->GetLeafName(origin))" ")"); do { *((volatile int*)__null) = 6071; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6072 | |
6073 | // Any databases in these directories are owned by the application and should |
6074 | // not have their filenames masked. Hopefully they also appear in the |
6075 | // Telemetry.cpp whitelist. |
6076 | if (origin.EqualsLiteral("chrome") || |
6077 | origin.EqualsLiteral("moz-safe-about+home")) { |
6078 | return 0; |
6079 | } |
6080 | |
6081 | // Get the <persistence> directory. |
6082 | nsCOMPtr<nsIFile> persistenceDirectory; |
6083 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (originDirectory->GetParent(getter_AddRefs(persistenceDirectory )))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(originDirectory->GetParent(getter_AddRefs(persistenceDirectory)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6084); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(originDirectory->GetParent(getter_AddRefs(persistenceDirectory)))" ")"); do { *((volatile int*)__null) = 6084; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
6084 | originDirectory->GetParent(getter_AddRefs(persistenceDirectory)))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (originDirectory->GetParent(getter_AddRefs(persistenceDirectory )))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(originDirectory->GetParent(getter_AddRefs(persistenceDirectory)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6084); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(originDirectory->GetParent(getter_AddRefs(persistenceDirectory)))" ")"); do { *((volatile int*)__null) = 6084; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6085 | |
6086 | nsString persistence; |
6087 | MOZ_ALWAYS_SUCCEEDS(persistenceDirectory->GetLeafName(persistence))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (persistenceDirectory->GetLeafName(persistence))), 1)))), 1 ))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(persistenceDirectory->GetLeafName(persistence))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6087); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(persistenceDirectory->GetLeafName(persistence))" ")"); do { *((volatile int*)__null) = 6087; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6088 | |
6089 | constexpr auto separator = u"*"_ns; |
6090 | |
6091 | uint32_t hashValue = |
6092 | HashString(persistence + separator + origin + separator + filename); |
6093 | |
6094 | MutexAutoLock lock(*gTelemetryIdMutex); |
6095 | |
6096 | if (!gTelemetryIdHashtable) { |
6097 | gTelemetryIdHashtable = new TelemetryIdHashtable(); |
6098 | } |
6099 | |
6100 | return gTelemetryIdHashtable->LookupOrInsertWith(hashValue, [] { |
6101 | static uint32_t sNextId = 1; |
6102 | |
6103 | // We're locked, no need for atomics. |
6104 | return sNextId++; |
6105 | }); |
6106 | } |
6107 | |
6108 | nsAutoString GetDatabaseFilenameBase(const nsAString& aDatabaseName, |
6109 | bool aIsPrivate) { |
6110 | nsAutoString databaseFilenameBase; |
6111 | |
6112 | if (aIsPrivate) { |
6113 | MOZ_DIAGNOSTIC_ASSERT(gStorageDatabaseNameMutex)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gStorageDatabaseNameMutex)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gStorageDatabaseNameMutex))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("gStorageDatabaseNameMutex" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6113); AnnotateMozCrashReason("MOZ_DIAGNOSTIC_ASSERT" "(" "gStorageDatabaseNameMutex" ")"); do { *((volatile int*)__null) = 6113; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6114 | |
6115 | MutexAutoLock lock(*gStorageDatabaseNameMutex); |
6116 | |
6117 | if (!gStorageDatabaseNameHashtable) { |
6118 | gStorageDatabaseNameHashtable = new StorageDatabaseNameHashtable(); |
6119 | } |
6120 | |
6121 | databaseFilenameBase.Append( |
6122 | gStorageDatabaseNameHashtable->LookupOrInsertWith(aDatabaseName, []() { |
6123 | return NSID_TrimBracketsUTF16(nsID::GenerateUUID()); |
6124 | })); |
6125 | |
6126 | return databaseFilenameBase; |
6127 | } |
6128 | |
6129 | // WARNING: do not change this hash function. See the comment in HashName() |
6130 | // for details. |
6131 | databaseFilenameBase.AppendInt(HashName(aDatabaseName)); |
6132 | |
6133 | nsAutoCString escapedName; |
6134 | if (!NS_Escape(NS_ConvertUTF16toUTF8(aDatabaseName), escapedName, |
6135 | url_XPAlphas)) { |
6136 | MOZ_CRASH("Can't escape database name!")do { do { } while (false); MOZ_ReportCrash("" "Can't escape database name!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6136); AnnotateMozCrashReason("MOZ_CRASH(" "Can't escape database name!" ")"); do { *((volatile int*)__null) = 6136; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
6137 | } |
6138 | |
6139 | const char* forwardIter = escapedName.BeginReading(); |
6140 | const char* backwardIter = escapedName.EndReading() - 1; |
6141 | |
6142 | nsAutoCString substring; |
6143 | while (forwardIter <= backwardIter && substring.Length() < 21) { |
6144 | if (substring.Length() % 2) { |
6145 | substring.Append(*backwardIter--); |
6146 | } else { |
6147 | substring.Append(*forwardIter++); |
6148 | } |
6149 | } |
6150 | |
6151 | databaseFilenameBase.AppendASCII(substring.get(), substring.Length()); |
6152 | |
6153 | return databaseFilenameBase; |
6154 | } |
6155 | |
6156 | const CommonIndexOpenCursorParams& GetCommonIndexOpenCursorParams( |
6157 | const OpenCursorParams& aParams) { |
6158 | switch (aParams.type()) { |
6159 | case OpenCursorParams::TIndexOpenCursorParams: |
6160 | return aParams.get_IndexOpenCursorParams().commonIndexParams(); |
6161 | case OpenCursorParams::TIndexOpenKeyCursorParams: |
6162 | return aParams.get_IndexOpenKeyCursorParams().commonIndexParams(); |
6163 | default: |
6164 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6164); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 6164; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
6165 | } |
6166 | } |
6167 | |
6168 | const CommonOpenCursorParams& GetCommonOpenCursorParams( |
6169 | const OpenCursorParams& aParams) { |
6170 | switch (aParams.type()) { |
6171 | case OpenCursorParams::TObjectStoreOpenCursorParams: |
6172 | return aParams.get_ObjectStoreOpenCursorParams().commonParams(); |
6173 | case OpenCursorParams::TObjectStoreOpenKeyCursorParams: |
6174 | return aParams.get_ObjectStoreOpenKeyCursorParams().commonParams(); |
6175 | case OpenCursorParams::TIndexOpenCursorParams: |
6176 | case OpenCursorParams::TIndexOpenKeyCursorParams: |
6177 | return GetCommonIndexOpenCursorParams(aParams).commonParams(); |
6178 | default: |
6179 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6179); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 6179; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
6180 | } |
6181 | } |
6182 | |
6183 | // TODO: Using nsCString as a return type here seems to lead to a dependency on |
6184 | // some temporaries, which I did not expect. Is it a good idea that the default |
6185 | // operator+ behaviour constructs such strings? It is certainly useful as an |
6186 | // optimization, but this should be better done via an appropriately named |
6187 | // function rather than an operator. |
6188 | nsAutoCString MakeColumnPairSelectionList( |
6189 | const nsLiteralCString& aPlainColumnName, |
6190 | const nsLiteralCString& aLocaleAwareColumnName, |
6191 | const nsLiteralCString& aSortColumnAlias, const bool aIsLocaleAware) { |
6192 | return aPlainColumnName + |
6193 | (aIsLocaleAware ? EmptyCString() : " as "_ns + aSortColumnAlias) + |
6194 | ", "_ns + aLocaleAwareColumnName + |
6195 | (aIsLocaleAware ? " as "_ns + aSortColumnAlias : EmptyCString()); |
6196 | } |
6197 | |
6198 | constexpr bool IsIncreasingOrder(const IDBCursorDirection aDirection) { |
6199 | MOZ_ASSERT(aDirection == IDBCursorDirection::Next ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6202); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6202; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
6200 | aDirection == IDBCursorDirection::Nextunique ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6202); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6202; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
6201 | aDirection == IDBCursorDirection::Prev ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6202); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6202; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
6202 | aDirection == IDBCursorDirection::Prevunique)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6202); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6202; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6203 | |
6204 | return aDirection == IDBCursorDirection::Next || |
6205 | aDirection == IDBCursorDirection::Nextunique; |
6206 | } |
6207 | |
6208 | constexpr bool IsUnique(const IDBCursorDirection aDirection) { |
6209 | MOZ_ASSERT(aDirection == IDBCursorDirection::Next ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6212); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6212; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
6210 | aDirection == IDBCursorDirection::Nextunique ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6212); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6212; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
6211 | aDirection == IDBCursorDirection::Prev ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6212); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6212; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
6212 | aDirection == IDBCursorDirection::Prevunique)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection ::Prev || aDirection == IDBCursorDirection::Prevunique))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6212); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirection == IDBCursorDirection::Next || aDirection == IDBCursorDirection::Nextunique || aDirection == IDBCursorDirection::Prev || aDirection == IDBCursorDirection::Prevunique" ")"); do { *((volatile int*)__null) = 6212; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6213 | |
6214 | return aDirection == IDBCursorDirection::Nextunique || |
6215 | aDirection == IDBCursorDirection::Prevunique; |
6216 | } |
6217 | |
6218 | // TODO: In principle, this could be constexpr, if operator+(nsLiteralCString, |
6219 | // nsLiteralCString) were constexpr and returned a literal type. |
6220 | nsAutoCString MakeDirectionClause(const IDBCursorDirection aDirection) { |
6221 | return " ORDER BY "_ns + kColumnNameKey + |
6222 | (IsIncreasingOrder(aDirection) ? " ASC"_ns : " DESC"_ns); |
6223 | } |
6224 | |
6225 | enum struct ComparisonOperator { |
6226 | LessThan, |
6227 | LessOrEquals, |
6228 | Equals, |
6229 | GreaterThan, |
6230 | GreaterOrEquals, |
6231 | }; |
6232 | |
6233 | constexpr nsLiteralCString GetComparisonOperatorString( |
6234 | const ComparisonOperator aComparisonOperator) { |
6235 | switch (aComparisonOperator) { |
6236 | case ComparisonOperator::LessThan: |
6237 | return "<"_ns; |
6238 | case ComparisonOperator::LessOrEquals: |
6239 | return "<="_ns; |
6240 | case ComparisonOperator::Equals: |
6241 | return "=="_ns; |
6242 | case ComparisonOperator::GreaterThan: |
6243 | return ">"_ns; |
6244 | case ComparisonOperator::GreaterOrEquals: |
6245 | return ">="_ns; |
6246 | } |
6247 | |
6248 | // TODO: This is just to silence the "control reaches end of non-void |
6249 | // function" warning. Cannot use MOZ_CRASH in a constexpr function, |
6250 | // unfortunately. |
6251 | return ""_ns; |
6252 | } |
6253 | |
6254 | nsAutoCString GetKeyClause(const nsACString& aColumnName, |
6255 | const ComparisonOperator aComparisonOperator, |
6256 | const nsLiteralCString& aStmtParamName) { |
6257 | return aColumnName + " "_ns + |
6258 | GetComparisonOperatorString(aComparisonOperator) + " :"_ns + |
6259 | aStmtParamName; |
6260 | } |
6261 | |
6262 | nsAutoCString GetSortKeyClause(const ComparisonOperator aComparisonOperator, |
6263 | const nsLiteralCString& aStmtParamName) { |
6264 | return GetKeyClause(kColumnNameAliasSortKey, aComparisonOperator, |
6265 | aStmtParamName); |
6266 | } |
6267 | |
6268 | template <IDBCursorType CursorType> |
6269 | struct PopulateResponseHelper; |
6270 | |
6271 | struct CommonPopulateResponseHelper { |
6272 | explicit CommonPopulateResponseHelper( |
6273 | const TransactionDatabaseOperationBase& aOp) |
6274 | : mOp{aOp} {} |
6275 | |
6276 | nsresult GetKeys(mozIStorageStatement* const aStmt, |
6277 | Key* const aOptOutSortKey) { |
6278 | QM_TRY(MOZ_TO_RESULT(GetCommonKeys(aStmt))){auto tryResult880 = (ToResult(GetCommonKeys(aStmt))); static_assert (std::is_empty_v<typename decltype(tryResult880)::ok_type> ); if ((__builtin_expect(!!(tryResult880.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(GetCommonKeys(aStmt))", tryResult880 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6278, mozilla::dom::quota::Severity::Error); return tryResult880 .propagateErr(); }}; |
6279 | |
6280 | if (aOptOutSortKey) { |
6281 | *aOptOutSortKey = mPosition; |
6282 | } |
6283 | |
6284 | return NS_OK; |
6285 | } |
6286 | |
6287 | nsresult GetCommonKeys(mozIStorageStatement* const aStmt) { |
6288 | MOZ_ASSERT(mPosition.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mPosition.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mPosition.IsUnset()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mPosition.IsUnset()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6288); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mPosition.IsUnset()" ")"); do { *((volatile int*)__null) = 6288; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6289 | |
6290 | QM_TRY(MOZ_TO_RESULT(mPosition.SetFromStatement(aStmt, 0))){auto tryResult881 = (ToResult(mPosition.SetFromStatement(aStmt , 0))); static_assert(std::is_empty_v<typename decltype(tryResult881 )::ok_type>); if ((__builtin_expect(!!(tryResult881.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(mPosition.SetFromStatement(aStmt, 0))" , tryResult881.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6290, mozilla::dom::quota::Severity::Error); return tryResult881 .propagateErr(); }}; |
6291 | |
6292 | IDB_LOG_MARK_PARENT_TRANSACTION_REQUEST(mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" " " "Request[%" "l" "u" "]" ": " "PRELOAD: Populating response with key %s", "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" " " "R[%" "l" "u" "]" ": " "Populating%.0s" , mozilla::dom::indexedDB::LoggingIdString<true>(mOp.BackgroundChildLoggingId ()).get(), mOp.TransactionLoggingSerialNumber(), mOp.LoggingSerialNumber (), mPosition.GetBuffer().get()) |
6293 | "PRELOAD: Populating response with key %s", "Populating%.0s",mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" " " "Request[%" "l" "u" "]" ": " "PRELOAD: Populating response with key %s", "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" " " "R[%" "l" "u" "]" ": " "Populating%.0s" , mozilla::dom::indexedDB::LoggingIdString<true>(mOp.BackgroundChildLoggingId ()).get(), mOp.TransactionLoggingSerialNumber(), mOp.LoggingSerialNumber (), mPosition.GetBuffer().get()) |
6294 | IDB_LOG_ID_STRING(mOp.BackgroundChildLoggingId()),mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" " " "Request[%" "l" "u" "]" ": " "PRELOAD: Populating response with key %s", "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" " " "R[%" "l" "u" "]" ": " "Populating%.0s" , mozilla::dom::indexedDB::LoggingIdString<true>(mOp.BackgroundChildLoggingId ()).get(), mOp.TransactionLoggingSerialNumber(), mOp.LoggingSerialNumber (), mPosition.GetBuffer().get()) |
6295 | mOp.TransactionLoggingSerialNumber(), mOp.LoggingSerialNumber(),mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" " " "Request[%" "l" "u" "]" ": " "PRELOAD: Populating response with key %s", "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" " " "R[%" "l" "u" "]" ": " "Populating%.0s" , mozilla::dom::indexedDB::LoggingIdString<true>(mOp.BackgroundChildLoggingId ()).get(), mOp.TransactionLoggingSerialNumber(), mOp.LoggingSerialNumber (), mPosition.GetBuffer().get()) |
6296 | mPosition.GetBuffer().get())mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" " " "Request[%" "l" "u" "]" ": " "PRELOAD: Populating response with key %s", "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" " " "R[%" "l" "u" "]" ": " "Populating%.0s" , mozilla::dom::indexedDB::LoggingIdString<true>(mOp.BackgroundChildLoggingId ()).get(), mOp.TransactionLoggingSerialNumber(), mOp.LoggingSerialNumber (), mPosition.GetBuffer().get()); |
6297 | |
6298 | return NS_OK; |
6299 | } |
6300 | |
6301 | template <typename Response> |
6302 | void FillKeys(Response& aResponse) { |
6303 | MOZ_ASSERT(!mPosition.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mPosition.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mPosition.IsUnset()))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mPosition.IsUnset()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6303); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mPosition.IsUnset()" ")"); do { *((volatile int*)__null) = 6303; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6304 | aResponse.key() = std::move(mPosition); |
6305 | } |
6306 | |
6307 | template <typename Response> |
6308 | static size_t GetKeySize(const Response& aResponse) { |
6309 | return aResponse.key().GetBuffer().Length(); |
6310 | } |
6311 | |
6312 | protected: |
6313 | const Key& GetPosition() const { return mPosition; } |
6314 | |
6315 | private: |
6316 | const TransactionDatabaseOperationBase& mOp; |
6317 | Key mPosition; |
6318 | }; |
6319 | |
6320 | struct IndexPopulateResponseHelper : CommonPopulateResponseHelper { |
6321 | using CommonPopulateResponseHelper::CommonPopulateResponseHelper; |
6322 | |
6323 | nsresult GetKeys(mozIStorageStatement* const aStmt, |
6324 | Key* const aOptOutSortKey) { |
6325 | MOZ_ASSERT(mLocaleAwarePosition.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLocaleAwarePosition.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mLocaleAwarePosition.IsUnset ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mLocaleAwarePosition.IsUnset()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6325); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLocaleAwarePosition.IsUnset()" ")"); do { *((volatile int*)__null) = 6325; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6326 | MOZ_ASSERT(mObjectStorePosition.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mObjectStorePosition.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mObjectStorePosition.IsUnset ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mObjectStorePosition.IsUnset()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6326); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mObjectStorePosition.IsUnset()" ")"); do { *((volatile int*)__null) = 6326; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6327 | |
6328 | QM_TRY(MOZ_TO_RESULT(CommonPopulateResponseHelper::GetCommonKeys(aStmt))){auto tryResult882 = (ToResult(CommonPopulateResponseHelper:: GetCommonKeys(aStmt))); static_assert(std::is_empty_v<typename decltype(tryResult882)::ok_type>); if ((__builtin_expect( !!(tryResult882.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(CommonPopulateResponseHelper::GetCommonKeys(aStmt))" , tryResult882.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6328, mozilla::dom::quota::Severity::Error); return tryResult882 .propagateErr(); }}; |
6329 | |
6330 | QM_TRY(MOZ_TO_RESULT(mLocaleAwarePosition.SetFromStatement(aStmt, 1))){auto tryResult883 = (ToResult(mLocaleAwarePosition.SetFromStatement (aStmt, 1))); static_assert(std::is_empty_v<typename decltype (tryResult883)::ok_type>); if ((__builtin_expect(!!(tryResult883 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(mLocaleAwarePosition.SetFromStatement(aStmt, 1))" , tryResult883.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6330, mozilla::dom::quota::Severity::Error); return tryResult883 .propagateErr(); }}; |
6331 | |
6332 | QM_TRY(MOZ_TO_RESULT(mObjectStorePosition.SetFromStatement(aStmt, 2))){auto tryResult884 = (ToResult(mObjectStorePosition.SetFromStatement (aStmt, 2))); static_assert(std::is_empty_v<typename decltype (tryResult884)::ok_type>); if ((__builtin_expect(!!(tryResult884 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(mObjectStorePosition.SetFromStatement(aStmt, 2))" , tryResult884.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6332, mozilla::dom::quota::Severity::Error); return tryResult884 .propagateErr(); }}; |
6333 | |
6334 | if (aOptOutSortKey) { |
6335 | *aOptOutSortKey = |
6336 | mLocaleAwarePosition.IsUnset() ? GetPosition() : mLocaleAwarePosition; |
6337 | } |
6338 | |
6339 | return NS_OK; |
6340 | } |
6341 | |
6342 | template <typename Response> |
6343 | void FillKeys(Response& aResponse) { |
6344 | MOZ_ASSERT(!mLocaleAwarePosition.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mLocaleAwarePosition.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mLocaleAwarePosition.IsUnset ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mLocaleAwarePosition.IsUnset()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6344); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mLocaleAwarePosition.IsUnset()" ")"); do { *((volatile int*)__null) = 6344; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6345 | MOZ_ASSERT(!mObjectStorePosition.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mObjectStorePosition.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mObjectStorePosition.IsUnset ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mObjectStorePosition.IsUnset()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6345); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mObjectStorePosition.IsUnset()" ")"); do { *((volatile int*)__null) = 6345; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6346 | |
6347 | CommonPopulateResponseHelper::FillKeys(aResponse); |
6348 | aResponse.sortKey() = std::move(mLocaleAwarePosition); |
6349 | aResponse.objectKey() = std::move(mObjectStorePosition); |
6350 | } |
6351 | |
6352 | template <typename Response> |
6353 | static size_t GetKeySize(Response& aResponse) { |
6354 | return CommonPopulateResponseHelper::GetKeySize(aResponse) + |
6355 | aResponse.sortKey().GetBuffer().Length() + |
6356 | aResponse.objectKey().GetBuffer().Length(); |
6357 | } |
6358 | |
6359 | private: |
6360 | Key mLocaleAwarePosition, mObjectStorePosition; |
6361 | }; |
6362 | |
6363 | struct KeyPopulateResponseHelper { |
6364 | static constexpr nsresult MaybeGetCloneInfo( |
6365 | mozIStorageStatement* const /*aStmt*/, const CursorBase& /*aCursor*/) { |
6366 | return NS_OK; |
6367 | } |
6368 | |
6369 | template <typename Response> |
6370 | static constexpr void MaybeFillCloneInfo(Response& /*aResponse*/, |
6371 | FilesArray* const /*aFiles*/) {} |
6372 | |
6373 | template <typename Response> |
6374 | static constexpr size_t MaybeGetCloneInfoSize(const Response& /*aResponse*/) { |
6375 | return 0; |
6376 | } |
6377 | }; |
6378 | |
6379 | template <bool StatementHasIndexKeyBindings> |
6380 | struct ValuePopulateResponseHelper { |
6381 | nsresult MaybeGetCloneInfo(mozIStorageStatement* const aStmt, |
6382 | const ValueCursorBase& aCursor) { |
6383 | constexpr auto offset = StatementHasIndexKeyBindings ? 2 : 0; |
6384 | |
6385 | QM_TRY_UNWRAP(auto cloneInfo,auto tryResult885 = (GetStructuredCloneReadInfoFromStatement( aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager)); if ( (__builtin_expect(!!(tryResult885.isErr()), 0))) { mozilla::dom ::quota::HandleError("GetStructuredCloneReadInfoFromStatement( aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager)" , tryResult885.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6387, mozilla::dom::quota::Severity::Error); return tryResult885 .propagateErr(); } auto cloneInfo = tryResult885.unwrap(); |
6386 | GetStructuredCloneReadInfoFromStatement(auto tryResult885 = (GetStructuredCloneReadInfoFromStatement( aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager)); if ( (__builtin_expect(!!(tryResult885.isErr()), 0))) { mozilla::dom ::quota::HandleError("GetStructuredCloneReadInfoFromStatement( aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager)" , tryResult885.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6387, mozilla::dom::quota::Severity::Error); return tryResult885 .propagateErr(); } auto cloneInfo = tryResult885.unwrap(); |
6387 | aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager))auto tryResult885 = (GetStructuredCloneReadInfoFromStatement( aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager)); if ( (__builtin_expect(!!(tryResult885.isErr()), 0))) { mozilla::dom ::quota::HandleError("GetStructuredCloneReadInfoFromStatement( aStmt, 2 + offset, 1 + offset, *aCursor.mFileManager)" , tryResult885.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6387, mozilla::dom::quota::Severity::Error); return tryResult885 .propagateErr(); } auto cloneInfo = tryResult885.unwrap();; |
6388 | |
6389 | mCloneInfo.init(std::move(cloneInfo)); |
6390 | |
6391 | if (mCloneInfo->HasPreprocessInfo()) { |
6392 | IDB_WARNING("Preprocessing for cursors not yet implemented!")do { nsPrintfCString s("Preprocessing for cursors not yet implemented!" ); mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6392, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6392); } while (0); |
6393 | return NS_ERROR_NOT_IMPLEMENTED; |
6394 | } |
6395 | |
6396 | return NS_OK; |
6397 | } |
6398 | |
6399 | template <typename Response> |
6400 | void MaybeFillCloneInfo(Response& aResponse, FilesArray* const aFiles) { |
6401 | auto cloneInfo = mCloneInfo.release(); |
6402 | aResponse.cloneInfo().data().data = cloneInfo.ReleaseData(); |
6403 | aFiles->AppendElement(cloneInfo.ReleaseFiles()); |
6404 | } |
6405 | |
6406 | template <typename Response> |
6407 | static size_t MaybeGetCloneInfoSize(const Response& aResponse) { |
6408 | return aResponse.cloneInfo().data().data.Size(); |
6409 | } |
6410 | |
6411 | private: |
6412 | LazyInitializedOnceEarlyDestructible<const StructuredCloneReadInfoParent> |
6413 | mCloneInfo; |
6414 | }; |
6415 | |
6416 | template <> |
6417 | struct PopulateResponseHelper<IDBCursorType::ObjectStore> |
6418 | : ValuePopulateResponseHelper<false>, CommonPopulateResponseHelper { |
6419 | using CommonPopulateResponseHelper::CommonPopulateResponseHelper; |
6420 | |
6421 | static auto& GetTypedResponse(CursorResponse* const aResponse) { |
6422 | return aResponse->get_ArrayOfObjectStoreCursorResponse(); |
6423 | } |
6424 | }; |
6425 | |
6426 | template <> |
6427 | struct PopulateResponseHelper<IDBCursorType::ObjectStoreKey> |
6428 | : KeyPopulateResponseHelper, CommonPopulateResponseHelper { |
6429 | using CommonPopulateResponseHelper::CommonPopulateResponseHelper; |
6430 | |
6431 | static auto& GetTypedResponse(CursorResponse* const aResponse) { |
6432 | return aResponse->get_ArrayOfObjectStoreKeyCursorResponse(); |
6433 | } |
6434 | }; |
6435 | |
6436 | template <> |
6437 | struct PopulateResponseHelper<IDBCursorType::Index> |
6438 | : ValuePopulateResponseHelper<true>, IndexPopulateResponseHelper { |
6439 | using IndexPopulateResponseHelper::IndexPopulateResponseHelper; |
6440 | |
6441 | static auto& GetTypedResponse(CursorResponse* const aResponse) { |
6442 | return aResponse->get_ArrayOfIndexCursorResponse(); |
6443 | } |
6444 | }; |
6445 | |
6446 | template <> |
6447 | struct PopulateResponseHelper<IDBCursorType::IndexKey> |
6448 | : KeyPopulateResponseHelper, IndexPopulateResponseHelper { |
6449 | using IndexPopulateResponseHelper::IndexPopulateResponseHelper; |
6450 | |
6451 | static auto& GetTypedResponse(CursorResponse* const aResponse) { |
6452 | return aResponse->get_ArrayOfIndexKeyCursorResponse(); |
6453 | } |
6454 | }; |
6455 | |
6456 | nsresult DispatchAndReturnFileReferences( |
6457 | PersistenceType aPersistenceType, const nsACString& aOrigin, |
6458 | const nsAString& aDatabaseName, const int64_t aFileId, |
6459 | int32_t* const aMemRefCnt, int32_t* const aDBRefCnt, bool* const aResult) { |
6460 | AssertIsOnBackgroundThread(); |
6461 | MOZ_ASSERT(aMemRefCnt)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMemRefCnt)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMemRefCnt))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aMemRefCnt", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6461); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMemRefCnt" ")"); do { *((volatile int*)__null) = 6461; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6462 | MOZ_ASSERT(aDBRefCnt)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDBRefCnt)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDBRefCnt))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDBRefCnt", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6462); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDBRefCnt" ")" ); do { *((volatile int*)__null) = 6462; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6463 | MOZ_ASSERT(aResult)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aResult)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aResult))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aResult", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6463); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aResult" ")" ); do { *((volatile int*)__null) = 6463; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6464 | |
6465 | *aResult = false; |
6466 | *aMemRefCnt = -1; |
6467 | *aDBRefCnt = -1; |
6468 | |
6469 | mozilla::Monitor monitor MOZ_ANNOTATED(__func__); |
6470 | bool waiting = true; |
6471 | |
6472 | auto lambda = [&] { |
6473 | AssertIsOnIOThread(); |
6474 | |
6475 | { |
6476 | IndexedDatabaseManager* const mgr = IndexedDatabaseManager::Get(); |
6477 | MOZ_ASSERT(mgr)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mgr)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(mgr))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("mgr", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6477); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mgr" ")"); do { *((volatile int*)__null) = 6477; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); |
6478 | |
6479 | const SafeRefPtr<DatabaseFileManager> fileManager = |
6480 | mgr->GetFileManager(aPersistenceType, aOrigin, aDatabaseName); |
6481 | |
6482 | if (fileManager) { |
6483 | const SafeRefPtr<DatabaseFileInfo> fileInfo = |
6484 | fileManager->GetFileInfo(aFileId); |
6485 | |
6486 | if (fileInfo) { |
6487 | fileInfo->GetReferences(aMemRefCnt, aDBRefCnt); |
6488 | |
6489 | if (*aMemRefCnt != -1) { |
6490 | // We added an extra temp ref, so account for that accordingly. |
6491 | (*aMemRefCnt)--; |
6492 | } |
6493 | |
6494 | *aResult = true; |
6495 | } |
6496 | } |
6497 | } |
6498 | |
6499 | mozilla::MonitorAutoLock lock(monitor); |
6500 | MOZ_ASSERT(waiting)do { static_assert( mozilla::detail::AssertionConditionType< decltype(waiting)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(waiting))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("waiting", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6500); AnnotateMozCrashReason("MOZ_ASSERT" "(" "waiting" ")" ); do { *((volatile int*)__null) = 6500; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6501 | |
6502 | waiting = false; |
6503 | lock.Notify(); |
6504 | }; |
6505 | |
6506 | QuotaManager* const quotaManager = QuotaManager::Get(); |
6507 | MOZ_ASSERT(quotaManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(quotaManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(quotaManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("quotaManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6507); AnnotateMozCrashReason("MOZ_ASSERT" "(" "quotaManager" ")"); do { *((volatile int*)__null) = 6507; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6508 | |
6509 | // XXX can't we simply use NS_DispatchAndSpinEventLoopUntilComplete instead of |
6510 | // using a monitor? |
6511 | QM_TRY(MOZ_TO_RESULT(quotaManager->IOThread()->Dispatch({auto tryResult886 = (ToResult(quotaManager->IOThread()-> Dispatch( NS_NewRunnableFunction("GetFileReferences", std::move (lambda)), nsIEventTarget::DISPATCH_NORMAL))); static_assert( std::is_empty_v<typename decltype(tryResult886)::ok_type> ); if ((__builtin_expect(!!(tryResult886.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch( NS_NewRunnableFunction(\"GetFileReferences\", std::move(lambda)), nsIEventTarget::DISPATCH_NORMAL))" , tryResult886.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6513, mozilla::dom::quota::Severity::Error); return tryResult886 .propagateErr(); }} |
6512 | NS_NewRunnableFunction("GetFileReferences", std::move(lambda)),{auto tryResult886 = (ToResult(quotaManager->IOThread()-> Dispatch( NS_NewRunnableFunction("GetFileReferences", std::move (lambda)), nsIEventTarget::DISPATCH_NORMAL))); static_assert( std::is_empty_v<typename decltype(tryResult886)::ok_type> ); if ((__builtin_expect(!!(tryResult886.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch( NS_NewRunnableFunction(\"GetFileReferences\", std::move(lambda)), nsIEventTarget::DISPATCH_NORMAL))" , tryResult886.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6513, mozilla::dom::quota::Severity::Error); return tryResult886 .propagateErr(); }} |
6513 | NS_DISPATCH_NORMAL))){auto tryResult886 = (ToResult(quotaManager->IOThread()-> Dispatch( NS_NewRunnableFunction("GetFileReferences", std::move (lambda)), nsIEventTarget::DISPATCH_NORMAL))); static_assert( std::is_empty_v<typename decltype(tryResult886)::ok_type> ); if ((__builtin_expect(!!(tryResult886.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch( NS_NewRunnableFunction(\"GetFileReferences\", std::move(lambda)), nsIEventTarget::DISPATCH_NORMAL))" , tryResult886.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6513, mozilla::dom::quota::Severity::Error); return tryResult886 .propagateErr(); }}; |
6514 | |
6515 | mozilla::MonitorAutoLock autolock(monitor); |
6516 | while (waiting) { |
6517 | autolock.Wait(); |
6518 | } |
6519 | |
6520 | return NS_OK; |
6521 | } |
6522 | |
6523 | class DeserializeIndexValueHelper final : public Runnable { |
6524 | public: |
6525 | DeserializeIndexValueHelper(int64_t aIndexID, const KeyPath& aKeyPath, |
6526 | bool aMultiEntry, const nsACString& aLocale, |
6527 | StructuredCloneReadInfoParent& aCloneReadInfo, |
6528 | nsTArray<IndexUpdateInfo>& aUpdateInfoArray) |
6529 | : Runnable("DeserializeIndexValueHelper"), |
6530 | mMonitor("DeserializeIndexValueHelper::mMonitor"), |
6531 | mIndexID(aIndexID), |
6532 | mKeyPath(aKeyPath), |
6533 | mMultiEntry(aMultiEntry), |
6534 | mLocale(aLocale), |
6535 | mCloneReadInfo(aCloneReadInfo), |
6536 | mUpdateInfoArray(aUpdateInfoArray), |
6537 | mStatus(NS_ERROR_FAILURE) {} |
6538 | |
6539 | nsresult DispatchAndWait() { |
6540 | // FIXME(Bug 1637530) Re-enable optimization using a non-system-principaled |
6541 | // JS context |
6542 | #if 0 |
6543 | // We don't need to go to the main-thread and use the sandbox. Let's create |
6544 | // the updateInfo data here. |
6545 | if (!mCloneReadInfo.Data().Size()) { |
6546 | AutoJSAPI jsapi; |
6547 | jsapi.Init(); |
6548 | |
6549 | JS::Rooted<JS::Value> value(jsapi.cx()); |
6550 | value.setUndefined(); |
6551 | |
6552 | ErrorResult rv; |
6553 | IDBObjectStore::AppendIndexUpdateInfo( |
6554 | mIndexID, mKeyPath, mMultiEntry, &mUpdateInfoArray, |
6555 | /* aAutoIncrementedObjectStoreKeyPath */ VoidString(), &rv); |
6556 | return rv.Failed() ? rv.StealNSResult() : NS_OK; |
6557 | } |
6558 | #endif |
6559 | |
6560 | // The operation will continue on the main-thread. |
6561 | |
6562 | MOZ_ASSERT(!(mCloneReadInfo.Data().Size() % sizeof(uint64_t)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!(mCloneReadInfo.Data().Size() % sizeof(uint64_t)))> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!(mCloneReadInfo.Data().Size() % sizeof(uint64_t)))) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!(mCloneReadInfo.Data().Size() % sizeof(uint64_t))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6562); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!(mCloneReadInfo.Data().Size() % sizeof(uint64_t))" ")"); do { *((volatile int*)__null) = 6562; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6563 | |
6564 | MonitorAutoLock lock(mMonitor); |
6565 | |
6566 | RefPtr<Runnable> self = this; |
6567 | QM_TRY(MOZ_TO_RESULT(SchedulerGroup::Dispatch(self.forget()))){auto tryResult887 = (ToResult(SchedulerGroup::Dispatch(self. forget()))); static_assert(std::is_empty_v<typename decltype (tryResult887)::ok_type>); if ((__builtin_expect(!!(tryResult887 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(SchedulerGroup::Dispatch(self.forget()))" , tryResult887.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6567, mozilla::dom::quota::Severity::Error); return tryResult887 .propagateErr(); }}; |
6568 | |
6569 | lock.Wait(); |
6570 | return mStatus; |
6571 | } |
6572 | |
6573 | NS_IMETHODvirtual nsresult |
6574 | Run() override { |
6575 | MOZ_ASSERT(NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6575); AnnotateMozCrashReason("MOZ_ASSERT" "(" "NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 6575; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6576 | |
6577 | AutoJSAPI jsapi; |
6578 | jsapi.Init(); |
6579 | JSContext* const cx = jsapi.cx(); |
6580 | |
6581 | JS::Rooted<JSObject*> global(cx, GetSandbox(cx)); |
6582 | |
6583 | QM_TRY(OkIf(global), NS_OK,{auto tryResult888 = (OkIf(global)); static_assert(std::is_empty_v <typename decltype(tryResult888)::ok_type>); if ((__builtin_expect (!!(tryResult888.isErr()), 0))) { auto tryTempError = tryResult888 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(global)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6584, mozilla::dom::quota::Severity::Error); [this](const NotOk ) { OperationCompleted(NS_ERROR_FAILURE); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(global)" , tryTempError, NS_OK); }} |
6584 | [this](const NotOk) { OperationCompleted(NS_ERROR_FAILURE); }){auto tryResult888 = (OkIf(global)); static_assert(std::is_empty_v <typename decltype(tryResult888)::ok_type>); if ((__builtin_expect (!!(tryResult888.isErr()), 0))) { auto tryTempError = tryResult888 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(global)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6584, mozilla::dom::quota::Severity::Error); [this](const NotOk ) { OperationCompleted(NS_ERROR_FAILURE); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(global)" , tryTempError, NS_OK); }}; |
6585 | |
6586 | const JSAutoRealm ar(cx, global); |
6587 | |
6588 | JS::Rooted<JS::Value> value(cx); |
6589 | QM_TRY(MOZ_TO_RESULT(DeserializeIndexValue(cx, &value)), NS_OK,{auto tryResult889 = (ToResult(DeserializeIndexValue(cx, & value))); static_assert(std::is_empty_v<typename decltype( tryResult889)::ok_type>); if ((__builtin_expect(!!(tryResult889 .isErr()), 0))) { auto tryTempError = tryResult889.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(DeserializeIndexValue(cx, &value))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6590, mozilla::dom::quota::Severity::Error); [this](const nsresult rv) { OperationCompleted(rv); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(DeserializeIndexValue(cx, &value))" , tryTempError, NS_OK); }} |
6590 | [this](const nsresult rv) { OperationCompleted(rv); }){auto tryResult889 = (ToResult(DeserializeIndexValue(cx, & value))); static_assert(std::is_empty_v<typename decltype( tryResult889)::ok_type>); if ((__builtin_expect(!!(tryResult889 .isErr()), 0))) { auto tryTempError = tryResult889.unwrapErr( ); mozilla::dom::quota::HandleError("ToResult(DeserializeIndexValue(cx, &value))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6590, mozilla::dom::quota::Severity::Error); [this](const nsresult rv) { OperationCompleted(rv); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(DeserializeIndexValue(cx, &value))" , tryTempError, NS_OK); }}; |
6591 | |
6592 | ErrorResult errorResult; |
6593 | IDBObjectStore::AppendIndexUpdateInfo( |
6594 | mIndexID, mKeyPath, mMultiEntry, mLocale, cx, value, &mUpdateInfoArray, |
6595 | /* aAutoIncrementedObjectStoreKeyPath */ VoidString(), &errorResult); |
6596 | QM_TRY(OkIf(!errorResult.Failed()), NS_OK,{auto tryResult890 = (OkIf(!errorResult.Failed())); static_assert (std::is_empty_v<typename decltype(tryResult890)::ok_type> ); if ((__builtin_expect(!!(tryResult890.isErr()), 0))) { auto tryTempError = tryResult890.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(!errorResult.Failed())", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6599, mozilla::dom::quota::Severity::Error); ([this, &errorResult ](const NotOk) { OperationCompleted(errorResult.StealNSResult ()); })(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "OkIf(!errorResult.Failed())", tryTempError, NS_OK); } } |
6597 | ([this, &errorResult](const NotOk) {{auto tryResult890 = (OkIf(!errorResult.Failed())); static_assert (std::is_empty_v<typename decltype(tryResult890)::ok_type> ); if ((__builtin_expect(!!(tryResult890.isErr()), 0))) { auto tryTempError = tryResult890.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(!errorResult.Failed())", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6599, mozilla::dom::quota::Severity::Error); ([this, &errorResult ](const NotOk) { OperationCompleted(errorResult.StealNSResult ()); })(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "OkIf(!errorResult.Failed())", tryTempError, NS_OK); } } |
6598 | OperationCompleted(errorResult.StealNSResult());{auto tryResult890 = (OkIf(!errorResult.Failed())); static_assert (std::is_empty_v<typename decltype(tryResult890)::ok_type> ); if ((__builtin_expect(!!(tryResult890.isErr()), 0))) { auto tryTempError = tryResult890.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(!errorResult.Failed())", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6599, mozilla::dom::quota::Severity::Error); ([this, &errorResult ](const NotOk) { OperationCompleted(errorResult.StealNSResult ()); })(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "OkIf(!errorResult.Failed())", tryTempError, NS_OK); } } |
6599 | })){auto tryResult890 = (OkIf(!errorResult.Failed())); static_assert (std::is_empty_v<typename decltype(tryResult890)::ok_type> ); if ((__builtin_expect(!!(tryResult890.isErr()), 0))) { auto tryTempError = tryResult890.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(!errorResult.Failed())", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6599, mozilla::dom::quota::Severity::Error); ([this, &errorResult ](const NotOk) { OperationCompleted(errorResult.StealNSResult ()); })(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "OkIf(!errorResult.Failed())", tryTempError, NS_OK); } }; |
6600 | |
6601 | OperationCompleted(NS_OK); |
6602 | return NS_OK; |
6603 | } |
6604 | |
6605 | private: |
6606 | nsresult DeserializeIndexValue(JSContext* aCx, |
6607 | JS::MutableHandle<JS::Value> aValue) { |
6608 | static const JSStructuredCloneCallbacks callbacks = { |
6609 | StructuredCloneReadCallback<StructuredCloneReadInfoParent>, |
6610 | nullptr, |
6611 | nullptr, |
6612 | nullptr, |
6613 | nullptr, |
6614 | nullptr, |
6615 | nullptr, |
6616 | nullptr}; |
6617 | |
6618 | if (!JS_ReadStructuredClone( |
6619 | aCx, mCloneReadInfo.Data(), JS_STRUCTURED_CLONE_VERSION8, |
6620 | JS::StructuredCloneScope::DifferentProcessForIndexedDB, aValue, |
6621 | JS::CloneDataPolicy(), &callbacks, &mCloneReadInfo)) { |
6622 | return NS_ERROR_DOM_DATA_CLONE_ERR; |
6623 | } |
6624 | |
6625 | return NS_OK; |
6626 | } |
6627 | |
6628 | void OperationCompleted(nsresult aStatus) { |
6629 | mStatus = aStatus; |
6630 | |
6631 | MonitorAutoLock lock(mMonitor); |
6632 | lock.Notify(); |
6633 | } |
6634 | |
6635 | Monitor mMonitor MOZ_UNANNOTATED; |
6636 | |
6637 | const int64_t mIndexID; |
6638 | const KeyPath& mKeyPath; |
6639 | const bool mMultiEntry; |
6640 | const nsCString mLocale; |
6641 | StructuredCloneReadInfoParent& mCloneReadInfo; |
6642 | nsTArray<IndexUpdateInfo>& mUpdateInfoArray; |
6643 | nsresult mStatus; |
6644 | }; |
6645 | |
6646 | auto DeserializeIndexValueToUpdateInfos( |
6647 | int64_t aIndexID, const KeyPath& aKeyPath, bool aMultiEntry, |
6648 | const nsACString& aLocale, StructuredCloneReadInfoParent& aCloneReadInfo) { |
6649 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6649); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 6649; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6650 | |
6651 | using ArrayType = AutoTArray<IndexUpdateInfo, 32>; |
6652 | using ResultType = Result<ArrayType, nsresult>; |
6653 | |
6654 | ArrayType updateInfoArray; |
6655 | const auto helper = MakeRefPtr<DeserializeIndexValueHelper>( |
6656 | aIndexID, aKeyPath, aMultiEntry, aLocale, aCloneReadInfo, |
6657 | updateInfoArray); |
6658 | const nsresult rv = helper->DispatchAndWait(); |
6659 | return NS_FAILED(rv)((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0))) ? Err(rv) : ResultType{std::move(updateInfoArray)}; |
6660 | } |
6661 | |
6662 | bool IsSome( |
6663 | const Maybe<CachingDatabaseConnection::BorrowedStatement>& aMaybeStmt) { |
6664 | return aMaybeStmt.isSome(); |
6665 | } |
6666 | |
6667 | already_AddRefed<nsIThreadPool> MakeConnectionIOTarget() { |
6668 | nsCOMPtr<nsIThreadPool> threadPool = new nsThreadPool(); |
6669 | |
6670 | MOZ_ALWAYS_SUCCEEDS(threadPool->SetThreadLimit(kMaxConnectionThreadCount))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetThreadLimit(kMaxConnectionThreadCount))), 1 )))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetThreadLimit(kMaxConnectionThreadCount))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6670); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetThreadLimit(kMaxConnectionThreadCount))" ")"); do { *((volatile int*)__null) = 6670; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6671 | |
6672 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6673); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount))" ")"); do { *((volatile int*)__null) = 6673; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
6673 | threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6673); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadLimit(kMaxIdleConnectionThreadCount))" ")"); do { *((volatile int*)__null) = 6673; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6674 | |
6675 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6676); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS))" ")"); do { *((volatile int*)__null) = 6676; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
6676 | threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6676); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(kConnectionThreadMaxIdleMS))" ")"); do { *((volatile int*)__null) = 6676; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6677 | |
6678 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6679); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS))" ")"); do { *((volatile int*)__null) = 6679; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
6679 | threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6679); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadGraceTimeout(kConnectionThreadGraceIdleMS))" ")"); do { *((volatile int*)__null) = 6679; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6680 | |
6681 | MOZ_ALWAYS_SUCCEEDS(threadPool->SetName("IndexedDB IO"_ns))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetName("IndexedDB IO"_ns))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(threadPool->SetName(\"IndexedDB IO\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6681); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetName(\"IndexedDB IO\"_ns))" ")"); do { *((volatile int*)__null) = 6681; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
6682 | |
6683 | return threadPool.forget(); |
6684 | } |
6685 | |
6686 | } // namespace |
6687 | |
6688 | /******************************************************************************* |
6689 | * Exported functions |
6690 | ******************************************************************************/ |
6691 | |
6692 | already_AddRefed<PBackgroundIDBFactoryParent> AllocPBackgroundIDBFactoryParent( |
6693 | const LoggingInfo& aLoggingInfo, const nsACString& aSystemLocale) { |
6694 | AssertIsOnBackgroundThread(); |
6695 | |
6696 | if (NS_WARN_IF(QuotaClient::IsShuttingDownOnBackgroundThread())NS_warn_if_impl(QuotaClient::IsShuttingDownOnBackgroundThread (), "QuotaClient::IsShuttingDownOnBackgroundThread()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6696)) { |
6697 | return nullptr; |
6698 | } |
6699 | |
6700 | if (NS_AUUF_OR_WARN_IF(!aLoggingInfo.nextTransactionSerialNumber())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aLoggingInfo.nextTransactionSerialNumber()" ")" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6700); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aLoggingInfo.nextTransactionSerialNumber()" ")"); do { *(( volatile int*)__null) = 6700; __attribute__((nomerge)) ::abort (); } while (false); } } while (false); } return aCond; }((!aLoggingInfo .nextTransactionSerialNumber())) || |
6701 | NS_AUUF_OR_WARN_IF([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aLoggingInfo.nextVersionChangeTransactionSerialNumber()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6702); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aLoggingInfo.nextVersionChangeTransactionSerialNumber()" ")" ); do { *((volatile int*)__null) = 6702; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((!aLoggingInfo.nextVersionChangeTransactionSerialNumber() )) |
6702 | !aLoggingInfo.nextVersionChangeTransactionSerialNumber())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aLoggingInfo.nextVersionChangeTransactionSerialNumber()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6702); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aLoggingInfo.nextVersionChangeTransactionSerialNumber()" ")" ); do { *((volatile int*)__null) = 6702; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((!aLoggingInfo.nextVersionChangeTransactionSerialNumber() )) || |
6703 | NS_AUUF_OR_WARN_IF(!aLoggingInfo.nextRequestSerialNumber())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aLoggingInfo.nextRequestSerialNumber()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6703); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aLoggingInfo.nextRequestSerialNumber()" ")"); do { *((volatile int*)__null) = 6703; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!aLoggingInfo .nextRequestSerialNumber()))) { |
6704 | return nullptr; |
6705 | } |
6706 | |
6707 | SafeRefPtr<Factory> actor = Factory::Create(aLoggingInfo, aSystemLocale); |
6708 | MOZ_ASSERT(actor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(actor)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(actor))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("actor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6708); AnnotateMozCrashReason("MOZ_ASSERT" "(" "actor" ")") ; do { *((volatile int*)__null) = 6708; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6709 | |
6710 | return actor.forget(); |
6711 | } |
6712 | |
6713 | bool RecvPBackgroundIDBFactoryConstructor( |
6714 | PBackgroundIDBFactoryParent* aActor, const LoggingInfo& /* aLoggingInfo */, |
6715 | const nsACString& /* aSystemLocale */) { |
6716 | AssertIsOnBackgroundThread(); |
6717 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6717); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 6717; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6718 | MOZ_ASSERT(!QuotaClient::IsShuttingDownOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!QuotaClient::IsShuttingDownOnBackgroundThread())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!QuotaClient::IsShuttingDownOnBackgroundThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!QuotaClient::IsShuttingDownOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6718); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!QuotaClient::IsShuttingDownOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 6718; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6719 | |
6720 | return true; |
6721 | } |
6722 | |
6723 | PBackgroundIndexedDBUtilsParent* AllocPBackgroundIndexedDBUtilsParent() { |
6724 | AssertIsOnBackgroundThread(); |
6725 | |
6726 | RefPtr<Utils> actor = new Utils(); |
6727 | |
6728 | return actor.forget().take(); |
6729 | } |
6730 | |
6731 | bool DeallocPBackgroundIndexedDBUtilsParent( |
6732 | PBackgroundIndexedDBUtilsParent* aActor) { |
6733 | AssertIsOnBackgroundThread(); |
6734 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6734); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 6734; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6735 | |
6736 | RefPtr<Utils> actor = dont_AddRef(static_cast<Utils*>(aActor)); |
6737 | return true; |
6738 | } |
6739 | |
6740 | bool RecvFlushPendingFileDeletions() { |
6741 | AssertIsOnBackgroundThread(); |
6742 | |
6743 | if (QuotaClient* quotaClient = QuotaClient::GetInstance()) { |
6744 | QM_WARNONLY_TRY(QM_TO_RESULT(quotaClient->FlushPendingFileDeletions())){auto tryResult891 = (ToResult<QMResult>(quotaClient-> FlushPendingFileDeletions())); static_assert(std::is_empty_v< typename decltype(tryResult891)::ok_type>); if ((__builtin_expect (!!(tryResult891.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult<QMResult>(quotaClient->FlushPendingFileDeletions())" , tryResult891.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6744, mozilla::dom::quota::Severity::Warning); }}; |
6745 | } |
6746 | |
6747 | return true; |
6748 | } |
6749 | |
6750 | RefPtr<mozilla::dom::quota::Client> CreateQuotaClient() { |
6751 | AssertIsOnBackgroundThread(); |
6752 | |
6753 | return MakeRefPtr<QuotaClient>(); |
6754 | } |
6755 | |
6756 | nsresult DatabaseFileManager::AsyncDeleteFile(int64_t aFileId) { |
6757 | AssertIsOnBackgroundThread(); |
6758 | MOZ_ASSERT(!ContainsFileInfo(aFileId))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!ContainsFileInfo(aFileId))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!ContainsFileInfo(aFileId))) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!ContainsFileInfo(aFileId)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6758); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!ContainsFileInfo(aFileId)" ")"); do { *((volatile int*)__null) = 6758; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6759 | |
6760 | QuotaClient* quotaClient = QuotaClient::GetInstance(); |
6761 | if (quotaClient) { |
6762 | QM_TRY(MOZ_TO_RESULT(quotaClient->AsyncDeleteFile(this, aFileId))){auto tryResult892 = (ToResult(quotaClient->AsyncDeleteFile (this, aFileId))); static_assert(std::is_empty_v<typename decltype (tryResult892)::ok_type>); if ((__builtin_expect(!!(tryResult892 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(quotaClient->AsyncDeleteFile(this, aFileId))" , tryResult892.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6762, mozilla::dom::quota::Severity::Error); return tryResult892 .propagateErr(); }}; |
6763 | } |
6764 | |
6765 | return NS_OK; |
6766 | } |
6767 | |
6768 | /******************************************************************************* |
6769 | * DatabaseConnection implementation |
6770 | ******************************************************************************/ |
6771 | |
6772 | DatabaseConnection::DatabaseConnection( |
6773 | MovingNotNull<nsCOMPtr<mozIStorageConnection>> aStorageConnection, |
6774 | MovingNotNull<SafeRefPtr<DatabaseFileManager>> aFileManager) |
6775 | : CachingDatabaseConnection(std::move(aStorageConnection)), |
6776 | mFileManager(std::move(aFileManager)), |
6777 | mLastDurability(IDBTransaction::Durability::Default), |
6778 | mInReadTransaction(false), |
6779 | mInWriteTransaction(false) |
6780 | #ifdef DEBUG1 |
6781 | , |
6782 | mDEBUGSavepointCount(0) |
6783 | #endif |
6784 | { |
6785 | AssertIsOnConnectionThread(); |
6786 | MOZ_ASSERT(mFileManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6786); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileManager" ")"); do { *((volatile int*)__null) = 6786; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6787 | } |
6788 | |
6789 | DatabaseConnection::~DatabaseConnection() { |
6790 | MOZ_ASSERT(!mFileManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mFileManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mFileManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mFileManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6790); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mFileManager" ")"); do { *((volatile int*)__null) = 6790; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6791 | MOZ_ASSERT(!mUpdateRefcountFunction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mUpdateRefcountFunction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mUpdateRefcountFunction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mUpdateRefcountFunction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6791); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mUpdateRefcountFunction" ")"); do { *((volatile int*)__null) = 6791; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6792 | MOZ_DIAGNOSTIC_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6792); AnnotateMozCrashReason("MOZ_DIAGNOSTIC_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6792; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6793 | MOZ_ASSERT(!mDEBUGSavepointCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDEBUGSavepointCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDEBUGSavepointCount))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("!mDEBUGSavepointCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6793); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDEBUGSavepointCount" ")"); do { *((volatile int*)__null) = 6793; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6794 | } |
6795 | |
6796 | nsresult DatabaseConnection::Init() { |
6797 | AssertIsOnConnectionThread(); |
6798 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6798); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 6798; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6799 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6799); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6799; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6800 | |
6801 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement("BEGIN;"_ns))){auto tryResult893 = (ToResult(ExecuteCachedStatement("BEGIN;"_ns ))); static_assert(std::is_empty_v<typename decltype(tryResult893 )::ok_type>); if ((__builtin_expect(!!(tryResult893.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"BEGIN;\"_ns))" , tryResult893.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6801, mozilla::dom::quota::Severity::Error); return tryResult893 .propagateErr(); }}; |
6802 | |
6803 | mInReadTransaction = true; |
6804 | |
6805 | return NS_OK; |
6806 | } |
6807 | |
6808 | nsresult DatabaseConnection::BeginWriteTransaction( |
6809 | const IDBTransaction::Durability aDurability) { |
6810 | AssertIsOnConnectionThread(); |
6811 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6811); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 6811; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6812 | MOZ_ASSERT(mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6812); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInReadTransaction" ")"); do { *((volatile int*)__null) = 6812; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6813 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6813); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6813; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6814 | |
6815 | AUTO_PROFILER_LABEL("DatabaseConnection::BeginWriteTransaction", DOM)mozilla::AutoProfilerLabel raiiObject6815( "DatabaseConnection::BeginWriteTransaction" , nullptr, JS::ProfilingCategoryPair::DOM); |
6816 | |
6817 | // Release our read locks. |
6818 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement("ROLLBACK;"_ns))){auto tryResult894 = (ToResult(ExecuteCachedStatement("ROLLBACK;"_ns ))); static_assert(std::is_empty_v<typename decltype(tryResult894 )::ok_type>); if ((__builtin_expect(!!(tryResult894.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"ROLLBACK;\"_ns))" , tryResult894.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6818, mozilla::dom::quota::Severity::Error); return tryResult894 .propagateErr(); }}; |
6819 | |
6820 | mInReadTransaction = false; |
6821 | |
6822 | if (mLastDurability != aDurability) { |
6823 | auto synchronousMode = [aDurability]() -> nsLiteralCString { |
6824 | switch (aDurability) { |
6825 | case IDBTransaction::Durability::Default: |
6826 | return GetDefaultSynchronousMode(); |
6827 | |
6828 | case IDBTransaction::Durability::Strict: |
6829 | return "EXTRA"_ns; |
6830 | |
6831 | case IDBTransaction::Durability::Relaxed: |
6832 | return "OFF"_ns; |
6833 | |
6834 | default: |
6835 | MOZ_CRASH("Unknown CheckpointMode!")do { do { } while (false); MOZ_ReportCrash("" "Unknown CheckpointMode!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6835); AnnotateMozCrashReason("MOZ_CRASH(" "Unknown CheckpointMode!" ")"); do { *((volatile int*)__null) = 6835; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
6836 | } |
6837 | }(); |
6838 | |
6839 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement("PRAGMA synchronous = "_ns +{auto tryResult895 = (ToResult(ExecuteCachedStatement("PRAGMA synchronous = "_ns + synchronousMode + ";"_ns))); static_assert(std::is_empty_v <typename decltype(tryResult895)::ok_type>); if ((__builtin_expect (!!(tryResult895.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(ExecuteCachedStatement(\"PRAGMA synchronous = \"_ns + synchronousMode + \";\"_ns))" , tryResult895.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6840, mozilla::dom::quota::Severity::Error); return tryResult895 .propagateErr(); }} |
6840 | synchronousMode + ";"_ns))){auto tryResult895 = (ToResult(ExecuteCachedStatement("PRAGMA synchronous = "_ns + synchronousMode + ";"_ns))); static_assert(std::is_empty_v <typename decltype(tryResult895)::ok_type>); if ((__builtin_expect (!!(tryResult895.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(ExecuteCachedStatement(\"PRAGMA synchronous = \"_ns + synchronousMode + \";\"_ns))" , tryResult895.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6840, mozilla::dom::quota::Severity::Error); return tryResult895 .propagateErr(); }}; |
6841 | |
6842 | mLastDurability = aDurability; |
6843 | } |
6844 | |
6845 | if (!mUpdateRefcountFunction) { |
6846 | MOZ_ASSERT(mFileManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6846); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileManager" ")"); do { *((volatile int*)__null) = 6846; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6847 | |
6848 | RefPtr<UpdateRefcountFunction> function = |
6849 | new UpdateRefcountFunction(this, **mFileManager); |
6850 | |
6851 | QM_TRY(MOZ_TO_RESULT(MutableStorageConnection().CreateFunction({auto tryResult896 = (ToResult(MutableStorageConnection().CreateFunction ( "update_refcount"_ns, 2, function))); static_assert(std::is_empty_v <typename decltype(tryResult896)::ok_type>); if ((__builtin_expect (!!(tryResult896.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(MutableStorageConnection().CreateFunction( \"update_refcount\"_ns, 2, function))" , tryResult896.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6853, mozilla::dom::quota::Severity::Error); return tryResult896 .propagateErr(); }} |
6852 | "update_refcount"_ns,{auto tryResult896 = (ToResult(MutableStorageConnection().CreateFunction ( "update_refcount"_ns, 2, function))); static_assert(std::is_empty_v <typename decltype(tryResult896)::ok_type>); if ((__builtin_expect (!!(tryResult896.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(MutableStorageConnection().CreateFunction( \"update_refcount\"_ns, 2, function))" , tryResult896.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6853, mozilla::dom::quota::Severity::Error); return tryResult896 .propagateErr(); }} |
6853 | /* aNumArguments */ 2, function))){auto tryResult896 = (ToResult(MutableStorageConnection().CreateFunction ( "update_refcount"_ns, 2, function))); static_assert(std::is_empty_v <typename decltype(tryResult896)::ok_type>); if ((__builtin_expect (!!(tryResult896.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(MutableStorageConnection().CreateFunction( \"update_refcount\"_ns, 2, function))" , tryResult896.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6853, mozilla::dom::quota::Severity::Error); return tryResult896 .propagateErr(); }}; |
6854 | |
6855 | mUpdateRefcountFunction = std::move(function); |
6856 | } |
6857 | |
6858 | // This one cannot obviously use ExecuteCachedStatement because of the custom |
6859 | // error handling for Execute only. If only Execute can produce |
6860 | // NS_ERROR_STORAGE_BUSY, we could actually use ExecuteCachedStatement and |
6861 | // simplify this. |
6862 | QM_TRY_INSPECT(const auto& beginStmt,auto tryResult897 = (BorrowCachedStatement("BEGIN IMMEDIATE;"_ns )); if ((__builtin_expect(!!(tryResult897.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"BEGIN IMMEDIATE;\"_ns)" , tryResult897.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6863, mozilla::dom::quota::Severity::Error); return tryResult897 .propagateErr(); } const auto& beginStmt = tryResult897.inspect (); |
6863 | BorrowCachedStatement("BEGIN IMMEDIATE;"_ns))auto tryResult897 = (BorrowCachedStatement("BEGIN IMMEDIATE;"_ns )); if ((__builtin_expect(!!(tryResult897.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"BEGIN IMMEDIATE;\"_ns)" , tryResult897.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6863, mozilla::dom::quota::Severity::Error); return tryResult897 .propagateErr(); } const auto& beginStmt = tryResult897.inspect ();; |
6864 | |
6865 | QM_TRY(QM_OR_ELSE_WARN_IF({auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6866 | // Expression.{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6867 | MOZ_TO_RESULT(beginStmt->Execute()),{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6868 | // Predicate.{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6869 | IsSpecificError<NS_ERROR_STORAGE_BUSY>,{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6870 | // Fallback.{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6871 | ([&beginStmt](nsresult rv) {{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6872 | NS_WARNING({auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6873 | "Received NS_ERROR_STORAGE_BUSY when attempting to start write "{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6874 | "transaction, retrying for up to 10 seconds");{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6875 | |
6876 | // Another thread must be using the database. Wait up to 10 seconds{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6877 | // for that to complete.{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6878 | const TimeStamp start = TimeStamp::NowLoRes();{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6879 | |
6880 | while (true) {{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6881 | PR_Sleep(PR_MillisecondsToInterval(100));{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6882 | |
6883 | rv = beginStmt->Execute();{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6884 | if (rv != NS_ERROR_STORAGE_BUSY ||{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6885 | TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) {{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6886 | break;{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6887 | }{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6888 | }{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6889 | |
6890 | return MOZ_TO_RESULT(rv);{auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }} |
6891 | }))){auto tryResult898 = (mozilla::dom::quota::OrElseIf( (ToResult (beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes ); mozilla::dom::quota::HandleError("\"ToResult(beginStmt->Execute())\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ([&beginStmt ](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, "Received NS_ERROR_STORAGE_BUSY when attempting to start write " "transaction, retrying for up to 10 seconds", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt ->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp:: NowLoRes() - start > TimeDuration::FromSeconds(10)) { break ; } } return ToResult(rv); }))); static_assert(std::is_empty_v <typename decltype(tryResult898)::ok_type>); if ((__builtin_expect (!!(tryResult898.isErr()), 0))) { mozilla::dom::quota::HandleError ("mozilla::dom::quota::OrElseIf( (ToResult(beginStmt->Execute())), [&](const auto& firstRes) { bool res = IsSpecificError<NS_ERROR_STORAGE_BUSY>(firstRes); mozilla::dom::quota::HandleError(\"\\\"ToResult(beginStmt->Execute())\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6891, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ([&beginStmt](nsresult rv) { NS_DebugBreak(NS_DEBUG_WARNING, \"Received NS_ERROR_STORAGE_BUSY when attempting to start write \" \"transaction, retrying for up to 10 seconds\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 6874); const TimeStamp start = TimeStamp::NowLoRes(); while (true) { PR_Sleep(PR_MillisecondsToInterval(100)); rv = beginStmt->Execute(); if (rv != NS_ERROR_STORAGE_BUSY || TimeStamp::NowLoRes() - start > TimeDuration::FromSeconds(10)) { break; } } return ToResult(rv); }))" , tryResult898.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6891, mozilla::dom::quota::Severity::Error); return tryResult898 .propagateErr(); }}; |
6892 | |
6893 | mInWriteTransaction = true; |
6894 | |
6895 | return NS_OK; |
6896 | } |
6897 | |
6898 | nsresult DatabaseConnection::CommitWriteTransaction() { |
6899 | AssertIsOnConnectionThread(); |
6900 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6900); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 6900; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6901 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6901); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 6901; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6902 | MOZ_ASSERT(mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInWriteTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6902); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6902; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6903 | |
6904 | AUTO_PROFILER_LABEL("DatabaseConnection::CommitWriteTransaction", DOM)mozilla::AutoProfilerLabel raiiObject6904( "DatabaseConnection::CommitWriteTransaction" , nullptr, JS::ProfilingCategoryPair::DOM); |
6905 | |
6906 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement("COMMIT;"_ns))){auto tryResult899 = (ToResult(ExecuteCachedStatement("COMMIT;"_ns ))); static_assert(std::is_empty_v<typename decltype(tryResult899 )::ok_type>); if ((__builtin_expect(!!(tryResult899.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"COMMIT;\"_ns))" , tryResult899.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6906, mozilla::dom::quota::Severity::Error); return tryResult899 .propagateErr(); }}; |
6907 | |
6908 | mInWriteTransaction = false; |
6909 | return NS_OK; |
6910 | } |
6911 | |
6912 | void DatabaseConnection::RollbackWriteTransaction() { |
6913 | AssertIsOnConnectionThread(); |
6914 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6914); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 6914; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6915 | MOZ_DIAGNOSTIC_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6915); AnnotateMozCrashReason("MOZ_DIAGNOSTIC_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 6915; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6916 | |
6917 | AUTO_PROFILER_LABEL("DatabaseConnection::RollbackWriteTransaction", DOM)mozilla::AutoProfilerLabel raiiObject6917( "DatabaseConnection::RollbackWriteTransaction" , nullptr, JS::ProfilingCategoryPair::DOM); |
6918 | |
6919 | if (!mInWriteTransaction) { |
6920 | return; |
6921 | } |
6922 | |
6923 | QM_WARNONLY_TRY({auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6924 | BorrowCachedStatement("ROLLBACK;"_ns){auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6925 | .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> {{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6926 | // This may fail if SQLite already rolled back the transaction{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6927 | // so ignore any errors.{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6928 | |
6929 | // XXX ROLLBACK can fail quite normmally if a previous statement{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6930 | // failed to execute successfully so SQLite rolled back the{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6931 | // transaction already. However, if it failed because of some other{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6932 | // reason, we could try to close the connection.{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6933 | Unused << stmt->Execute();{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6934 | |
6935 | self.mInWriteTransaction = false;{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6936 | return Ok{};{auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }} |
6937 | })){auto tryResult900 = (BorrowCachedStatement("ROLLBACK;"_ns) . andThen([&self = *this](const auto& stmt) -> Result <Ok, nsresult> { Unused << stmt->Execute(); self .mInWriteTransaction = false; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult900)::ok_type> ); if ((__builtin_expect(!!(tryResult900.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK;\"_ns) .andThen([&self = *this](const auto& stmt) -> Result<Ok, nsresult> { Unused << stmt->Execute(); self.mInWriteTransaction = false; return Ok{}; })" , tryResult900.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6937, mozilla::dom::quota::Severity::Warning); }}; |
6938 | } |
6939 | |
6940 | void DatabaseConnection::FinishWriteTransaction() { |
6941 | AssertIsOnConnectionThread(); |
6942 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6942); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 6942; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6943 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6943); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 6943; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6944 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6944); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6944; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6945 | |
6946 | AUTO_PROFILER_LABEL("DatabaseConnection::FinishWriteTransaction", DOM)mozilla::AutoProfilerLabel raiiObject6946( "DatabaseConnection::FinishWriteTransaction" , nullptr, JS::ProfilingCategoryPair::DOM); |
6947 | |
6948 | if (mUpdateRefcountFunction) { |
6949 | mUpdateRefcountFunction->Reset(); |
6950 | } |
6951 | |
6952 | QM_WARNONLY_TRY(MOZ_TO_RESULT(ExecuteCachedStatement("BEGIN;"_ns)){auto tryResult901 = (ToResult(ExecuteCachedStatement("BEGIN;"_ns )) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult901)::ok_type> ); if ((__builtin_expect(!!(tryResult901.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"BEGIN;\"_ns)) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })" , tryResult901.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6956, mozilla::dom::quota::Severity::Warning); }} |
6953 | .andThen([&](const auto) -> Result<Ok, nsresult> {{auto tryResult901 = (ToResult(ExecuteCachedStatement("BEGIN;"_ns )) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult901)::ok_type> ); if ((__builtin_expect(!!(tryResult901.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"BEGIN;\"_ns)) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })" , tryResult901.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6956, mozilla::dom::quota::Severity::Warning); }} |
6954 | mInReadTransaction = true;{auto tryResult901 = (ToResult(ExecuteCachedStatement("BEGIN;"_ns )) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult901)::ok_type> ); if ((__builtin_expect(!!(tryResult901.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"BEGIN;\"_ns)) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })" , tryResult901.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6956, mozilla::dom::quota::Severity::Warning); }} |
6955 | return Ok{};{auto tryResult901 = (ToResult(ExecuteCachedStatement("BEGIN;"_ns )) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult901)::ok_type> ); if ((__builtin_expect(!!(tryResult901.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"BEGIN;\"_ns)) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })" , tryResult901.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6956, mozilla::dom::quota::Severity::Warning); }} |
6956 | })){auto tryResult901 = (ToResult(ExecuteCachedStatement("BEGIN;"_ns )) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })); static_assert (std::is_empty_v<typename decltype(tryResult901)::ok_type> ); if ((__builtin_expect(!!(tryResult901.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"BEGIN;\"_ns)) .andThen([&](const auto) -> Result<Ok, nsresult> { mInReadTransaction = true; return Ok{}; })" , tryResult901.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6956, mozilla::dom::quota::Severity::Warning); }}; |
6957 | } |
6958 | |
6959 | nsresult DatabaseConnection::StartSavepoint() { |
6960 | AssertIsOnConnectionThread(); |
6961 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6961); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 6961; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6962 | MOZ_ASSERT(mUpdateRefcountFunction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mUpdateRefcountFunction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mUpdateRefcountFunction))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mUpdateRefcountFunction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6962); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mUpdateRefcountFunction" ")"); do { *((volatile int*)__null) = 6962; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6963 | MOZ_ASSERT(mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInWriteTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6963); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6963; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6964 | |
6965 | AUTO_PROFILER_LABEL("DatabaseConnection::StartSavepoint", DOM)mozilla::AutoProfilerLabel raiiObject6965( "DatabaseConnection::StartSavepoint" , nullptr, JS::ProfilingCategoryPair::DOM); |
6966 | |
6967 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement(SAVEPOINT_CLAUSE))){auto tryResult902 = (ToResult(ExecuteCachedStatement("SAVEPOINT sp;"_ns ))); static_assert(std::is_empty_v<typename decltype(tryResult902 )::ok_type>); if ((__builtin_expect(!!(tryResult902.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(ExecuteCachedStatement(\"SAVEPOINT sp;\"_ns))" , tryResult902.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6967, mozilla::dom::quota::Severity::Error); return tryResult902 .propagateErr(); }}; |
6968 | |
6969 | mUpdateRefcountFunction->StartSavepoint(); |
6970 | |
6971 | #ifdef DEBUG1 |
6972 | MOZ_ASSERT(mDEBUGSavepointCount < UINT32_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGSavepointCount < (4294967295U))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mDEBUGSavepointCount < (4294967295U)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGSavepointCount < (4294967295U)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6972); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGSavepointCount < (4294967295U)" ")"); do { *((volatile int*)__null) = 6972; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6973 | mDEBUGSavepointCount++; |
6974 | #endif |
6975 | |
6976 | return NS_OK; |
6977 | } |
6978 | |
6979 | nsresult DatabaseConnection::ReleaseSavepoint() { |
6980 | AssertIsOnConnectionThread(); |
6981 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6981); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 6981; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6982 | MOZ_ASSERT(mUpdateRefcountFunction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mUpdateRefcountFunction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mUpdateRefcountFunction))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mUpdateRefcountFunction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6982); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mUpdateRefcountFunction" ")"); do { *((volatile int*)__null) = 6982; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6983 | MOZ_ASSERT(mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInWriteTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6983); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInWriteTransaction" ")"); do { *((volatile int*)__null) = 6983; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6984 | |
6985 | AUTO_PROFILER_LABEL("DatabaseConnection::ReleaseSavepoint", DOM)mozilla::AutoProfilerLabel raiiObject6985( "DatabaseConnection::ReleaseSavepoint" , nullptr, JS::ProfilingCategoryPair::DOM); |
6986 | |
6987 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement("RELEASE "_ns SAVEPOINT_CLAUSE))){auto tryResult903 = (ToResult(ExecuteCachedStatement("RELEASE "_ns "SAVEPOINT sp;"_ns))); static_assert(std::is_empty_v<typename decltype(tryResult903)::ok_type>); if ((__builtin_expect( !!(tryResult903.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(ExecuteCachedStatement(\"RELEASE \"_ns \"SAVEPOINT sp;\"_ns))" , tryResult903.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6987, mozilla::dom::quota::Severity::Error); return tryResult903 .propagateErr(); }}; |
6988 | |
6989 | mUpdateRefcountFunction->ReleaseSavepoint(); |
6990 | |
6991 | #ifdef DEBUG1 |
6992 | MOZ_ASSERT(mDEBUGSavepointCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGSavepointCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGSavepointCount))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGSavepointCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 6992); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGSavepointCount" ")"); do { *((volatile int*)__null) = 6992; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
6993 | mDEBUGSavepointCount--; |
6994 | #endif |
6995 | |
6996 | return NS_OK; |
6997 | } |
6998 | |
6999 | nsresult DatabaseConnection::RollbackSavepoint() { |
7000 | AssertIsOnConnectionThread(); |
7001 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7001); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 7001; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7002 | MOZ_ASSERT(mUpdateRefcountFunction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mUpdateRefcountFunction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mUpdateRefcountFunction))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mUpdateRefcountFunction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7002); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mUpdateRefcountFunction" ")"); do { *((volatile int*)__null) = 7002; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7003 | MOZ_ASSERT(mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInWriteTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7003); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7003; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7004 | |
7005 | AUTO_PROFILER_LABEL("DatabaseConnection::RollbackSavepoint", DOM)mozilla::AutoProfilerLabel raiiObject7005( "DatabaseConnection::RollbackSavepoint" , nullptr, JS::ProfilingCategoryPair::DOM); |
7006 | |
7007 | #ifdef DEBUG1 |
7008 | MOZ_ASSERT(mDEBUGSavepointCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGSavepointCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGSavepointCount))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGSavepointCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7008); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGSavepointCount" ")"); do { *((volatile int*)__null) = 7008; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7009 | mDEBUGSavepointCount--; |
7010 | #endif |
7011 | |
7012 | mUpdateRefcountFunction->RollbackSavepoint(); |
7013 | |
7014 | QM_TRY_INSPECT(const auto& stmt,auto tryResult904 = (BorrowCachedStatement("ROLLBACK TO "_ns "SAVEPOINT sp;"_ns )); if ((__builtin_expect(!!(tryResult904.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK TO \"_ns \"SAVEPOINT sp;\"_ns)" , tryResult904.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7015, mozilla::dom::quota::Severity::Error); return tryResult904 .propagateErr(); } const auto& stmt = tryResult904.inspect (); |
7015 | BorrowCachedStatement("ROLLBACK TO "_ns SAVEPOINT_CLAUSE))auto tryResult904 = (BorrowCachedStatement("ROLLBACK TO "_ns "SAVEPOINT sp;"_ns )); if ((__builtin_expect(!!(tryResult904.isErr()), 0))) { mozilla ::dom::quota::HandleError("BorrowCachedStatement(\"ROLLBACK TO \"_ns \"SAVEPOINT sp;\"_ns)" , tryResult904.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7015, mozilla::dom::quota::Severity::Error); return tryResult904 .propagateErr(); } const auto& stmt = tryResult904.inspect ();; |
7016 | |
7017 | // This may fail if SQLite already rolled back the savepoint so ignore any |
7018 | // errors. |
7019 | Unused << stmt->Execute(); |
7020 | |
7021 | return NS_OK; |
7022 | } |
7023 | |
7024 | nsresult DatabaseConnection::CheckpointInternal(CheckpointMode aMode) { |
7025 | AssertIsOnConnectionThread(); |
7026 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7026); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 7026; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7027 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7027); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7027; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7028 | |
7029 | AUTO_PROFILER_LABEL("DatabaseConnection::CheckpointInternal", DOM)mozilla::AutoProfilerLabel raiiObject7029( "DatabaseConnection::CheckpointInternal" , nullptr, JS::ProfilingCategoryPair::DOM); |
7030 | |
7031 | nsAutoCString stmtString; |
7032 | stmtString.AssignLiteral("PRAGMA wal_checkpoint("); |
7033 | |
7034 | switch (aMode) { |
7035 | case CheckpointMode::Full: |
7036 | // Ensures that the database is completely checkpointed and flushed to |
7037 | // disk. |
7038 | stmtString.AppendLiteral("FULL"); |
7039 | break; |
7040 | |
7041 | case CheckpointMode::Restart: |
7042 | // Like Full, but also ensures that the next write will start overwriting |
7043 | // the existing WAL file rather than letting the WAL file grow. |
7044 | stmtString.AppendLiteral("RESTART"); |
7045 | break; |
7046 | |
7047 | case CheckpointMode::Truncate: |
7048 | // Like Restart but also truncates the existing WAL file. |
7049 | stmtString.AppendLiteral("TRUNCATE"); |
7050 | break; |
7051 | |
7052 | default: |
7053 | MOZ_CRASH("Unknown CheckpointMode!")do { do { } while (false); MOZ_ReportCrash("" "Unknown CheckpointMode!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7053); AnnotateMozCrashReason("MOZ_CRASH(" "Unknown CheckpointMode!" ")"); do { *((volatile int*)__null) = 7053; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
7054 | } |
7055 | |
7056 | stmtString.AppendLiteral(");"); |
7057 | |
7058 | QM_TRY(MOZ_TO_RESULT(ExecuteCachedStatement(stmtString))){auto tryResult905 = (ToResult(ExecuteCachedStatement(stmtString ))); static_assert(std::is_empty_v<typename decltype(tryResult905 )::ok_type>); if ((__builtin_expect(!!(tryResult905.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(ExecuteCachedStatement(stmtString))" , tryResult905.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7058, mozilla::dom::quota::Severity::Error); return tryResult905 .propagateErr(); }}; |
7059 | |
7060 | return NS_OK; |
7061 | } |
7062 | |
7063 | void DatabaseConnection::DoIdleProcessing(bool aNeedsCheckpoint, |
7064 | const Atomic<bool>& aInterrupted) { |
7065 | AssertIsOnConnectionThread(); |
7066 | MOZ_ASSERT(mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7066); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInReadTransaction" ")"); do { *((volatile int*)__null) = 7066; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7067 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7067); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7067; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7068 | |
7069 | AUTO_PROFILER_LABEL("DatabaseConnection::DoIdleProcessing", DOM)mozilla::AutoProfilerLabel raiiObject7069( "DatabaseConnection::DoIdleProcessing" , nullptr, JS::ProfilingCategoryPair::DOM); |
7070 | |
7071 | CachingDatabaseConnection::CachedStatement freelistStmt; |
7072 | const uint32_t freelistCount = [this, &freelistStmt] { |
7073 | QM_TRY_RETURN(GetFreelistCount(freelistStmt), 0u){auto tryResult906 = (GetFreelistCount(freelistStmt)); if ((__builtin_expect (!!(tryResult906.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult906.unwrapErr(); mozilla::dom::quota ::HandleError("GetFreelistCount(freelistStmt)", tryResult906. inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7073, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "GetFreelistCount(freelistStmt)" , tryTempError, 0u); } return tryResult906.unwrap();}; |
7074 | }(); |
7075 | |
7076 | CachedStatement rollbackStmt; |
7077 | CachedStatement beginStmt; |
7078 | if (aNeedsCheckpoint || freelistCount) { |
7079 | QM_TRY_UNWRAP(rollbackStmt, GetCachedStatement("ROLLBACK;"_ns), QM_VOID)auto tryResult907 = (GetCachedStatement("ROLLBACK;"_ns)); if ( (__builtin_expect(!!(tryResult907.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult907.unwrapErr(); mozilla ::dom::quota::HandleError("GetCachedStatement(\"ROLLBACK;\"_ns)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7079, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; } rollbackStmt = tryResult907.unwrap();; |
7080 | QM_TRY_UNWRAP(beginStmt, GetCachedStatement("BEGIN;"_ns), QM_VOID)auto tryResult908 = (GetCachedStatement("BEGIN;"_ns)); if ((__builtin_expect (!!(tryResult908.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult908.unwrapErr(); mozilla::dom::quota ::HandleError("GetCachedStatement(\"BEGIN;\"_ns)", tryTempError , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7080, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; } beginStmt = tryResult908.unwrap();; |
7081 | |
7082 | // Release the connection's normal transaction. It's possible that it could |
7083 | // fail, but that isn't a problem here. |
7084 | Unused << rollbackStmt.Borrow()->Execute(); |
7085 | |
7086 | mInReadTransaction = false; |
7087 | } |
7088 | |
7089 | const bool freedSomePages = |
7090 | freelistCount && [this, &freelistStmt, &rollbackStmt, freelistCount, |
7091 | aNeedsCheckpoint, &aInterrupted] { |
7092 | // Warn in case of an error, but do not propagate it. Just indicate we |
7093 | // didn't free any pages. |
7094 | QM_TRY_INSPECT(auto tryResult909 = (ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt , freelistCount, aNeedsCheckpoint, aInterrupted)); if ((__builtin_expect (!!(tryResult909.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult909.unwrapErr(); mozilla::dom::quota ::HandleError("ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7098, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, false); } const bool& res = tryResult909. inspect(); |
7095 | const bool& res,auto tryResult909 = (ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt , freelistCount, aNeedsCheckpoint, aInterrupted)); if ((__builtin_expect (!!(tryResult909.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult909.unwrapErr(); mozilla::dom::quota ::HandleError("ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7098, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, false); } const bool& res = tryResult909. inspect(); |
7096 | ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount,auto tryResult909 = (ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt , freelistCount, aNeedsCheckpoint, aInterrupted)); if ((__builtin_expect (!!(tryResult909.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult909.unwrapErr(); mozilla::dom::quota ::HandleError("ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7098, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, false); } const bool& res = tryResult909. inspect(); |
7097 | aNeedsCheckpoint, aInterrupted),auto tryResult909 = (ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt , freelistCount, aNeedsCheckpoint, aInterrupted)); if ((__builtin_expect (!!(tryResult909.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult909.unwrapErr(); mozilla::dom::quota ::HandleError("ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7098, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, false); } const bool& res = tryResult909. inspect(); |
7098 | false)auto tryResult909 = (ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt , freelistCount, aNeedsCheckpoint, aInterrupted)); if ((__builtin_expect (!!(tryResult909.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult909.unwrapErr(); mozilla::dom::quota ::HandleError("ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7098, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ReclaimFreePagesWhileIdle(freelistStmt, rollbackStmt, freelistCount, aNeedsCheckpoint, aInterrupted)" , tryTempError, false); } const bool& res = tryResult909. inspect();; |
7099 | |
7100 | // Make sure we didn't leave a transaction running. |
7101 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7101); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 7101; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7102 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7102); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7102; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7103 | |
7104 | return res; |
7105 | }(); |
7106 | |
7107 | // Truncate the WAL if we were asked to or if we managed to free some space. |
7108 | if (aNeedsCheckpoint || freedSomePages) { |
7109 | QM_WARNONLY_TRY(QM_TO_RESULT(CheckpointInternal(CheckpointMode::Truncate))){auto tryResult910 = (ToResult<QMResult>(CheckpointInternal (CheckpointMode::Truncate))); static_assert(std::is_empty_v< typename decltype(tryResult910)::ok_type>); if ((__builtin_expect (!!(tryResult910.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult<QMResult>(CheckpointInternal(CheckpointMode::Truncate))" , tryResult910.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7109, mozilla::dom::quota::Severity::Warning); }}; |
7110 | } |
7111 | |
7112 | // Finally try to restart the read transaction if we rolled it back earlier. |
7113 | if (beginStmt) { |
7114 | QM_WARNONLY_TRY({auto tryResult911 = (ToResult(beginStmt.Borrow()->Execute ()) .andThen([&self = *this](const Ok) -> Result<Ok , nsresult> { self.mInReadTransaction = true; return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult911 )::ok_type>); if ((__builtin_expect(!!(tryResult911.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(beginStmt.Borrow()->Execute()) .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> { self.mInReadTransaction = true; return Ok{}; })" , tryResult911.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7119, mozilla::dom::quota::Severity::Warning); }} |
7115 | MOZ_TO_RESULT(beginStmt.Borrow()->Execute()){auto tryResult911 = (ToResult(beginStmt.Borrow()->Execute ()) .andThen([&self = *this](const Ok) -> Result<Ok , nsresult> { self.mInReadTransaction = true; return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult911 )::ok_type>); if ((__builtin_expect(!!(tryResult911.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(beginStmt.Borrow()->Execute()) .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> { self.mInReadTransaction = true; return Ok{}; })" , tryResult911.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7119, mozilla::dom::quota::Severity::Warning); }} |
7116 | .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> {{auto tryResult911 = (ToResult(beginStmt.Borrow()->Execute ()) .andThen([&self = *this](const Ok) -> Result<Ok , nsresult> { self.mInReadTransaction = true; return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult911 )::ok_type>); if ((__builtin_expect(!!(tryResult911.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(beginStmt.Borrow()->Execute()) .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> { self.mInReadTransaction = true; return Ok{}; })" , tryResult911.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7119, mozilla::dom::quota::Severity::Warning); }} |
7117 | self.mInReadTransaction = true;{auto tryResult911 = (ToResult(beginStmt.Borrow()->Execute ()) .andThen([&self = *this](const Ok) -> Result<Ok , nsresult> { self.mInReadTransaction = true; return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult911 )::ok_type>); if ((__builtin_expect(!!(tryResult911.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(beginStmt.Borrow()->Execute()) .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> { self.mInReadTransaction = true; return Ok{}; })" , tryResult911.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7119, mozilla::dom::quota::Severity::Warning); }} |
7118 | return Ok{};{auto tryResult911 = (ToResult(beginStmt.Borrow()->Execute ()) .andThen([&self = *this](const Ok) -> Result<Ok , nsresult> { self.mInReadTransaction = true; return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult911 )::ok_type>); if ((__builtin_expect(!!(tryResult911.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(beginStmt.Borrow()->Execute()) .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> { self.mInReadTransaction = true; return Ok{}; })" , tryResult911.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7119, mozilla::dom::quota::Severity::Warning); }} |
7119 | })){auto tryResult911 = (ToResult(beginStmt.Borrow()->Execute ()) .andThen([&self = *this](const Ok) -> Result<Ok , nsresult> { self.mInReadTransaction = true; return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult911 )::ok_type>); if ((__builtin_expect(!!(tryResult911.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(beginStmt.Borrow()->Execute()) .andThen([&self = *this](const Ok) -> Result<Ok, nsresult> { self.mInReadTransaction = true; return Ok{}; })" , tryResult911.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7119, mozilla::dom::quota::Severity::Warning); }}; |
7120 | } |
7121 | } |
7122 | |
7123 | Result<bool, nsresult> DatabaseConnection::ReclaimFreePagesWhileIdle( |
7124 | CachedStatement& aFreelistStatement, CachedStatement& aRollbackStatement, |
7125 | uint32_t aFreelistCount, bool aNeedsCheckpoint, |
7126 | const Atomic<bool>& aInterrupted) { |
7127 | AssertIsOnConnectionThread(); |
7128 | MOZ_ASSERT(aFreelistStatement)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aFreelistStatement)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aFreelistStatement))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFreelistStatement" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7128); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFreelistStatement" ")"); do { *((volatile int*)__null) = 7128; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7129 | MOZ_ASSERT(aRollbackStatement)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aRollbackStatement)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aRollbackStatement))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aRollbackStatement" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7129); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aRollbackStatement" ")"); do { *((volatile int*)__null) = 7129; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7130 | MOZ_ASSERT(aFreelistCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aFreelistCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aFreelistCount))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFreelistCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7130); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFreelistCount" ")"); do { *((volatile int*)__null) = 7130; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7131 | MOZ_ASSERT(!mInReadTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInReadTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInReadTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInReadTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7131); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInReadTransaction" ")"); do { *((volatile int*)__null) = 7131; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7132 | MOZ_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7132); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7132; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7133 | |
7134 | AUTO_PROFILER_LABEL("DatabaseConnection::ReclaimFreePagesWhileIdle", DOM)mozilla::AutoProfilerLabel raiiObject7134( "DatabaseConnection::ReclaimFreePagesWhileIdle" , nullptr, JS::ProfilingCategoryPair::DOM); |
7135 | |
7136 | uint32_t pauseOnConnectionThreadMs = StaticPrefs:: |
7137 | dom_indexedDB_connectionIdleMaintenance_pauseOnConnectionThreadMs(); |
7138 | if (pauseOnConnectionThreadMs > 0) { |
7139 | PR_Sleep(PR_MillisecondsToInterval(pauseOnConnectionThreadMs)); |
7140 | } |
7141 | |
7142 | // Make sure we don't keep working if anything else needs this thread. |
7143 | if (aInterrupted) { |
7144 | return false; |
7145 | } |
7146 | |
7147 | // Make all the statements we'll need up front. |
7148 | |
7149 | // Only try to free 10% at a time so that we can bail out if this connection |
7150 | // suddenly becomes active or if the thread is needed otherwise. |
7151 | QM_TRY_INSPECT(auto tryResult912 = (GetCachedStatement( "PRAGMA incremental_vacuum("_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + ");"_ns)); if ((__builtin_expect(!!(tryResult912.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetCachedStatement( \"PRAGMA incremental_vacuum(\"_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + \");\"_ns)" , tryResult912.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7156, mozilla::dom::quota::Severity::Error); return tryResult912 .propagateErr(); } const auto& incrementalVacuumStmt = tryResult912 .inspect(); |
7152 | const auto& incrementalVacuumStmt,auto tryResult912 = (GetCachedStatement( "PRAGMA incremental_vacuum("_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + ");"_ns)); if ((__builtin_expect(!!(tryResult912.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetCachedStatement( \"PRAGMA incremental_vacuum(\"_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + \");\"_ns)" , tryResult912.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7156, mozilla::dom::quota::Severity::Error); return tryResult912 .propagateErr(); } const auto& incrementalVacuumStmt = tryResult912 .inspect(); |
7153 | GetCachedStatement(auto tryResult912 = (GetCachedStatement( "PRAGMA incremental_vacuum("_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + ");"_ns)); if ((__builtin_expect(!!(tryResult912.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetCachedStatement( \"PRAGMA incremental_vacuum(\"_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + \");\"_ns)" , tryResult912.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7156, mozilla::dom::quota::Severity::Error); return tryResult912 .propagateErr(); } const auto& incrementalVacuumStmt = tryResult912 .inspect(); |
7154 | "PRAGMA incremental_vacuum("_ns +auto tryResult912 = (GetCachedStatement( "PRAGMA incremental_vacuum("_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + ");"_ns)); if ((__builtin_expect(!!(tryResult912.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetCachedStatement( \"PRAGMA incremental_vacuum(\"_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + \");\"_ns)" , tryResult912.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7156, mozilla::dom::quota::Severity::Error); return tryResult912 .propagateErr(); } const auto& incrementalVacuumStmt = tryResult912 .inspect(); |
7155 | IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) +auto tryResult912 = (GetCachedStatement( "PRAGMA incremental_vacuum("_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + ");"_ns)); if ((__builtin_expect(!!(tryResult912.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetCachedStatement( \"PRAGMA incremental_vacuum(\"_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + \");\"_ns)" , tryResult912.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7156, mozilla::dom::quota::Severity::Error); return tryResult912 .propagateErr(); } const auto& incrementalVacuumStmt = tryResult912 .inspect(); |
7156 | ");"_ns))auto tryResult912 = (GetCachedStatement( "PRAGMA incremental_vacuum("_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + ");"_ns)); if ((__builtin_expect(!!(tryResult912.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetCachedStatement( \"PRAGMA incremental_vacuum(\"_ns + IntToCString(std::max(uint64_t(1), uint64_t(aFreelistCount / 10))) + \");\"_ns)" , tryResult912.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7156, mozilla::dom::quota::Severity::Error); return tryResult912 .propagateErr(); } const auto& incrementalVacuumStmt = tryResult912 .inspect();; |
7157 | |
7158 | QM_TRY_INSPECT(const auto& beginImmediateStmt,auto tryResult913 = (GetCachedStatement("BEGIN IMMEDIATE;"_ns )); if ((__builtin_expect(!!(tryResult913.isErr()), 0))) { mozilla ::dom::quota::HandleError("GetCachedStatement(\"BEGIN IMMEDIATE;\"_ns)" , tryResult913.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7159, mozilla::dom::quota::Severity::Error); return tryResult913 .propagateErr(); } const auto& beginImmediateStmt = tryResult913 .inspect(); |
7159 | GetCachedStatement("BEGIN IMMEDIATE;"_ns))auto tryResult913 = (GetCachedStatement("BEGIN IMMEDIATE;"_ns )); if ((__builtin_expect(!!(tryResult913.isErr()), 0))) { mozilla ::dom::quota::HandleError("GetCachedStatement(\"BEGIN IMMEDIATE;\"_ns)" , tryResult913.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7159, mozilla::dom::quota::Severity::Error); return tryResult913 .propagateErr(); } const auto& beginImmediateStmt = tryResult913 .inspect();; |
7160 | |
7161 | QM_TRY_INSPECT(const auto& commitStmt, GetCachedStatement("COMMIT;"_ns))auto tryResult914 = (GetCachedStatement("COMMIT;"_ns)); if (( __builtin_expect(!!(tryResult914.isErr()), 0))) { mozilla::dom ::quota::HandleError("GetCachedStatement(\"COMMIT;\"_ns)", tryResult914 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7161, mozilla::dom::quota::Severity::Error); return tryResult914 .propagateErr(); } const auto& commitStmt = tryResult914. inspect();; |
7162 | |
7163 | if (aNeedsCheckpoint) { |
7164 | // Freeing pages is a journaled operation, so it will require additional WAL |
7165 | // space. However, we're idle and are about to checkpoint anyway, so doing a |
7166 | // RESTART checkpoint here should allow us to reuse any existing space. |
7167 | QM_TRY(MOZ_TO_RESULT(CheckpointInternal(CheckpointMode::Restart))){auto tryResult915 = (ToResult(CheckpointInternal(CheckpointMode ::Restart))); static_assert(std::is_empty_v<typename decltype (tryResult915)::ok_type>); if ((__builtin_expect(!!(tryResult915 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(CheckpointInternal(CheckpointMode::Restart))" , tryResult915.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7167, mozilla::dom::quota::Severity::Error); return tryResult915 .propagateErr(); }}; |
7168 | } |
7169 | |
7170 | // Start the write transaction. |
7171 | QM_TRY(MOZ_TO_RESULT(beginImmediateStmt.Borrow()->Execute())){auto tryResult916 = (ToResult(beginImmediateStmt.Borrow()-> Execute())); static_assert(std::is_empty_v<typename decltype (tryResult916)::ok_type>); if ((__builtin_expect(!!(tryResult916 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(beginImmediateStmt.Borrow()->Execute())" , tryResult916.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7171, mozilla::dom::quota::Severity::Error); return tryResult916 .propagateErr(); }}; |
7172 | |
7173 | mInWriteTransaction = true; |
7174 | |
7175 | bool freedSomePages = false; |
7176 | |
7177 | const auto rollback = [&aRollbackStatement, this](const auto&) { |
7178 | MOZ_ASSERT(mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInWriteTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7178); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7178; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7179 | |
7180 | // Something failed, make sure we roll everything back. |
7181 | Unused << aRollbackStatement.Borrow()->Execute(); |
7182 | |
7183 | // XXX Is rollback infallible? Shouldn't we check the result? |
7184 | |
7185 | mInWriteTransaction = false; |
7186 | }; |
7187 | |
7188 | uint64_t previousFreelistCount = (uint64_t)aFreelistCount + 1; |
7189 | |
7190 | QM_TRY(CollectWhile({auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7191 | [&aFreelistCount, &previousFreelistCount,{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7192 | &aInterrupted]() -> Result<bool, nsresult> {{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7193 | if (aInterrupted) {{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7194 | // On interrupt, abort and roll back this transaction. It's ok{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7195 | // if we never make progress here because the idle service{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7196 | // should eventually reclaim this space.{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7197 | return false;{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7198 | }{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7199 | // If we were not able to free anything, we might either see{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7200 | // a DB that has no auto-vacuum support at all or some other{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7201 | // (hopefully temporary) condition that prevents vacuum from{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7202 | // working. Just carry on in non-DEBUG.{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7203 | bool madeProgress = previousFreelistCount != aFreelistCount;{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7204 | previousFreelistCount = aFreelistCount;{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7205 | MOZ_ASSERT(madeProgress);{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7206 | QM_WARNONLY_TRY(MOZ_TO_RESULT(madeProgress));{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7207 | return madeProgress && (aFreelistCount != 0);{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7208 | },{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7209 | [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt,{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7210 | &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> {{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7211 | QM_TRY(MOZ_TO_RESULT(incrementalVacuumStmt.Borrow()->Execute()));{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7212 | |
7213 | freedSomePages = true;{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7214 | |
7215 | QM_TRY_UNWRAP(aFreelistCount,{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7216 | GetFreelistCount(aFreelistStatement));{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7217 | |
7218 | return Ok{};{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7219 | }){auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7220 | .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback,{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7221 | this](Ok) -> Result<Ok, nsresult> {{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7222 | if (aInterrupted) {{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7223 | rollback(Ok{});{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7224 | freedSomePages = false;{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7225 | }{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7226 | |
7227 | if (freedSomePages) {{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7228 | // Commit the write transaction.{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7229 | QM_TRY(MOZ_TO_RESULT(commitStmt.Borrow()->Execute()),{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7230 | QM_PROPAGATE,{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7231 | [](const auto&) { NS_WARNING("Failed to commit!"); });{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7232 | |
7233 | mInWriteTransaction = false;{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7234 | }{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7235 | |
7236 | return Ok{};{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7237 | }),{auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }} |
7238 | QM_PROPAGATE, rollback){auto tryResult921 = (CollectWhile( [&aFreelistCount, & previousFreelistCount, &aInterrupted]() -> Result<bool , nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType <decltype(madeProgress)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("madeProgress", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "madeProgress" ")"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v< typename decltype(tryResult917)::ok_type>); if ((__builtin_expect (!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(madeProgress)", tryResult917.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement , &aFreelistCount, &incrementalVacuumStmt, &freedSomePages , this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert (std::is_empty_v<typename decltype(tryResult918)::ok_type> ); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(incrementalVacuumStmt.Borrow()->Execute())" , tryResult918.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7211, mozilla::dom::quota::Severity::Error); return tryResult918 .propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect (!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError ("GetFreelistCount(aFreelistStatement)", tryResult919.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7216, mozilla::dom::quota::Severity::Error); return tryResult919 .propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, & aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult > { if (aInterrupted) { rollback(Ok{}); freedSomePages = false ; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt .Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect( !!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(commitStmt.Borrow()->Execute())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231, mozilla::dom::quota::Severity::Error); [](const auto& ) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to commit!", nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7231); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal (func, "ToResult(commitStmt.Borrow()->Execute())", tryTempError , Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })); static_assert(std::is_empty_v<typename decltype (tryResult921)::ok_type>); if ((__builtin_expect(!!(tryResult921 .isErr()), 0))) { auto tryTempError = tryResult921.unwrapErr( ); mozilla::dom::quota::HandleError("CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7238, mozilla::dom::quota::Severity::Error); rollback(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func , "CollectWhile( [&aFreelistCount, &previousFreelistCount, &aInterrupted]() -> Result<bool, nsresult> { if (aInterrupted) { return false; } bool madeProgress = previousFreelistCount != aFreelistCount; previousFreelistCount = aFreelistCount; do { static_assert( mozilla::detail::AssertionConditionType<decltype(madeProgress)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(madeProgress))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"madeProgress\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7205); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"madeProgress\" \")\"); do { *((volatile int*)__null) = 7205; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); {auto tryResult917 = (ToResult(madeProgress)); static_assert(std::is_empty_v<typename decltype(tryResult917)::ok_type>); if ((__builtin_expect(!!(tryResult917.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(madeProgress)\", tryResult917.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7206, mozilla::dom::quota::Severity::Warning); }}; return madeProgress && (aFreelistCount != 0); }, [&aFreelistStatement, &aFreelistCount, &incrementalVacuumStmt, &freedSomePages, this]() -> mozilla::Result<Ok, nsresult> { {auto tryResult918 = (ToResult(incrementalVacuumStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult918)::ok_type>); if ((__builtin_expect(!!(tryResult918.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(incrementalVacuumStmt.Borrow()->Execute())\", tryResult918.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7211, mozilla::dom::quota::Severity::Error); return tryResult918.propagateErr(); }}; freedSomePages = true; auto tryResult919 = (GetFreelistCount(aFreelistStatement)); if ((__builtin_expect(!!(tryResult919.isErr()), 0))) { mozilla::dom::quota::HandleError(\"GetFreelistCount(aFreelistStatement)\", tryResult919.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7216, mozilla::dom::quota::Severity::Error); return tryResult919.propagateErr(); } aFreelistCount = tryResult919.unwrap();; return Ok{}; }) .andThen([&commitStmt, &freedSomePages, &aInterrupted, &rollback, this](Ok) -> Result<Ok, nsresult> { if (aInterrupted) { rollback(Ok{}); freedSomePages = false; } if (freedSomePages) { {auto tryResult920 = (ToResult(commitStmt.Borrow()->Execute())); static_assert(std::is_empty_v<typename decltype(tryResult920)::ok_type>); if ((__builtin_expect(!!(tryResult920.isErr()), 0))) { auto tryTempError = tryResult920.unwrapErr(); mozilla::dom::quota::HandleError(\"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231, mozilla::dom::quota::Severity::Error); [](const auto&) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to commit!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7231); }(tryTempError); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"ToResult(commitStmt.Borrow()->Execute())\", tryTempError, Err(tryTempError)); }}; mInWriteTransaction = false; } return Ok{}; })" , tryTempError, Err(tryTempError)); }}; |
7239 | |
7240 | return freedSomePages; |
7241 | } |
7242 | |
7243 | Result<uint32_t, nsresult> DatabaseConnection::GetFreelistCount( |
7244 | CachedStatement& aCachedStatement) { |
7245 | AssertIsOnConnectionThread(); |
7246 | |
7247 | AUTO_PROFILER_LABEL("DatabaseConnection::GetFreelistCount", DOM)mozilla::AutoProfilerLabel raiiObject7247( "DatabaseConnection::GetFreelistCount" , nullptr, JS::ProfilingCategoryPair::DOM); |
7248 | |
7249 | if (!aCachedStatement) { |
7250 | QM_TRY_UNWRAP(aCachedStatement,auto tryResult922 = (GetCachedStatement("PRAGMA freelist_count;"_ns )); if ((__builtin_expect(!!(tryResult922.isErr()), 0))) { mozilla ::dom::quota::HandleError("GetCachedStatement(\"PRAGMA freelist_count;\"_ns)" , tryResult922.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7251, mozilla::dom::quota::Severity::Error); return tryResult922 .propagateErr(); } aCachedStatement = tryResult922.unwrap(); |
7251 | GetCachedStatement("PRAGMA freelist_count;"_ns))auto tryResult922 = (GetCachedStatement("PRAGMA freelist_count;"_ns )); if ((__builtin_expect(!!(tryResult922.isErr()), 0))) { mozilla ::dom::quota::HandleError("GetCachedStatement(\"PRAGMA freelist_count;\"_ns)" , tryResult922.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7251, mozilla::dom::quota::Severity::Error); return tryResult922 .propagateErr(); } aCachedStatement = tryResult922.unwrap();; |
7252 | } |
7253 | |
7254 | const auto borrowedStatement = aCachedStatement.Borrow(); |
7255 | |
7256 | QM_TRY_UNWRAP(const DebugOnly<bool> hasResult,auto tryResult923 = (::mozilla::ToResultInvokeMember( (&* borrowedStatement), &::mozilla::detail::DerefedType<decltype (&*borrowedStatement)>::ExecuteStep)); if ((__builtin_expect (!!(tryResult923.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (&*borrowedStatement), &::mozilla::detail::DerefedType<decltype(&*borrowedStatement)>::ExecuteStep)" , tryResult923.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7257, mozilla::dom::quota::Severity::Error); return tryResult923 .propagateErr(); } const DebugOnly<bool> hasResult = tryResult923 .unwrap(); |
7257 | MOZ_TO_RESULT_INVOKE_MEMBER(&*borrowedStatement, ExecuteStep))auto tryResult923 = (::mozilla::ToResultInvokeMember( (&* borrowedStatement), &::mozilla::detail::DerefedType<decltype (&*borrowedStatement)>::ExecuteStep)); if ((__builtin_expect (!!(tryResult923.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (&*borrowedStatement), &::mozilla::detail::DerefedType<decltype(&*borrowedStatement)>::ExecuteStep)" , tryResult923.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7257, mozilla::dom::quota::Severity::Error); return tryResult923 .propagateErr(); } const DebugOnly<bool> hasResult = tryResult923 .unwrap();; |
7258 | |
7259 | MOZ_ASSERT(hasResult)do { static_assert( mozilla::detail::AssertionConditionType< decltype(hasResult)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(hasResult))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("hasResult", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7259); AnnotateMozCrashReason("MOZ_ASSERT" "(" "hasResult" ")" ); do { *((volatile int*)__null) = 7259; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7260 | |
7261 | QM_TRY_INSPECT(const int32_t& freelistCount,auto tryResult924 = (::mozilla::ToResultInvokeMember( (*borrowedStatement ), &::mozilla::detail::DerefedType<decltype(*borrowedStatement )>::GetInt32, 0)); if ((__builtin_expect(!!(tryResult924.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (*borrowedStatement), &::mozilla::detail::DerefedType<decltype(*borrowedStatement)>::GetInt32, 0)" , tryResult924.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7262, mozilla::dom::quota::Severity::Error); return tryResult924 .propagateErr(); } const int32_t& freelistCount = tryResult924 .inspect(); |
7262 | MOZ_TO_RESULT_INVOKE_MEMBER(*borrowedStatement, GetInt32, 0))auto tryResult924 = (::mozilla::ToResultInvokeMember( (*borrowedStatement ), &::mozilla::detail::DerefedType<decltype(*borrowedStatement )>::GetInt32, 0)); if ((__builtin_expect(!!(tryResult924.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (*borrowedStatement), &::mozilla::detail::DerefedType<decltype(*borrowedStatement)>::GetInt32, 0)" , tryResult924.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7262, mozilla::dom::quota::Severity::Error); return tryResult924 .propagateErr(); } const int32_t& freelistCount = tryResult924 .inspect();; |
7263 | |
7264 | MOZ_ASSERT(freelistCount >= 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(freelistCount >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(freelistCount >= 0))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("freelistCount >= 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7264); AnnotateMozCrashReason("MOZ_ASSERT" "(" "freelistCount >= 0" ")"); do { *((volatile int*)__null) = 7264; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7265 | |
7266 | return uint32_t(freelistCount); |
7267 | } |
7268 | |
7269 | void DatabaseConnection::Close() { |
7270 | AssertIsOnConnectionThread(); |
7271 | MOZ_ASSERT(!mDEBUGSavepointCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDEBUGSavepointCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDEBUGSavepointCount))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("!mDEBUGSavepointCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7271); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDEBUGSavepointCount" ")"); do { *((volatile int*)__null) = 7271; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7272 | MOZ_DIAGNOSTIC_ASSERT(!mInWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInWriteTransaction))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mInWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7272); AnnotateMozCrashReason("MOZ_DIAGNOSTIC_ASSERT" "(" "!mInWriteTransaction" ")"); do { *((volatile int*)__null) = 7272; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7273 | |
7274 | AUTO_PROFILER_LABEL("DatabaseConnection::Close", DOM)mozilla::AutoProfilerLabel raiiObject7274( "DatabaseConnection::Close" , nullptr, JS::ProfilingCategoryPair::DOM); |
7275 | |
7276 | if (mUpdateRefcountFunction) { |
7277 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (MutableStorageConnection().RemoveFunction("update_refcount"_ns ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(MutableStorageConnection().RemoveFunction(\"update_refcount\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7278); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(MutableStorageConnection().RemoveFunction(\"update_refcount\"_ns))" ")"); do { *((volatile int*)__null) = 7278; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
7278 | MutableStorageConnection().RemoveFunction("update_refcount"_ns))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (MutableStorageConnection().RemoveFunction("update_refcount"_ns ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(MutableStorageConnection().RemoveFunction(\"update_refcount\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7278); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(MutableStorageConnection().RemoveFunction(\"update_refcount\"_ns))" ")"); do { *((volatile int*)__null) = 7278; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
7279 | mUpdateRefcountFunction = nullptr; |
7280 | } |
7281 | |
7282 | CachingDatabaseConnection::Close(); |
7283 | |
7284 | mFileManager.destroy(); |
7285 | } |
7286 | |
7287 | nsresult DatabaseConnection::DisableQuotaChecks() { |
7288 | AssertIsOnConnectionThread(); |
7289 | MOZ_ASSERT(HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(HasStorageConnection())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(HasStorageConnection()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7289); AnnotateMozCrashReason("MOZ_ASSERT" "(" "HasStorageConnection()" ")"); do { *((volatile int*)__null) = 7289; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7290 | |
7291 | if (!mQuotaObject) { |
7292 | MOZ_ASSERT(!mJournalQuotaObject)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mJournalQuotaObject)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mJournalQuotaObject))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mJournalQuotaObject" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7292); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mJournalQuotaObject" ")"); do { *((volatile int*)__null) = 7292; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7293 | |
7294 | QM_TRY(MOZ_TO_RESULT(MutableStorageConnection().GetQuotaObjects({auto tryResult925 = (ToResult(MutableStorageConnection().GetQuotaObjects ( getter_AddRefs(mQuotaObject), getter_AddRefs(mJournalQuotaObject )))); static_assert(std::is_empty_v<typename decltype(tryResult925 )::ok_type>); if ((__builtin_expect(!!(tryResult925.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(MutableStorageConnection().GetQuotaObjects( getter_AddRefs(mQuotaObject), getter_AddRefs(mJournalQuotaObject)))" , tryResult925.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7295, mozilla::dom::quota::Severity::Error); return tryResult925 .propagateErr(); }} |
7295 | getter_AddRefs(mQuotaObject), getter_AddRefs(mJournalQuotaObject)))){auto tryResult925 = (ToResult(MutableStorageConnection().GetQuotaObjects ( getter_AddRefs(mQuotaObject), getter_AddRefs(mJournalQuotaObject )))); static_assert(std::is_empty_v<typename decltype(tryResult925 )::ok_type>); if ((__builtin_expect(!!(tryResult925.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(MutableStorageConnection().GetQuotaObjects( getter_AddRefs(mQuotaObject), getter_AddRefs(mJournalQuotaObject)))" , tryResult925.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7295, mozilla::dom::quota::Severity::Error); return tryResult925 .propagateErr(); }}; |
7296 | |
7297 | MOZ_ASSERT(mQuotaObject)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mQuotaObject)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mQuotaObject))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mQuotaObject", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7297); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mQuotaObject" ")"); do { *((volatile int*)__null) = 7297; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7298 | MOZ_ASSERT(mJournalQuotaObject)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mJournalQuotaObject)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mJournalQuotaObject))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mJournalQuotaObject" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7298); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mJournalQuotaObject" ")"); do { *((volatile int*)__null) = 7298; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7299 | } |
7300 | |
7301 | mQuotaObject->DisableQuotaCheck(); |
7302 | mJournalQuotaObject->DisableQuotaCheck(); |
7303 | |
7304 | return NS_OK; |
7305 | } |
7306 | |
7307 | void DatabaseConnection::EnableQuotaChecks() { |
7308 | AssertIsOnConnectionThread(); |
7309 | if (!mQuotaObject) { |
7310 | MOZ_ASSERT(!mJournalQuotaObject)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mJournalQuotaObject)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mJournalQuotaObject))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mJournalQuotaObject" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7310); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mJournalQuotaObject" ")"); do { *((volatile int*)__null) = 7310; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7311 | |
7312 | // DisableQuotaChecks failed earlier, so we don't need to enable quota |
7313 | // checks again. |
7314 | return; |
7315 | } |
7316 | |
7317 | MOZ_ASSERT(mJournalQuotaObject)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mJournalQuotaObject)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mJournalQuotaObject))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mJournalQuotaObject" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7317); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mJournalQuotaObject" ")"); do { *((volatile int*)__null) = 7317; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7318 | |
7319 | const RefPtr<QuotaObject> quotaObject = std::move(mQuotaObject); |
7320 | const RefPtr<QuotaObject> journalQuotaObject = std::move(mJournalQuotaObject); |
7321 | |
7322 | quotaObject->EnableQuotaCheck(); |
7323 | journalQuotaObject->EnableQuotaCheck(); |
7324 | |
7325 | QM_TRY_INSPECT(const int64_t& fileSize, GetFileSize(quotaObject->Path()),auto tryResult926 = (GetFileSize(quotaObject->Path())); if ((__builtin_expect(!!(tryResult926.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult926.unwrapErr(); mozilla ::dom::quota::HandleError("GetFileSize(quotaObject->Path())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7326, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; } const int64_t& fileSize = tryResult926.inspect(); |
7326 | QM_VOID)auto tryResult926 = (GetFileSize(quotaObject->Path())); if ((__builtin_expect(!!(tryResult926.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult926.unwrapErr(); mozilla ::dom::quota::HandleError("GetFileSize(quotaObject->Path())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7326, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; } const int64_t& fileSize = tryResult926.inspect();; |
7327 | QM_TRY_INSPECT(const int64_t& journalFileSize,auto tryResult927 = (GetFileSize(journalQuotaObject->Path( ))); if ((__builtin_expect(!!(tryResult927.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult927.unwrapErr (); mozilla::dom::quota::HandleError("GetFileSize(journalQuotaObject->Path())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7328, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; } const int64_t& journalFileSize = tryResult927.inspect (); |
7328 | GetFileSize(journalQuotaObject->Path()), QM_VOID)auto tryResult927 = (GetFileSize(journalQuotaObject->Path( ))); if ((__builtin_expect(!!(tryResult927.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult927.unwrapErr (); mozilla::dom::quota::HandleError("GetFileSize(journalQuotaObject->Path())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7328, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; } const int64_t& journalFileSize = tryResult927.inspect ();; |
7329 | |
7330 | DebugOnly<bool> result = journalQuotaObject->MaybeUpdateSize( |
7331 | journalFileSize, /* aTruncate */ true); |
7332 | MOZ_ASSERT(result)do { static_assert( mozilla::detail::AssertionConditionType< decltype(result)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(result))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("result", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7332); AnnotateMozCrashReason("MOZ_ASSERT" "(" "result" ")" ); do { *((volatile int*)__null) = 7332; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7333 | |
7334 | result = quotaObject->MaybeUpdateSize(fileSize, /* aTruncate */ true); |
7335 | MOZ_ASSERT(result)do { static_assert( mozilla::detail::AssertionConditionType< decltype(result)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(result))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("result", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7335); AnnotateMozCrashReason("MOZ_ASSERT" "(" "result" ")" ); do { *((volatile int*)__null) = 7335; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7336 | } |
7337 | |
7338 | Result<int64_t, nsresult> DatabaseConnection::GetFileSize( |
7339 | const nsAString& aPath) { |
7340 | MOZ_ASSERT(!aPath.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aPath.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aPath.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aPath.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7340); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aPath.IsEmpty()" ")"); do { *((volatile int*)__null) = 7340; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7341 | |
7342 | QM_TRY_INSPECT(const auto& file, QM_NewLocalFile(aPath))auto tryResult928 = (QM_NewLocalFile(aPath)); if ((__builtin_expect (!!(tryResult928.isErr()), 0))) { mozilla::dom::quota::HandleError ("QM_NewLocalFile(aPath)", tryResult928.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7342, mozilla::dom::quota::Severity::Error); return tryResult928 .propagateErr(); } const auto& file = tryResult928.inspect ();; |
7343 | QM_TRY_INSPECT(const bool& exists, MOZ_TO_RESULT_INVOKE_MEMBER(file, Exists))auto tryResult929 = (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::Exists )); if ((__builtin_expect(!!(tryResult929.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::Exists)" , tryResult929.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7343, mozilla::dom::quota::Severity::Error); return tryResult929 .propagateErr(); } const bool& exists = tryResult929.inspect ();; |
7344 | |
7345 | if (exists) { |
7346 | QM_TRY_RETURN(MOZ_TO_RESULT_INVOKE_MEMBER(file, GetFileSize)){auto tryResult930 = (::mozilla::ToResultInvokeMember( (file) , &::mozilla::detail::DerefedType<decltype(file)>:: GetFileSize)); if ((__builtin_expect(!!(tryResult930.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize)" , tryResult930.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7346, mozilla::dom::quota::Severity::Error); } return tryResult930 ;}; |
7347 | } |
7348 | |
7349 | return 0; |
7350 | } |
7351 | |
7352 | DatabaseConnection::AutoSavepoint::AutoSavepoint() |
7353 | : mConnection(nullptr) |
7354 | #ifdef DEBUG1 |
7355 | , |
7356 | mDEBUGTransaction(nullptr) |
7357 | #endif |
7358 | { |
7359 | MOZ_COUNT_CTOR(DatabaseConnection::AutoSavepoint)do { static_assert(std::is_class_v<DatabaseConnection::AutoSavepoint >, "Token '" "DatabaseConnection::AutoSavepoint" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, DatabaseConnection ::AutoSavepoint>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "DatabaseConnection::AutoSavepoint" , sizeof(*this)); } while (0); |
7360 | } |
7361 | |
7362 | DatabaseConnection::AutoSavepoint::~AutoSavepoint() { |
7363 | MOZ_COUNT_DTOR(DatabaseConnection::AutoSavepoint)do { static_assert(std::is_class_v<DatabaseConnection::AutoSavepoint >, "Token '" "DatabaseConnection::AutoSavepoint" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, DatabaseConnection ::AutoSavepoint>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "DatabaseConnection::AutoSavepoint" , sizeof(*this)); } while (0); |
7364 | |
7365 | if (mConnection) { |
7366 | mConnection->AssertIsOnConnectionThread(); |
7367 | MOZ_ASSERT(mDEBUGTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7367); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction" ")"); do { *((volatile int*)__null) = 7367; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7368 | MOZ_ASSERT(do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction->GetMode() == IDBTransaction::Mode ::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::VersionChange)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction->GetMode () == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction-> GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::VersionChange))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7372); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7372; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7369 | mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction->GetMode() == IDBTransaction::Mode ::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::VersionChange)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction->GetMode () == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction-> GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::VersionChange))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7372); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7372; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7370 | mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction->GetMode() == IDBTransaction::Mode ::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::VersionChange)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction->GetMode () == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction-> GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::VersionChange))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7372); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7372; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7371 | mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction->GetMode() == IDBTransaction::Mode ::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::VersionChange)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction->GetMode () == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction-> GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::VersionChange))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7372); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7372; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7372 | mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction->GetMode() == IDBTransaction::Mode ::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction ::Mode::VersionChange)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction->GetMode () == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction-> GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction ->GetMode() == IDBTransaction::Mode::VersionChange))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7372); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWrite || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::ReadWriteFlush || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::Cleanup || mDEBUGTransaction->GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7372; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7373 | |
7374 | QM_WARNONLY_TRY(QM_TO_RESULT(mConnection->RollbackSavepoint())){auto tryResult931 = (ToResult<QMResult>(mConnection-> RollbackSavepoint())); static_assert(std::is_empty_v<typename decltype(tryResult931)::ok_type>); if ((__builtin_expect( !!(tryResult931.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult<QMResult>(mConnection->RollbackSavepoint())" , tryResult931.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7374, mozilla::dom::quota::Severity::Warning); }}; |
7375 | } |
7376 | } |
7377 | |
7378 | nsresult DatabaseConnection::AutoSavepoint::Start( |
7379 | const TransactionBase& aTransaction) { |
7380 | MOZ_ASSERT(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7383); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7383; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7381 | aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7383); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7383; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7382 | aTransaction.GetMode() == IDBTransaction::Mode::Cleanup ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7383); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7383; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7383 | aTransaction.GetMode() == IDBTransaction::Mode::VersionChange)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7383); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aTransaction.GetMode() == IDBTransaction::Mode::ReadWrite || aTransaction.GetMode() == IDBTransaction::Mode::ReadWriteFlush || aTransaction.GetMode() == IDBTransaction::Mode::Cleanup || aTransaction.GetMode() == IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 7383; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7384 | |
7385 | DatabaseConnection* connection = aTransaction.GetDatabase().GetConnection(); |
7386 | MOZ_ASSERT(connection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(connection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(connection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("connection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7386); AnnotateMozCrashReason("MOZ_ASSERT" "(" "connection" ")"); do { *((volatile int*)__null) = 7386; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7387 | connection->AssertIsOnConnectionThread(); |
7388 | |
7389 | // The previous operation failed to begin a write transaction and the |
7390 | // following opertion jumped to the connection thread before the previous |
7391 | // operation has updated its failure to the transaction. |
7392 | if (!connection->GetUpdateRefcountFunction()) { |
7393 | NS_WARNING(NS_DebugBreak(NS_DEBUG_WARNING, "The connection was closed because the previous operation " "failed!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7395) |
7394 | "The connection was closed because the previous operation "NS_DebugBreak(NS_DEBUG_WARNING, "The connection was closed because the previous operation " "failed!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7395) |
7395 | "failed!")NS_DebugBreak(NS_DEBUG_WARNING, "The connection was closed because the previous operation " "failed!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7395); |
7396 | return NS_ERROR_DOM_INDEXEDDB_ABORT_ERR; |
7397 | } |
7398 | |
7399 | MOZ_ASSERT(!mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7399); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mConnection" ")"); do { *((volatile int*)__null) = 7399; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7400 | MOZ_ASSERT(!mDEBUGTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDEBUGTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDEBUGTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mDEBUGTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7400); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDEBUGTransaction" ")"); do { *((volatile int*)__null) = 7400; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7401 | |
7402 | QM_TRY(MOZ_TO_RESULT(connection->StartSavepoint())){auto tryResult932 = (ToResult(connection->StartSavepoint( ))); static_assert(std::is_empty_v<typename decltype(tryResult932 )::ok_type>); if ((__builtin_expect(!!(tryResult932.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->StartSavepoint())" , tryResult932.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7402, mozilla::dom::quota::Severity::Error); return tryResult932 .propagateErr(); }}; |
7403 | |
7404 | mConnection = connection; |
7405 | #ifdef DEBUG1 |
7406 | mDEBUGTransaction = &aTransaction; |
7407 | #endif |
7408 | |
7409 | return NS_OK; |
7410 | } |
7411 | |
7412 | nsresult DatabaseConnection::AutoSavepoint::Commit() { |
7413 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7413); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7413; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7414 | mConnection->AssertIsOnConnectionThread(); |
7415 | MOZ_ASSERT(mDEBUGTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDEBUGTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDEBUGTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDEBUGTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7415); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDEBUGTransaction" ")"); do { *((volatile int*)__null) = 7415; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7416 | |
7417 | QM_TRY(MOZ_TO_RESULT(mConnection->ReleaseSavepoint())){auto tryResult933 = (ToResult(mConnection->ReleaseSavepoint ())); static_assert(std::is_empty_v<typename decltype(tryResult933 )::ok_type>); if ((__builtin_expect(!!(tryResult933.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(mConnection->ReleaseSavepoint())" , tryResult933.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7417, mozilla::dom::quota::Severity::Error); return tryResult933 .propagateErr(); }}; |
7418 | |
7419 | mConnection = nullptr; |
7420 | #ifdef DEBUG1 |
7421 | mDEBUGTransaction = nullptr; |
7422 | #endif |
7423 | |
7424 | return NS_OK; |
7425 | } |
7426 | |
7427 | DatabaseConnection::UpdateRefcountFunction::UpdateRefcountFunction( |
7428 | DatabaseConnection* const aConnection, DatabaseFileManager& aFileManager) |
7429 | : mConnection(aConnection), |
7430 | mFileManager(aFileManager), |
7431 | mInSavepoint(false) { |
7432 | MOZ_ASSERT(aConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7432); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aConnection" ")"); do { *((volatile int*)__null) = 7432; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7433 | aConnection->AssertIsOnConnectionThread(); |
7434 | } |
7435 | |
7436 | nsresult DatabaseConnection::UpdateRefcountFunction::WillCommit() { |
7437 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7437); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7437; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7438 | mConnection->AssertIsOnConnectionThread(); |
7439 | MOZ_ASSERT(mConnection->HasStorageConnection())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection->HasStorageConnection())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mConnection->HasStorageConnection()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection->HasStorageConnection()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7439); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection->HasStorageConnection()" ")"); do { *((volatile int*)__null) = 7439; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7440 | |
7441 | AUTO_PROFILER_LABEL("DatabaseConnection::UpdateRefcountFunction::WillCommit",mozilla::AutoProfilerLabel raiiObject7442( "DatabaseConnection::UpdateRefcountFunction::WillCommit" , nullptr, JS::ProfilingCategoryPair::DOM) |
7442 | DOM)mozilla::AutoProfilerLabel raiiObject7442( "DatabaseConnection::UpdateRefcountFunction::WillCommit" , nullptr, JS::ProfilingCategoryPair::DOM); |
7443 | |
7444 | // The parameter names are not used, parameters are bound by index |
7445 | // only locally in the same function. |
7446 | auto update = |
7447 | [updateStatement = LazyStatement{*mConnection, |
7448 | "UPDATE file " |
7449 | "SET refcount = refcount + :delta " |
7450 | "WHERE id = :id"_ns}, |
7451 | selectStatement = LazyStatement{*mConnection, |
7452 | "SELECT id " |
7453 | "FROM file " |
7454 | "WHERE id = :id"_ns}, |
7455 | insertStatement = |
7456 | LazyStatement{ |
7457 | *mConnection, |
7458 | "INSERT INTO file (id, refcount) VALUES(:id, :delta)"_ns}, |
7459 | this](int64_t aId, int32_t aDelta) mutable -> Result<Ok, nsresult> { |
7460 | AUTO_PROFILER_LABEL(mozilla::AutoProfilerLabel raiiObject7461( "DatabaseConnection::UpdateRefcountFunction::WillCommit::Update" , nullptr, JS::ProfilingCategoryPair::DOM) |
7461 | "DatabaseConnection::UpdateRefcountFunction::WillCommit::Update", DOM)mozilla::AutoProfilerLabel raiiObject7461( "DatabaseConnection::UpdateRefcountFunction::WillCommit::Update" , nullptr, JS::ProfilingCategoryPair::DOM); |
7462 | { |
7463 | QM_TRY_INSPECT(const auto& borrowedUpdateStatement,auto tryResult934 = (updateStatement.Borrow()); if ((__builtin_expect (!!(tryResult934.isErr()), 0))) { mozilla::dom::quota::HandleError ("updateStatement.Borrow()", tryResult934.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7464, mozilla::dom::quota::Severity::Error); return tryResult934 .propagateErr(); } const auto& borrowedUpdateStatement = tryResult934 .inspect(); |
7464 | updateStatement.Borrow())auto tryResult934 = (updateStatement.Borrow()); if ((__builtin_expect (!!(tryResult934.isErr()), 0))) { mozilla::dom::quota::HandleError ("updateStatement.Borrow()", tryResult934.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7464, mozilla::dom::quota::Severity::Error); return tryResult934 .propagateErr(); } const auto& borrowedUpdateStatement = tryResult934 .inspect();; |
7465 | |
7466 | QM_TRY({auto tryResult935 = (ToResult(borrowedUpdateStatement->BindInt32ByIndex (0, aDelta))); static_assert(std::is_empty_v<typename decltype (tryResult935)::ok_type>); if ((__builtin_expect(!!(tryResult935 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedUpdateStatement->BindInt32ByIndex(0, aDelta))" , tryResult935.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7467, mozilla::dom::quota::Severity::Error); return tryResult935 .propagateErr(); }} |
7467 | MOZ_TO_RESULT(borrowedUpdateStatement->BindInt32ByIndex(0, aDelta))){auto tryResult935 = (ToResult(borrowedUpdateStatement->BindInt32ByIndex (0, aDelta))); static_assert(std::is_empty_v<typename decltype (tryResult935)::ok_type>); if ((__builtin_expect(!!(tryResult935 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedUpdateStatement->BindInt32ByIndex(0, aDelta))" , tryResult935.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7467, mozilla::dom::quota::Severity::Error); return tryResult935 .propagateErr(); }}; |
7468 | QM_TRY(MOZ_TO_RESULT(borrowedUpdateStatement->BindInt64ByIndex(1, aId))){auto tryResult936 = (ToResult(borrowedUpdateStatement->BindInt64ByIndex (1, aId))); static_assert(std::is_empty_v<typename decltype (tryResult936)::ok_type>); if ((__builtin_expect(!!(tryResult936 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedUpdateStatement->BindInt64ByIndex(1, aId))" , tryResult936.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7468, mozilla::dom::quota::Severity::Error); return tryResult936 .propagateErr(); }}; |
7469 | QM_TRY(MOZ_TO_RESULT(borrowedUpdateStatement->Execute())){auto tryResult937 = (ToResult(borrowedUpdateStatement->Execute ())); static_assert(std::is_empty_v<typename decltype(tryResult937 )::ok_type>); if ((__builtin_expect(!!(tryResult937.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedUpdateStatement->Execute())" , tryResult937.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7469, mozilla::dom::quota::Severity::Error); return tryResult937 .propagateErr(); }}; |
7470 | } |
7471 | |
7472 | QM_TRY_INSPECT(auto tryResult938 = (::mozilla::ToResultInvokeMember( (mConnection ->MutableStorageConnection()), &::mozilla::detail::DerefedType <decltype(mConnection->MutableStorageConnection())>:: GetAffectedRows)); if ((__builtin_expect(!!(tryResult938.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (mConnection->MutableStorageConnection()), &::mozilla::detail::DerefedType<decltype(mConnection->MutableStorageConnection())>::GetAffectedRows)" , tryResult938.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7475, mozilla::dom::quota::Severity::Error); return tryResult938 .propagateErr(); } const int32_t& rows = tryResult938.inspect (); |
7473 | const int32_t& rows,auto tryResult938 = (::mozilla::ToResultInvokeMember( (mConnection ->MutableStorageConnection()), &::mozilla::detail::DerefedType <decltype(mConnection->MutableStorageConnection())>:: GetAffectedRows)); if ((__builtin_expect(!!(tryResult938.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (mConnection->MutableStorageConnection()), &::mozilla::detail::DerefedType<decltype(mConnection->MutableStorageConnection())>::GetAffectedRows)" , tryResult938.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7475, mozilla::dom::quota::Severity::Error); return tryResult938 .propagateErr(); } const int32_t& rows = tryResult938.inspect (); |
7474 | MOZ_TO_RESULT_INVOKE_MEMBER(mConnection->MutableStorageConnection(),auto tryResult938 = (::mozilla::ToResultInvokeMember( (mConnection ->MutableStorageConnection()), &::mozilla::detail::DerefedType <decltype(mConnection->MutableStorageConnection())>:: GetAffectedRows)); if ((__builtin_expect(!!(tryResult938.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (mConnection->MutableStorageConnection()), &::mozilla::detail::DerefedType<decltype(mConnection->MutableStorageConnection())>::GetAffectedRows)" , tryResult938.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7475, mozilla::dom::quota::Severity::Error); return tryResult938 .propagateErr(); } const int32_t& rows = tryResult938.inspect (); |
7475 | GetAffectedRows))auto tryResult938 = (::mozilla::ToResultInvokeMember( (mConnection ->MutableStorageConnection()), &::mozilla::detail::DerefedType <decltype(mConnection->MutableStorageConnection())>:: GetAffectedRows)); if ((__builtin_expect(!!(tryResult938.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (mConnection->MutableStorageConnection()), &::mozilla::detail::DerefedType<decltype(mConnection->MutableStorageConnection())>::GetAffectedRows)" , tryResult938.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7475, mozilla::dom::quota::Severity::Error); return tryResult938 .propagateErr(); } const int32_t& rows = tryResult938.inspect ();; |
7476 | |
7477 | if (rows > 0) { |
7478 | QM_TRY_INSPECT(auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7479 | const bool& hasResult,auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7480 | selectStatementauto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7481 | .BorrowAndExecuteSingleStep(auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7482 | [aId](auto& stmt) -> Result<Ok, nsresult> {auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7483 | QM_TRY(MOZ_TO_RESULT(stmt.BindInt64ByIndex(0, aId)));auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7484 | return Ok{};auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7485 | })auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect (); |
7486 | .map(IsSome))auto tryResult940 = (selectStatement .BorrowAndExecuteSingleStep ( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert (std::is_empty_v<typename decltype(tryResult939)::ok_type> ); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(stmt.BindInt64ByIndex(0, aId))" , tryResult939.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7483, mozilla::dom::quota::Severity::Error); return tryResult939 .propagateErr(); }}; return Ok{}; }) .map(IsSome)); if ((__builtin_expect (!!(tryResult940.isErr()), 0))) { mozilla::dom::quota::HandleError ("selectStatement .BorrowAndExecuteSingleStep( [aId](auto& stmt) -> Result<Ok, nsresult> { {auto tryResult939 = (ToResult(stmt.BindInt64ByIndex(0, aId))); static_assert(std::is_empty_v<typename decltype(tryResult939)::ok_type>); if ((__builtin_expect(!!(tryResult939.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.BindInt64ByIndex(0, aId))\", tryResult939.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7483, mozilla::dom::quota::Severity::Error); return tryResult939.propagateErr(); }}; return Ok{}; }) .map(IsSome)" , tryResult940.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7486, mozilla::dom::quota::Severity::Error); return tryResult940 .propagateErr(); } const bool& hasResult = tryResult940.inspect ();; |
7487 | |
7488 | if (!hasResult) { |
7489 | // Don't have to create the journal here, we can create all at once, |
7490 | // just before commit |
7491 | mJournalsToCreateBeforeCommit.AppendElement(aId); |
7492 | } |
7493 | |
7494 | return Ok{}; |
7495 | } |
7496 | |
7497 | QM_TRY_INSPECT(const auto& borrowedInsertStatement,auto tryResult941 = (insertStatement.Borrow()); if ((__builtin_expect (!!(tryResult941.isErr()), 0))) { mozilla::dom::quota::HandleError ("insertStatement.Borrow()", tryResult941.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7498, mozilla::dom::quota::Severity::Error); return tryResult941 .propagateErr(); } const auto& borrowedInsertStatement = tryResult941 .inspect(); |
7498 | insertStatement.Borrow())auto tryResult941 = (insertStatement.Borrow()); if ((__builtin_expect (!!(tryResult941.isErr()), 0))) { mozilla::dom::quota::HandleError ("insertStatement.Borrow()", tryResult941.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7498, mozilla::dom::quota::Severity::Error); return tryResult941 .propagateErr(); } const auto& borrowedInsertStatement = tryResult941 .inspect();; |
7499 | |
7500 | QM_TRY(MOZ_TO_RESULT(borrowedInsertStatement->BindInt64ByIndex(0, aId))){auto tryResult942 = (ToResult(borrowedInsertStatement->BindInt64ByIndex (0, aId))); static_assert(std::is_empty_v<typename decltype (tryResult942)::ok_type>); if ((__builtin_expect(!!(tryResult942 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedInsertStatement->BindInt64ByIndex(0, aId))" , tryResult942.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7500, mozilla::dom::quota::Severity::Error); return tryResult942 .propagateErr(); }}; |
7501 | QM_TRY(MOZ_TO_RESULT(borrowedInsertStatement->BindInt32ByIndex(1, aDelta))){auto tryResult943 = (ToResult(borrowedInsertStatement->BindInt32ByIndex (1, aDelta))); static_assert(std::is_empty_v<typename decltype (tryResult943)::ok_type>); if ((__builtin_expect(!!(tryResult943 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedInsertStatement->BindInt32ByIndex(1, aDelta))" , tryResult943.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7501, mozilla::dom::quota::Severity::Error); return tryResult943 .propagateErr(); }}; |
7502 | QM_TRY(MOZ_TO_RESULT(borrowedInsertStatement->Execute())){auto tryResult944 = (ToResult(borrowedInsertStatement->Execute ())); static_assert(std::is_empty_v<typename decltype(tryResult944 )::ok_type>); if ((__builtin_expect(!!(tryResult944.isErr( )), 0))) { mozilla::dom::quota::HandleError("ToResult(borrowedInsertStatement->Execute())" , tryResult944.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7502, mozilla::dom::quota::Severity::Error); return tryResult944 .propagateErr(); }}; |
7503 | |
7504 | mJournalsToRemoveAfterCommit.AppendElement(aId); |
7505 | |
7506 | return Ok{}; |
7507 | }; |
7508 | |
7509 | QM_TRY(CollectEachInRange({auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7510 | mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> {{auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7511 | const auto delta = entry.GetData()->Delta();{auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7512 | if (delta) {{auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7513 | QM_TRY(update(entry.GetKey(), delta));{auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7514 | }{auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7515 | |
7516 | return Ok{};{auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }} |
7517 | })){auto tryResult946 = (CollectEachInRange( mFileInfoEntries, [ &update](const auto& entry) -> Result<Ok, nsresult > { const auto delta = entry.GetData()->Delta(); if (delta ) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert (std::is_empty_v<typename decltype(tryResult945)::ok_type> ); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla ::dom::quota::HandleError("update(entry.GetKey(), delta)", tryResult945 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7513, mozilla::dom::quota::Severity::Error); return tryResult945 .propagateErr(); }}; } return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult946)::ok_type>); if ((__builtin_expect (!!(tryResult946.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( mFileInfoEntries, [&update](const auto& entry) -> Result<Ok, nsresult> { const auto delta = entry.GetData()->Delta(); if (delta) { {auto tryResult945 = (update(entry.GetKey(), delta)); static_assert(std::is_empty_v<typename decltype(tryResult945)::ok_type>); if ((__builtin_expect(!!(tryResult945.isErr()), 0))) { mozilla::dom::quota::HandleError(\"update(entry.GetKey(), delta)\", tryResult945.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 7513, mozilla::dom::quota::Severity::Error); return tryResult945.propagateErr(); }}; } return Ok{}; })" , tryResult946.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7517, mozilla::dom::quota::Severity::Error); return tryResult946 .propagateErr(); }}; |
7518 | |
7519 | QM_TRY(MOZ_TO_RESULT(CreateJournals())){auto tryResult947 = (ToResult(CreateJournals())); static_assert (std::is_empty_v<typename decltype(tryResult947)::ok_type> ); if ((__builtin_expect(!!(tryResult947.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(CreateJournals())", tryResult947 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7519, mozilla::dom::quota::Severity::Error); return tryResult947 .propagateErr(); }}; |
7520 | |
7521 | return NS_OK; |
7522 | } |
7523 | |
7524 | void DatabaseConnection::UpdateRefcountFunction::DidCommit() { |
7525 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7525); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7525; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7526 | mConnection->AssertIsOnConnectionThread(); |
7527 | |
7528 | AUTO_PROFILER_LABEL("DatabaseConnection::UpdateRefcountFunction::DidCommit",mozilla::AutoProfilerLabel raiiObject7529( "DatabaseConnection::UpdateRefcountFunction::DidCommit" , nullptr, JS::ProfilingCategoryPair::DOM) |
7529 | DOM)mozilla::AutoProfilerLabel raiiObject7529( "DatabaseConnection::UpdateRefcountFunction::DidCommit" , nullptr, JS::ProfilingCategoryPair::DOM); |
7530 | |
7531 | for (const auto& entry : mFileInfoEntries.Values()) { |
7532 | entry->MaybeUpdateDBRefs(); |
7533 | } |
7534 | |
7535 | QM_WARNONLY_TRY(QM_TO_RESULT(RemoveJournals(mJournalsToRemoveAfterCommit))){auto tryResult948 = (ToResult<QMResult>(RemoveJournals (mJournalsToRemoveAfterCommit))); static_assert(std::is_empty_v <typename decltype(tryResult948)::ok_type>); if ((__builtin_expect (!!(tryResult948.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult<QMResult>(RemoveJournals(mJournalsToRemoveAfterCommit))" , tryResult948.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7535, mozilla::dom::quota::Severity::Warning); }}; |
7536 | } |
7537 | |
7538 | void DatabaseConnection::UpdateRefcountFunction::DidAbort() { |
7539 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7539); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7539; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7540 | mConnection->AssertIsOnConnectionThread(); |
7541 | |
7542 | AUTO_PROFILER_LABEL("DatabaseConnection::UpdateRefcountFunction::DidAbort",mozilla::AutoProfilerLabel raiiObject7543( "DatabaseConnection::UpdateRefcountFunction::DidAbort" , nullptr, JS::ProfilingCategoryPair::DOM) |
7543 | DOM)mozilla::AutoProfilerLabel raiiObject7543( "DatabaseConnection::UpdateRefcountFunction::DidAbort" , nullptr, JS::ProfilingCategoryPair::DOM); |
7544 | |
7545 | QM_WARNONLY_TRY(QM_TO_RESULT(RemoveJournals(mJournalsToRemoveAfterAbort))){auto tryResult949 = (ToResult<QMResult>(RemoveJournals (mJournalsToRemoveAfterAbort))); static_assert(std::is_empty_v <typename decltype(tryResult949)::ok_type>); if ((__builtin_expect (!!(tryResult949.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult<QMResult>(RemoveJournals(mJournalsToRemoveAfterAbort))" , tryResult949.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7545, mozilla::dom::quota::Severity::Warning); }}; |
7546 | } |
7547 | |
7548 | void DatabaseConnection::UpdateRefcountFunction::StartSavepoint() { |
7549 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7549); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7549; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7550 | mConnection->AssertIsOnConnectionThread(); |
7551 | MOZ_ASSERT(!mInSavepoint)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInSavepoint)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInSavepoint))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInSavepoint", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7551); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInSavepoint" ")"); do { *((volatile int*)__null) = 7551; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7552 | MOZ_ASSERT(!mSavepointEntriesIndex.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mSavepointEntriesIndex.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mSavepointEntriesIndex.Count ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mSavepointEntriesIndex.Count()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7552); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mSavepointEntriesIndex.Count()" ")"); do { *((volatile int*)__null) = 7552; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7553 | |
7554 | mInSavepoint = true; |
7555 | } |
7556 | |
7557 | void DatabaseConnection::UpdateRefcountFunction::ReleaseSavepoint() { |
7558 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7558); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7558; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7559 | mConnection->AssertIsOnConnectionThread(); |
7560 | MOZ_ASSERT(mInSavepoint)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInSavepoint)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInSavepoint))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInSavepoint", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7560); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInSavepoint" ")"); do { *((volatile int*)__null) = 7560; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7561 | |
7562 | mSavepointEntriesIndex.Clear(); |
7563 | mInSavepoint = false; |
7564 | } |
7565 | |
7566 | void DatabaseConnection::UpdateRefcountFunction::RollbackSavepoint() { |
7567 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7567); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7567; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7568 | mConnection->AssertIsOnConnectionThread(); |
7569 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7569); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 7569; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7570 | MOZ_ASSERT(mInSavepoint)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInSavepoint)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInSavepoint))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInSavepoint", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7570); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInSavepoint" ")"); do { *((volatile int*)__null) = 7570; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7571 | |
7572 | for (const auto& entry : mSavepointEntriesIndex.Values()) { |
7573 | entry->DecBySavepointDelta(); |
7574 | } |
7575 | |
7576 | mInSavepoint = false; |
7577 | mSavepointEntriesIndex.Clear(); |
7578 | } |
7579 | |
7580 | void DatabaseConnection::UpdateRefcountFunction::Reset() { |
7581 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7581); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7581; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7582 | mConnection->AssertIsOnConnectionThread(); |
7583 | MOZ_ASSERT(!mSavepointEntriesIndex.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mSavepointEntriesIndex.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mSavepointEntriesIndex.Count ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mSavepointEntriesIndex.Count()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7583); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mSavepointEntriesIndex.Count()" ")"); do { *((volatile int*)__null) = 7583; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7584 | MOZ_ASSERT(!mInSavepoint)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInSavepoint)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInSavepoint))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInSavepoint", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7584); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInSavepoint" ")"); do { *((volatile int*)__null) = 7584; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7585 | |
7586 | mJournalsToCreateBeforeCommit.Clear(); |
7587 | mJournalsToRemoveAfterCommit.Clear(); |
7588 | mJournalsToRemoveAfterAbort.Clear(); |
7589 | |
7590 | // DatabaseFileInfo implementation automatically removes unreferenced files, |
7591 | // but it's done asynchronously and with a delay. We want to remove them (and |
7592 | // decrease quota usage) before we fire the commit event. |
7593 | for (const auto& entry : mFileInfoEntries.Values()) { |
7594 | // We need to move mFileInfo into a raw pointer in order to release it |
7595 | // explicitly with aSyncDeleteFile == true. |
7596 | DatabaseFileInfo* const fileInfo = entry->ReleaseFileInfo().forget().take(); |
7597 | MOZ_ASSERT(fileInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(fileInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(fileInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("fileInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7597); AnnotateMozCrashReason("MOZ_ASSERT" "(" "fileInfo" ")" ); do { *((volatile int*)__null) = 7597; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7598 | |
7599 | fileInfo->Release(/* aSyncDeleteFile */ true); |
7600 | } |
7601 | |
7602 | mFileInfoEntries.Clear(); |
7603 | } |
7604 | |
7605 | nsresult DatabaseConnection::UpdateRefcountFunction::ProcessValue( |
7606 | mozIStorageValueArray* aValues, int32_t aIndex, UpdateType aUpdateType) { |
7607 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7607); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7607; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7608 | mConnection->AssertIsOnConnectionThread(); |
7609 | MOZ_ASSERT(aValues)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aValues)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aValues))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aValues", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7609); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aValues" ")" ); do { *((volatile int*)__null) = 7609; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7610 | |
7611 | AUTO_PROFILER_LABEL(mozilla::AutoProfilerLabel raiiObject7612( "DatabaseConnection::UpdateRefcountFunction::ProcessValue" , nullptr, JS::ProfilingCategoryPair::DOM) |
7612 | "DatabaseConnection::UpdateRefcountFunction::ProcessValue", DOM)mozilla::AutoProfilerLabel raiiObject7612( "DatabaseConnection::UpdateRefcountFunction::ProcessValue" , nullptr, JS::ProfilingCategoryPair::DOM); |
7613 | |
7614 | QM_TRY_INSPECT(const int32_t& type,auto tryResult950 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, aIndex)); if ((__builtin_expect(!!(tryResult950 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, aIndex)" , tryResult950.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7615, mozilla::dom::quota::Severity::Error); return tryResult950 .propagateErr(); } const int32_t& type = tryResult950.inspect (); |
7615 | MOZ_TO_RESULT_INVOKE_MEMBER(aValues, GetTypeOfIndex, aIndex))auto tryResult950 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, aIndex)); if ((__builtin_expect(!!(tryResult950 .isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, aIndex)" , tryResult950.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7615, mozilla::dom::quota::Severity::Error); return tryResult950 .propagateErr(); } const int32_t& type = tryResult950.inspect ();; |
7616 | |
7617 | if (type == mozIStorageValueArray::VALUE_TYPE_NULL) { |
7618 | return NS_OK; |
7619 | } |
7620 | |
7621 | QM_TRY_INSPECT(const auto& ids, MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult951 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (aValues)>::GetString), (aValues), aIndex)); if ((__builtin_expect (!!(tryResult951.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aValues)>::GetString), (aValues), aIndex)" , tryResult951.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7622, mozilla::dom::quota::Severity::Error); return tryResult951 .propagateErr(); } const auto& ids = tryResult951.inspect (); |
7622 | nsString, aValues, GetString, aIndex))auto tryResult951 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (aValues)>::GetString), (aValues), aIndex)); if ((__builtin_expect (!!(tryResult951.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aValues)>::GetString), (aValues), aIndex)" , tryResult951.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7622, mozilla::dom::quota::Severity::Error); return tryResult951 .propagateErr(); } const auto& ids = tryResult951.inspect ();; |
7623 | |
7624 | QM_TRY_INSPECT(const auto& files,auto tryResult952 = (DeserializeStructuredCloneFiles(mFileManager , ids)); if ((__builtin_expect(!!(tryResult952.isErr()), 0))) { mozilla::dom::quota::HandleError("DeserializeStructuredCloneFiles(mFileManager, ids)" , tryResult952.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7625, mozilla::dom::quota::Severity::Error); return tryResult952 .propagateErr(); } const auto& files = tryResult952.inspect (); |
7625 | DeserializeStructuredCloneFiles(mFileManager, ids))auto tryResult952 = (DeserializeStructuredCloneFiles(mFileManager , ids)); if ((__builtin_expect(!!(tryResult952.isErr()), 0))) { mozilla::dom::quota::HandleError("DeserializeStructuredCloneFiles(mFileManager, ids)" , tryResult952.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7625, mozilla::dom::quota::Severity::Error); return tryResult952 .propagateErr(); } const auto& files = tryResult952.inspect ();; |
7626 | |
7627 | for (const StructuredCloneFileParent& file : files) { |
7628 | const int64_t id = file.FileInfo().Id(); |
7629 | MOZ_ASSERT(id > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(id > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(id > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("id > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7629); AnnotateMozCrashReason("MOZ_ASSERT" "(" "id > 0" ")" ); do { *((volatile int*)__null) = 7629; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7630 | |
7631 | const auto entry = |
7632 | WrapNotNull(mFileInfoEntries.GetOrInsertNew(id, file.FileInfoPtr())); |
7633 | |
7634 | if (mInSavepoint) { |
7635 | mSavepointEntriesIndex.InsertOrUpdate(id, entry); |
7636 | } |
7637 | |
7638 | switch (aUpdateType) { |
7639 | case UpdateType::Increment: |
7640 | entry->IncDeltas(mInSavepoint); |
7641 | break; |
7642 | case UpdateType::Decrement: |
7643 | entry->DecDeltas(mInSavepoint); |
7644 | break; |
7645 | default: |
7646 | MOZ_CRASH("Unknown update type!")do { do { } while (false); MOZ_ReportCrash("" "Unknown update type!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7646); AnnotateMozCrashReason("MOZ_CRASH(" "Unknown update type!" ")"); do { *((volatile int*)__null) = 7646; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
7647 | } |
7648 | } |
7649 | |
7650 | return NS_OK; |
7651 | } |
7652 | |
7653 | nsresult DatabaseConnection::UpdateRefcountFunction::CreateJournals() { |
7654 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7654); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7654; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7655 | mConnection->AssertIsOnConnectionThread(); |
7656 | |
7657 | AUTO_PROFILER_LABEL(mozilla::AutoProfilerLabel raiiObject7658( "DatabaseConnection::UpdateRefcountFunction::CreateJournals" , nullptr, JS::ProfilingCategoryPair::DOM) |
7658 | "DatabaseConnection::UpdateRefcountFunction::CreateJournals", DOM)mozilla::AutoProfilerLabel raiiObject7658( "DatabaseConnection::UpdateRefcountFunction::CreateJournals" , nullptr, JS::ProfilingCategoryPair::DOM); |
7659 | |
7660 | const nsCOMPtr<nsIFile> journalDirectory = mFileManager.GetJournalDirectory(); |
7661 | QM_TRY(OkIf(journalDirectory), NS_ERROR_FAILURE){auto tryResult953 = (OkIf(journalDirectory)); static_assert( std::is_empty_v<typename decltype(tryResult953)::ok_type> ); if ((__builtin_expect(!!(tryResult953.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult953.unwrapErr (); mozilla::dom::quota::HandleError("OkIf(journalDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7661, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(journalDirectory)" , tryTempError, NS_ERROR_FAILURE); }}; |
7662 | |
7663 | for (const int64_t id : mJournalsToCreateBeforeCommit) { |
7664 | const nsCOMPtr<nsIFile> file = |
7665 | DatabaseFileManager::GetFileForId(journalDirectory, id); |
7666 | QM_TRY(OkIf(file), NS_ERROR_FAILURE){auto tryResult954 = (OkIf(file)); static_assert(std::is_empty_v <typename decltype(tryResult954)::ok_type>); if ((__builtin_expect (!!(tryResult954.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult954.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(file)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7666, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(file)", tryTempError , NS_ERROR_FAILURE); }}; |
7667 | |
7668 | QM_TRY(MOZ_TO_RESULT(file->Create(nsIFile::NORMAL_FILE_TYPE, 0644))){auto tryResult955 = (ToResult(file->Create(nsIFile::NORMAL_FILE_TYPE , 0644))); static_assert(std::is_empty_v<typename decltype (tryResult955)::ok_type>); if ((__builtin_expect(!!(tryResult955 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(file->Create(nsIFile::NORMAL_FILE_TYPE, 0644))" , tryResult955.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7668, mozilla::dom::quota::Severity::Error); return tryResult955 .propagateErr(); }}; |
7669 | |
7670 | mJournalsToRemoveAfterAbort.AppendElement(id); |
7671 | } |
7672 | |
7673 | return NS_OK; |
7674 | } |
7675 | |
7676 | nsresult DatabaseConnection::UpdateRefcountFunction::RemoveJournals( |
7677 | const nsTArray<int64_t>& aJournals) { |
7678 | MOZ_ASSERT(mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7678); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnection" ")"); do { *((volatile int*)__null) = 7678; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7679 | mConnection->AssertIsOnConnectionThread(); |
7680 | |
7681 | AUTO_PROFILER_LABEL(mozilla::AutoProfilerLabel raiiObject7682( "DatabaseConnection::UpdateRefcountFunction::RemoveJournals" , nullptr, JS::ProfilingCategoryPair::DOM) |
7682 | "DatabaseConnection::UpdateRefcountFunction::RemoveJournals", DOM)mozilla::AutoProfilerLabel raiiObject7682( "DatabaseConnection::UpdateRefcountFunction::RemoveJournals" , nullptr, JS::ProfilingCategoryPair::DOM); |
7683 | |
7684 | nsCOMPtr<nsIFile> journalDirectory = mFileManager.GetJournalDirectory(); |
7685 | QM_TRY(OkIf(journalDirectory), NS_ERROR_FAILURE){auto tryResult956 = (OkIf(journalDirectory)); static_assert( std::is_empty_v<typename decltype(tryResult956)::ok_type> ); if ((__builtin_expect(!!(tryResult956.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult956.unwrapErr (); mozilla::dom::quota::HandleError("OkIf(journalDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7685, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(journalDirectory)" , tryTempError, NS_ERROR_FAILURE); }}; |
7686 | |
7687 | for (const auto& journal : aJournals) { |
7688 | nsCOMPtr<nsIFile> file = |
7689 | DatabaseFileManager::GetFileForId(journalDirectory, journal); |
7690 | QM_TRY(OkIf(file), NS_ERROR_FAILURE){auto tryResult957 = (OkIf(file)); static_assert(std::is_empty_v <typename decltype(tryResult957)::ok_type>); if ((__builtin_expect (!!(tryResult957.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult957.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(file)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7690, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(file)", tryTempError , NS_ERROR_FAILURE); }}; |
7691 | |
7692 | QM_WARNONLY_TRY(QM_TO_RESULT(file->Remove(false))){auto tryResult958 = (ToResult<QMResult>(file->Remove (false))); static_assert(std::is_empty_v<typename decltype (tryResult958)::ok_type>); if ((__builtin_expect(!!(tryResult958 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult<QMResult>(file->Remove(false))" , tryResult958.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7692, mozilla::dom::quota::Severity::Warning); }}; |
7693 | } |
7694 | |
7695 | return NS_OK; |
7696 | } |
7697 | |
7698 | NS_IMPL_ISUPPORTS(DatabaseConnection::UpdateRefcountFunction,MozExternalRefCountType DatabaseConnection::UpdateRefcountFunction ::AddRef(void) { static_assert(!std::is_destructible_v<DatabaseConnection ::UpdateRefcountFunction>, "Reference-counted class " "DatabaseConnection::UpdateRefcountFunction" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 7699; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType <decltype("DatabaseConnection::UpdateRefcountFunction" != nullptr )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!("DatabaseConnection::UpdateRefcountFunction" != nullptr ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" " (" "Must specify a name" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" ") (" "Must specify a name" ")"); do { *((volatile int*)__null ) = 7699; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); if (!mRefCnt.isThreadSafe) _mOwningThread .AssertOwnership("DatabaseConnection::UpdateRefcountFunction" " not thread-safe"); nsrefcnt count = ++mRefCnt; NS_LogAddRef ((this), (count), ("DatabaseConnection::UpdateRefcountFunction" ), (uint32_t)(sizeof(*this))); return count; } MozExternalRefCountType DatabaseConnection::UpdateRefcountFunction::Release(void) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 7699 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType <decltype("DatabaseConnection::UpdateRefcountFunction" != nullptr )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!("DatabaseConnection::UpdateRefcountFunction" != nullptr ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" " (" "Must specify a name" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" ") (" "Must specify a name" ")"); do { *((volatile int*)__null ) = 7699; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); if (!mRefCnt.isThreadSafe) _mOwningThread .AssertOwnership("DatabaseConnection::UpdateRefcountFunction" " not thread-safe"); const char* const nametmp = "DatabaseConnection::UpdateRefcountFunction" ; nsrefcnt count = --mRefCnt; NS_LogRelease((this), (count), ( nametmp)); if (count == 0) { mRefCnt = 1; delete (this); return 0; } return count; } nsresult DatabaseConnection::UpdateRefcountFunction ::QueryInterface(const nsIID& aIID, void** aInstancePtr) { do { if (!(aInstancePtr)) { NS_DebugBreak(NS_DEBUG_ASSERTION , "QueryInterface requires a non-NULL destination!", "aInstancePtr" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); MOZ_PretendNoReturn(); } } while (0); nsresult rv = NS_ERROR_FAILURE ; static_assert(1 > 0, "Need more arguments to NS_INTERFACE_TABLE" ); static const QITableEntry table[] = { {&mozilla::detail ::kImplementedIID<DatabaseConnection::UpdateRefcountFunction , mozIStorageFunction>, int32_t( reinterpret_cast<char* >(static_cast<mozIStorageFunction*>((DatabaseConnection ::UpdateRefcountFunction*)0x1000)) - reinterpret_cast<char *>((DatabaseConnection::UpdateRefcountFunction*)0x1000))}, {&mozilla::detail::kImplementedIID<DatabaseConnection ::UpdateRefcountFunction, nsISupports>, int32_t(reinterpret_cast <char*>(static_cast<nsISupports*>( static_cast< mozIStorageFunction*>((DatabaseConnection::UpdateRefcountFunction *)0x1000))) - reinterpret_cast<char*>((DatabaseConnection ::UpdateRefcountFunction*)0x1000))}, { nullptr, 0 } } ; static_assert (std::size(table) > 1, "need at least 1 interface"); rv = NS_TableDrivenQI (static_cast<void*>(this), aIID, aInstancePtr, table); return rv; } |
7699 | mozIStorageFunction)MozExternalRefCountType DatabaseConnection::UpdateRefcountFunction ::AddRef(void) { static_assert(!std::is_destructible_v<DatabaseConnection ::UpdateRefcountFunction>, "Reference-counted class " "DatabaseConnection::UpdateRefcountFunction" " should not have a public destructor. " "Make this class's destructor non-public" ); do { static_assert( mozilla::detail::AssertionConditionType <decltype(int32_t(mRefCnt) >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) >= 0" " (" "illegal refcnt" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) >= 0" ") (" "illegal refcnt" ")"); do { *((volatile int*)__null) = 7699; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType <decltype("DatabaseConnection::UpdateRefcountFunction" != nullptr )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!("DatabaseConnection::UpdateRefcountFunction" != nullptr ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" " (" "Must specify a name" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" ") (" "Must specify a name" ")"); do { *((volatile int*)__null ) = 7699; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); if (!mRefCnt.isThreadSafe) _mOwningThread .AssertOwnership("DatabaseConnection::UpdateRefcountFunction" " not thread-safe"); nsrefcnt count = ++mRefCnt; NS_LogAddRef ((this), (count), ("DatabaseConnection::UpdateRefcountFunction" ), (uint32_t)(sizeof(*this))); return count; } MozExternalRefCountType DatabaseConnection::UpdateRefcountFunction::Release(void) { do { static_assert( mozilla::detail::AssertionConditionType< decltype(int32_t(mRefCnt) > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(int32_t(mRefCnt) > 0))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("int32_t(mRefCnt) > 0" " (" "dup release" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "int32_t(mRefCnt) > 0" ") (" "dup release" ")"); do { *((volatile int*)__null) = 7699 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType <decltype("DatabaseConnection::UpdateRefcountFunction" != nullptr )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!("DatabaseConnection::UpdateRefcountFunction" != nullptr ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" " (" "Must specify a name" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "\"DatabaseConnection::UpdateRefcountFunction\" != nullptr" ") (" "Must specify a name" ")"); do { *((volatile int*)__null ) = 7699; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); if (!mRefCnt.isThreadSafe) _mOwningThread .AssertOwnership("DatabaseConnection::UpdateRefcountFunction" " not thread-safe"); const char* const nametmp = "DatabaseConnection::UpdateRefcountFunction" ; nsrefcnt count = --mRefCnt; NS_LogRelease((this), (count), ( nametmp)); if (count == 0) { mRefCnt = 1; delete (this); return 0; } return count; } nsresult DatabaseConnection::UpdateRefcountFunction ::QueryInterface(const nsIID& aIID, void** aInstancePtr) { do { if (!(aInstancePtr)) { NS_DebugBreak(NS_DEBUG_ASSERTION , "QueryInterface requires a non-NULL destination!", "aInstancePtr" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7699); MOZ_PretendNoReturn(); } } while (0); nsresult rv = NS_ERROR_FAILURE ; static_assert(1 > 0, "Need more arguments to NS_INTERFACE_TABLE" ); static const QITableEntry table[] = { {&mozilla::detail ::kImplementedIID<DatabaseConnection::UpdateRefcountFunction , mozIStorageFunction>, int32_t( reinterpret_cast<char* >(static_cast<mozIStorageFunction*>((DatabaseConnection ::UpdateRefcountFunction*)0x1000)) - reinterpret_cast<char *>((DatabaseConnection::UpdateRefcountFunction*)0x1000))}, {&mozilla::detail::kImplementedIID<DatabaseConnection ::UpdateRefcountFunction, nsISupports>, int32_t(reinterpret_cast <char*>(static_cast<nsISupports*>( static_cast< mozIStorageFunction*>((DatabaseConnection::UpdateRefcountFunction *)0x1000))) - reinterpret_cast<char*>((DatabaseConnection ::UpdateRefcountFunction*)0x1000))}, { nullptr, 0 } } ; static_assert (std::size(table) > 1, "need at least 1 interface"); rv = NS_TableDrivenQI (static_cast<void*>(this), aIID, aInstancePtr, table); return rv; } |
7700 | |
7701 | NS_IMETHODIMPnsresult |
7702 | DatabaseConnection::UpdateRefcountFunction::OnFunctionCall( |
7703 | mozIStorageValueArray* aValues, nsIVariant** _retval) { |
7704 | MOZ_ASSERT(aValues)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aValues)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aValues))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aValues", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7704); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aValues" ")" ); do { *((volatile int*)__null) = 7704; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7705 | MOZ_ASSERT(_retval)do { static_assert( mozilla::detail::AssertionConditionType< decltype(_retval)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(_retval))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("_retval", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7705); AnnotateMozCrashReason("MOZ_ASSERT" "(" "_retval" ")" ); do { *((volatile int*)__null) = 7705; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7706 | |
7707 | AUTO_PROFILER_LABEL(mozilla::AutoProfilerLabel raiiObject7708( "DatabaseConnection::UpdateRefcountFunction::OnFunctionCall" , nullptr, JS::ProfilingCategoryPair::DOM) |
7708 | "DatabaseConnection::UpdateRefcountFunction::OnFunctionCall", DOM)mozilla::AutoProfilerLabel raiiObject7708( "DatabaseConnection::UpdateRefcountFunction::OnFunctionCall" , nullptr, JS::ProfilingCategoryPair::DOM); |
7709 | |
7710 | #ifdef DEBUG1 |
7711 | { |
7712 | QM_TRY_INSPECT(const uint32_t& numEntries,auto tryResult959 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetNumEntries)); if ((__builtin_expect(!!(tryResult959.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult959 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetNumEntries)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7714, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetNumEntries)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7714); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7714; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const uint32_t & numEntries = tryResult959.inspect(); |
7713 | MOZ_TO_RESULT_INVOKE_MEMBER(aValues, GetNumEntries),auto tryResult959 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetNumEntries)); if ((__builtin_expect(!!(tryResult959.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult959 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetNumEntries)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7714, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetNumEntries)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7714); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7714; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const uint32_t & numEntries = tryResult959.inspect(); |
7714 | QM_ASSERT_UNREACHABLE)auto tryResult959 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetNumEntries)); if ((__builtin_expect(!!(tryResult959.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult959 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetNumEntries)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7714, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetNumEntries)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7714); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7714; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const uint32_t & numEntries = tryResult959.inspect();; |
7715 | |
7716 | MOZ_ASSERT(numEntries == 2)do { static_assert( mozilla::detail::AssertionConditionType< decltype(numEntries == 2)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(numEntries == 2))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("numEntries == 2" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7716); AnnotateMozCrashReason("MOZ_ASSERT" "(" "numEntries == 2" ")"); do { *((volatile int*)__null) = 7716; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7717 | |
7718 | QM_TRY_INSPECT(const int32_t& type1,auto tryResult960 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, 0)); if ((__builtin_expect(!!(tryResult960. isErr()), 0))) { auto tryTempError __attribute__((__unused__) ) = tryResult960.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 0)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7720, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 0)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7720); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7720; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & type1 = tryResult960.inspect(); |
7719 | MOZ_TO_RESULT_INVOKE_MEMBER(aValues, GetTypeOfIndex, 0),auto tryResult960 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, 0)); if ((__builtin_expect(!!(tryResult960. isErr()), 0))) { auto tryTempError __attribute__((__unused__) ) = tryResult960.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 0)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7720, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 0)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7720); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7720; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & type1 = tryResult960.inspect(); |
7720 | QM_ASSERT_UNREACHABLE)auto tryResult960 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, 0)); if ((__builtin_expect(!!(tryResult960. isErr()), 0))) { auto tryTempError __attribute__((__unused__) ) = tryResult960.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 0)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7720, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 0)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7720); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7720; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & type1 = tryResult960.inspect();; |
7721 | |
7722 | QM_TRY_INSPECT(const int32_t& type2,auto tryResult961 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, 1)); if ((__builtin_expect(!!(tryResult961. isErr()), 0))) { auto tryTempError __attribute__((__unused__) ) = tryResult961.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 1)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7724, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 1)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7724); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7724; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & type2 = tryResult961.inspect(); |
7723 | MOZ_TO_RESULT_INVOKE_MEMBER(aValues, GetTypeOfIndex, 1),auto tryResult961 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, 1)); if ((__builtin_expect(!!(tryResult961. isErr()), 0))) { auto tryTempError __attribute__((__unused__) ) = tryResult961.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 1)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7724, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 1)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7724); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7724; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & type2 = tryResult961.inspect(); |
7724 | QM_ASSERT_UNREACHABLE)auto tryResult961 = (::mozilla::ToResultInvokeMember( (aValues ), &::mozilla::detail::DerefedType<decltype(aValues)> ::GetTypeOfIndex, 1)); if ((__builtin_expect(!!(tryResult961. isErr()), 0))) { auto tryTempError __attribute__((__unused__) ) = tryResult961.unwrapErr(); mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 1)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7724, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (aValues), &::mozilla::detail::DerefedType<decltype(aValues)>::GetTypeOfIndex, 1)" , tryTempError, [](const char*, const char*) -> ::mozilla:: GenericErrorResult<nsresult> { do { do { } while (false ); MOZ_ReportCrash("" "Should never be reached.", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7724); AnnotateMozCrashReason("MOZ_CRASH(" "Should never be reached." ")"); do { *((volatile int*)__null) = 7724; __attribute__((nomerge )) ::abort(); } while (false); } while (false); }); } const int32_t & type2 = tryResult961.inspect();; |
7725 | |
7726 | MOZ_ASSERT(!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL &&do { static_assert( mozilla::detail::AssertionConditionType< decltype(!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7727); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL)" ")"); do { *((volatile int*)__null) = 7727; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
7727 | type2 == mozIStorageValueArray::VALUE_TYPE_NULL))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7727); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!(type1 == mozIStorageValueArray::VALUE_TYPE_NULL && type2 == mozIStorageValueArray::VALUE_TYPE_NULL)" ")"); do { *((volatile int*)__null) = 7727; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7728 | } |
7729 | #endif |
7730 | |
7731 | QM_TRY(MOZ_TO_RESULT(ProcessValue(aValues, 0, UpdateType::Decrement))){auto tryResult962 = (ToResult(ProcessValue(aValues, 0, UpdateType ::Decrement))); static_assert(std::is_empty_v<typename decltype (tryResult962)::ok_type>); if ((__builtin_expect(!!(tryResult962 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(ProcessValue(aValues, 0, UpdateType::Decrement))" , tryResult962.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7731, mozilla::dom::quota::Severity::Error); return tryResult962 .propagateErr(); }}; |
7732 | |
7733 | QM_TRY(MOZ_TO_RESULT(ProcessValue(aValues, 1, UpdateType::Increment))){auto tryResult963 = (ToResult(ProcessValue(aValues, 1, UpdateType ::Increment))); static_assert(std::is_empty_v<typename decltype (tryResult963)::ok_type>); if ((__builtin_expect(!!(tryResult963 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(ProcessValue(aValues, 1, UpdateType::Increment))" , tryResult963.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7733, mozilla::dom::quota::Severity::Error); return tryResult963 .propagateErr(); }}; |
7734 | |
7735 | return NS_OK; |
7736 | } |
7737 | |
7738 | /******************************************************************************* |
7739 | * ConnectionPool implementation |
7740 | ******************************************************************************/ |
7741 | |
7742 | ConnectionPool::ConnectionPool() |
7743 | : mDatabasesMutex("ConnectionPool::mDatabasesMutex"), |
7744 | mIOTarget(MakeConnectionIOTarget()), |
7745 | mIdleTimer(NS_NewTimer()), |
7746 | mNextTransactionId(0) { |
7747 | AssertIsOnOwningThread(); |
7748 | AssertIsOnBackgroundThread(); |
7749 | MOZ_ASSERT(mIdleTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIdleTimer)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mIdleTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mIdleTimer", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7749); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleTimer" ")"); do { *((volatile int*)__null) = 7749; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7750 | } |
7751 | |
7752 | ConnectionPool::~ConnectionPool() { |
7753 | AssertIsOnOwningThread(); |
7754 | MOZ_ASSERT(mIdleDatabases.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIdleDatabases.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mIdleDatabases.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mIdleDatabases.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7754); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleDatabases.IsEmpty()" ")"); do { *((volatile int*)__null) = 7754; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7755 | MOZ_ASSERT(!mIdleTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mIdleTimer)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mIdleTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mIdleTimer", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7755); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mIdleTimer" ")"); do { *((volatile int*)__null) = 7755; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7756 | MOZ_ASSERT(mTargetIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mTargetIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mTargetIdleTime.IsNull()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mTargetIdleTime.IsNull()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7756); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mTargetIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 7756; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7757 | MOZ_ASSERT(!mDatabases.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabases.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDatabases.Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mDatabases.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7757); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabases.Count()" ")"); do { *((volatile int*)__null) = 7757; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7758 | MOZ_ASSERT(!mTransactions.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mTransactions.Count()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7758); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Count()" ")"); do { *((volatile int*)__null) = 7758; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7759 | MOZ_ASSERT(mQueuedTransactions.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mQueuedTransactions.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mQueuedTransactions.IsEmpty( )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mQueuedTransactions.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7759); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mQueuedTransactions.IsEmpty()" ")"); do { *((volatile int*)__null) = 7759; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7760 | MOZ_ASSERT(mCompleteCallbacks.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mCompleteCallbacks.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mCompleteCallbacks.IsEmpty() ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "mCompleteCallbacks.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7760); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCompleteCallbacks.IsEmpty()" ")"); do { *((volatile int*)__null) = 7760; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7761 | MOZ_ASSERT(mShutdownRequested)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mShutdownRequested)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mShutdownRequested))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mShutdownRequested" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7761); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mShutdownRequested" ")"); do { *((volatile int*)__null) = 7761; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7762 | MOZ_ASSERT(mShutdownComplete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mShutdownComplete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mShutdownComplete))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mShutdownComplete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7762); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mShutdownComplete" ")"); do { *((volatile int*)__null) = 7762; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7763 | } |
7764 | |
7765 | // static |
7766 | void ConnectionPool::IdleTimerCallback(nsITimer* aTimer, void* aClosure) { |
7767 | MOZ_ASSERT(aTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aTimer)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aTimer", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7767); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aTimer" ")" ); do { *((volatile int*)__null) = 7767; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7768 | MOZ_ASSERT(aClosure)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aClosure)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aClosure))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aClosure", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7768); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aClosure" ")" ); do { *((volatile int*)__null) = 7768; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7769 | |
7770 | AUTO_PROFILER_LABEL("ConnectionPool::IdleTimerCallback", DOM)mozilla::AutoProfilerLabel raiiObject7770( "ConnectionPool::IdleTimerCallback" , nullptr, JS::ProfilingCategoryPair::DOM); |
7771 | |
7772 | auto& self = *static_cast<ConnectionPool*>(aClosure); |
7773 | MOZ_ASSERT(self.mIdleTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(self.mIdleTimer)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(self.mIdleTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("self.mIdleTimer" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7773); AnnotateMozCrashReason("MOZ_ASSERT" "(" "self.mIdleTimer" ")"); do { *((volatile int*)__null) = 7773; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7774 | MOZ_ASSERT(SameCOMIdentity(self.mIdleTimer, aTimer))do { static_assert( mozilla::detail::AssertionConditionType< decltype(SameCOMIdentity(self.mIdleTimer, aTimer))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(SameCOMIdentity(self.mIdleTimer, aTimer)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("SameCOMIdentity(self.mIdleTimer, aTimer)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7774); AnnotateMozCrashReason("MOZ_ASSERT" "(" "SameCOMIdentity(self.mIdleTimer, aTimer)" ")"); do { *((volatile int*)__null) = 7774; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7775 | MOZ_ASSERT(!self.mTargetIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!self.mTargetIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!self.mTargetIdleTime.IsNull ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!self.mTargetIdleTime.IsNull()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7775); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!self.mTargetIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 7775; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7776 | |
7777 | self.mTargetIdleTime = TimeStamp(); |
7778 | |
7779 | // Cheat a little. |
7780 | const TimeStamp now = |
7781 | TimeStamp::NowLoRes() + TimeDuration::FromMilliseconds(500); |
7782 | |
7783 | // XXX Move this to ArrayAlgorithm.h? |
7784 | const auto removeUntil = [](auto& array, auto&& cond) { |
7785 | const auto begin = array.begin(), end = array.end(); |
7786 | array.RemoveElementsRange( |
7787 | begin, std::find_if(begin, end, std::forward<decltype(cond)>(cond))); |
7788 | }; |
7789 | |
7790 | removeUntil(self.mIdleDatabases, [now, &self](const auto& info) { |
7791 | if (now >= info.mIdleTime) { |
7792 | if ((*info.mDatabaseInfo)->mIdle) { |
7793 | self.PerformIdleDatabaseMaintenance(*info.mDatabaseInfo.ref()); |
7794 | } else { |
7795 | self.CloseDatabase(*info.mDatabaseInfo.ref()); |
7796 | } |
7797 | |
7798 | return false; |
7799 | } |
7800 | |
7801 | return true; |
7802 | }); |
7803 | |
7804 | self.AdjustIdleTimer(); |
7805 | } |
7806 | |
7807 | Result<RefPtr<DatabaseConnection>, nsresult> |
7808 | ConnectionPool::GetOrCreateConnection(const Database& aDatabase) { |
7809 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7809); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 7809; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7810 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7810); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 7810; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7811 | |
7812 | AUTO_PROFILER_LABEL("ConnectionPool::GetOrCreateConnection", DOM)mozilla::AutoProfilerLabel raiiObject7812( "ConnectionPool::GetOrCreateConnection" , nullptr, JS::ProfilingCategoryPair::DOM); |
7813 | |
7814 | DatabaseInfo* dbInfo; |
7815 | { |
7816 | MutexAutoLock lock(mDatabasesMutex); |
7817 | |
7818 | dbInfo = mDatabases.Get(aDatabase.Id()); |
7819 | } |
7820 | |
7821 | MOZ_ASSERT(dbInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(dbInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7821); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo" ")" ); do { *((volatile int*)__null) = 7821; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7822 | |
7823 | if (dbInfo->mConnection) { |
7824 | dbInfo->AssertIsOnConnectionThread(); |
7825 | |
7826 | return dbInfo->mConnection; |
7827 | } |
7828 | |
7829 | MOZ_ASSERT(!dbInfo->mDEBUGConnectionEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo->mDEBUGConnectionEventTarget)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!dbInfo->mDEBUGConnectionEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!dbInfo->mDEBUGConnectionEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7829); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo->mDEBUGConnectionEventTarget" ")"); do { *((volatile int*)__null) = 7829; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7830 | |
7831 | QM_TRY_UNWRAP(auto tryResult964 = (GetStorageConnection(aDatabase.FilePath( ), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase .MaybeKeyRef())); if ((__builtin_expect(!!(tryResult964.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetStorageConnection(aDatabase.FilePath(), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase.MaybeKeyRef())" , tryResult964.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7834, mozilla::dom::quota::Severity::Error); return tryResult964 .propagateErr(); } MovingNotNull<nsCOMPtr<mozIStorageConnection >> storageConnection = tryResult964.unwrap(); |
7832 | MovingNotNull<nsCOMPtr<mozIStorageConnection>> storageConnection,auto tryResult964 = (GetStorageConnection(aDatabase.FilePath( ), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase .MaybeKeyRef())); if ((__builtin_expect(!!(tryResult964.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetStorageConnection(aDatabase.FilePath(), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase.MaybeKeyRef())" , tryResult964.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7834, mozilla::dom::quota::Severity::Error); return tryResult964 .propagateErr(); } MovingNotNull<nsCOMPtr<mozIStorageConnection >> storageConnection = tryResult964.unwrap(); |
7833 | GetStorageConnection(aDatabase.FilePath(), aDatabase.DirectoryLockId(),auto tryResult964 = (GetStorageConnection(aDatabase.FilePath( ), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase .MaybeKeyRef())); if ((__builtin_expect(!!(tryResult964.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetStorageConnection(aDatabase.FilePath(), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase.MaybeKeyRef())" , tryResult964.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7834, mozilla::dom::quota::Severity::Error); return tryResult964 .propagateErr(); } MovingNotNull<nsCOMPtr<mozIStorageConnection >> storageConnection = tryResult964.unwrap(); |
7834 | aDatabase.TelemetryId(), aDatabase.MaybeKeyRef()))auto tryResult964 = (GetStorageConnection(aDatabase.FilePath( ), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase .MaybeKeyRef())); if ((__builtin_expect(!!(tryResult964.isErr ()), 0))) { mozilla::dom::quota::HandleError("GetStorageConnection(aDatabase.FilePath(), aDatabase.DirectoryLockId(), aDatabase.TelemetryId(), aDatabase.MaybeKeyRef())" , tryResult964.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7834, mozilla::dom::quota::Severity::Error); return tryResult964 .propagateErr(); } MovingNotNull<nsCOMPtr<mozIStorageConnection >> storageConnection = tryResult964.unwrap();; |
7835 | |
7836 | RefPtr<DatabaseConnection> connection = new DatabaseConnection( |
7837 | std::move(storageConnection), aDatabase.GetFileManagerPtr()); |
7838 | |
7839 | QM_TRY(MOZ_TO_RESULT(connection->Init())){auto tryResult965 = (ToResult(connection->Init())); static_assert (std::is_empty_v<typename decltype(tryResult965)::ok_type> ); if ((__builtin_expect(!!(tryResult965.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(connection->Init())", tryResult965 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7839, mozilla::dom::quota::Severity::Error); return tryResult965 .propagateErr(); }}; |
7840 | |
7841 | dbInfo->mConnection = connection; |
7842 | |
7843 | IDB_DEBUG_LOG(("ConnectionPool created connection 0x%p for '%s'", |
7844 | dbInfo->mConnection.get(), |
7845 | NS_ConvertUTF16toUTF8(aDatabase.FilePath()).get())); |
7846 | |
7847 | #ifdef DEBUG1 |
7848 | dbInfo->mDEBUGConnectionEventTarget = GetCurrentSerialEventTarget(); |
7849 | #endif |
7850 | |
7851 | return connection; |
7852 | } |
7853 | |
7854 | uint64_t ConnectionPool::Start( |
7855 | const nsID& aBackgroundChildLoggingId, const nsACString& aDatabaseId, |
7856 | int64_t aLoggingSerialNumber, const nsTArray<nsString>& aObjectStoreNames, |
7857 | bool aIsWriteTransaction, |
7858 | TransactionDatabaseOperationBase* aTransactionOp) { |
7859 | AssertIsOnOwningThread(); |
7860 | MOZ_ASSERT(!aDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseId.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseId.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7860); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 7860; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7861 | MOZ_ASSERT(mNextTransactionId < UINT64_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mNextTransactionId < (18446744073709551615UL))> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mNextTransactionId < (18446744073709551615UL)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mNextTransactionId < (18446744073709551615UL)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7861); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mNextTransactionId < (18446744073709551615UL)" ")"); do { *((volatile int*)__null) = 7861; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7862 | MOZ_ASSERT(!mShutdownRequested)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mShutdownRequested)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mShutdownRequested))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mShutdownRequested" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7862); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mShutdownRequested" ")"); do { *((volatile int*)__null) = 7862; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7863 | |
7864 | AUTO_PROFILER_LABEL("ConnectionPool::Start", DOM)mozilla::AutoProfilerLabel raiiObject7864( "ConnectionPool::Start" , nullptr, JS::ProfilingCategoryPair::DOM); |
7865 | |
7866 | const uint64_t transactionId = ++mNextTransactionId; |
7867 | |
7868 | // To avoid always acquiring a lock, we don't use WithEntryHandle here, which |
7869 | // would require a lock in any case. |
7870 | DatabaseInfo* dbInfo = mDatabases.Get(aDatabaseId); |
7871 | |
7872 | const bool databaseInfoIsNew = !dbInfo; |
7873 | |
7874 | if (databaseInfoIsNew) { |
7875 | MutexAutoLock lock(mDatabasesMutex); |
7876 | |
7877 | dbInfo = mDatabases |
7878 | .InsertOrUpdate(aDatabaseId, |
7879 | MakeUnique<DatabaseInfo>(this, aDatabaseId)) |
7880 | .get(); |
7881 | } |
7882 | |
7883 | MOZ_ASSERT(!mTransactions.Contains(transactionId))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Contains(transactionId))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mTransactions.Contains(transactionId)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Contains(transactionId)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7883); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Contains(transactionId)" ")"); do { *((volatile int*)__null) = 7883; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7884 | auto& transactionInfo = *mTransactions.InsertOrUpdate( |
7885 | transactionId, MakeUnique<TransactionInfo>( |
7886 | *dbInfo, aBackgroundChildLoggingId, aDatabaseId, |
7887 | transactionId, aLoggingSerialNumber, aObjectStoreNames, |
7888 | aIsWriteTransaction, aTransactionOp)); |
7889 | |
7890 | if (aIsWriteTransaction) { |
7891 | MOZ_ASSERT(dbInfo->mWriteTransactionCount < UINT32_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo->mWriteTransactionCount < (4294967295U) )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(dbInfo->mWriteTransactionCount < (4294967295U) ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "dbInfo->mWriteTransactionCount < (4294967295U)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7891); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo->mWriteTransactionCount < (4294967295U)" ")"); do { *((volatile int*)__null) = 7891; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7892 | dbInfo->mWriteTransactionCount++; |
7893 | } else { |
7894 | MOZ_ASSERT(dbInfo->mReadTransactionCount < UINT32_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo->mReadTransactionCount < (4294967295U)) >::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(dbInfo->mReadTransactionCount < (4294967295U)) )), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbInfo->mReadTransactionCount < (4294967295U)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7894); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo->mReadTransactionCount < (4294967295U)" ")"); do { *((volatile int*)__null) = 7894; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7895 | dbInfo->mReadTransactionCount++; |
7896 | } |
7897 | |
7898 | auto& blockingTransactions = dbInfo->mBlockingTransactions; |
7899 | |
7900 | for (const nsAString& objectStoreName : aObjectStoreNames) { |
7901 | TransactionInfoPair* blockInfo = |
7902 | blockingTransactions.GetOrInsertNew(objectStoreName); |
7903 | |
7904 | // Mark what we are blocking on. |
7905 | if (const auto maybeBlockingRead = blockInfo->mLastBlockingReads) { |
7906 | transactionInfo.mBlockedOn.Insert(&maybeBlockingRead.ref()); |
7907 | maybeBlockingRead->AddBlockingTransaction(transactionInfo); |
7908 | } |
7909 | |
7910 | if (aIsWriteTransaction) { |
7911 | for (const auto blockingWrite : blockInfo->mLastBlockingWrites) { |
7912 | transactionInfo.mBlockedOn.Insert(blockingWrite); |
7913 | blockingWrite->AddBlockingTransaction(transactionInfo); |
7914 | } |
7915 | |
7916 | blockInfo->mLastBlockingReads = SomeRef(transactionInfo); |
7917 | blockInfo->mLastBlockingWrites.Clear(); |
7918 | } else { |
7919 | blockInfo->mLastBlockingWrites.AppendElement( |
7920 | WrapNotNullUnchecked(&transactionInfo)); |
7921 | } |
7922 | } |
7923 | |
7924 | if (!transactionInfo.mBlockedOn.Count()) { |
7925 | Unused << ScheduleTransaction(transactionInfo, |
7926 | /* aFromQueuedTransactions */ false); |
7927 | } |
7928 | |
7929 | if (!databaseInfoIsNew && |
7930 | (mIdleDatabases.RemoveElement(dbInfo) || |
7931 | mDatabasesPerformingIdleMaintenance.RemoveElement(dbInfo))) { |
7932 | AdjustIdleTimer(); |
7933 | } |
7934 | |
7935 | return transactionId; |
7936 | } |
7937 | |
7938 | void ConnectionPool::Dispatch(uint64_t aTransactionId, nsIRunnable* aRunnable) { |
7939 | AssertIsOnOwningThread(); |
7940 | MOZ_ASSERT(aRunnable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aRunnable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aRunnable))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aRunnable", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7940); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aRunnable" ")" ); do { *((volatile int*)__null) = 7940; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7941 | |
7942 | AUTO_PROFILER_LABEL("ConnectionPool::Dispatch", DOM)mozilla::AutoProfilerLabel raiiObject7942( "ConnectionPool::Dispatch" , nullptr, JS::ProfilingCategoryPair::DOM); |
7943 | |
7944 | auto* const transactionInfo = mTransactions.Get(aTransactionId); |
7945 | MOZ_ASSERT(transactionInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(transactionInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(transactionInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("transactionInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7945); AnnotateMozCrashReason("MOZ_ASSERT" "(" "transactionInfo" ")"); do { *((volatile int*)__null) = 7945; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7946 | MOZ_ASSERT(!transactionInfo->mFinished)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!transactionInfo->mFinished)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!transactionInfo->mFinished ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "!transactionInfo->mFinished", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7946); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!transactionInfo->mFinished" ")"); do { *((volatile int*)__null) = 7946; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7947 | |
7948 | if (transactionInfo->mRunning) { |
7949 | DatabaseInfo& dbInfo = transactionInfo->mDatabaseInfo; |
7950 | MOZ_ASSERT(dbInfo.mEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo.mEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbInfo.mEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7950); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mEventTarget" ")"); do { *((volatile int*)__null) = 7950; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7951 | MOZ_ASSERT(!dbInfo.mClosing)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo.mClosing)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!dbInfo.mClosing))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!dbInfo.mClosing" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7951); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo.mClosing" ")"); do { *((volatile int*)__null) = 7951; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7952 | MOZ_ASSERT_IF(do { if (transactionInfo->mIsWriteTransaction) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(dbInfo. mRunningWriteTransaction && dbInfo.mRunningWriteTransaction .refEquals(*transactionInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7955); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" ")"); do { *((volatile int*)__null) = 7955; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
7953 | transactionInfo->mIsWriteTransaction,do { if (transactionInfo->mIsWriteTransaction) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(dbInfo. mRunningWriteTransaction && dbInfo.mRunningWriteTransaction .refEquals(*transactionInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7955); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" ")"); do { *((volatile int*)__null) = 7955; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
7954 | dbInfo.mRunningWriteTransaction &&do { if (transactionInfo->mIsWriteTransaction) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(dbInfo. mRunningWriteTransaction && dbInfo.mRunningWriteTransaction .refEquals(*transactionInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7955); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" ")"); do { *((volatile int*)__null) = 7955; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false) |
7955 | dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo))do { if (transactionInfo->mIsWriteTransaction) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(dbInfo. mRunningWriteTransaction && dbInfo.mRunningWriteTransaction .refEquals(*transactionInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7955); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mRunningWriteTransaction && dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)" ")"); do { *((volatile int*)__null) = 7955; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
7956 | |
7957 | MOZ_ALWAYS_SUCCEEDS(dbInfo.Dispatch(do_AddRef(aRunnable)))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (dbInfo.Dispatch(do_AddRef(aRunnable)))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(dbInfo.Dispatch(do_AddRef(aRunnable)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7957); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(dbInfo.Dispatch(do_AddRef(aRunnable)))" ")"); do { *((volatile int*)__null) = 7957; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
7958 | } else { |
7959 | transactionInfo->mQueuedRunnables.AppendElement(aRunnable); |
7960 | } |
7961 | } |
7962 | |
7963 | void ConnectionPool::Finish(uint64_t aTransactionId, |
7964 | FinishCallback* aCallback) { |
7965 | AssertIsOnOwningThread(); |
7966 | |
7967 | #ifdef DEBUG1 |
7968 | auto* const transactionInfo = mTransactions.Get(aTransactionId); |
7969 | MOZ_ASSERT(transactionInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(transactionInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(transactionInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("transactionInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7969); AnnotateMozCrashReason("MOZ_ASSERT" "(" "transactionInfo" ")"); do { *((volatile int*)__null) = 7969; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7970 | MOZ_ASSERT(!transactionInfo->mFinished)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!transactionInfo->mFinished)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!transactionInfo->mFinished ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "!transactionInfo->mFinished", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7970); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!transactionInfo->mFinished" ")"); do { *((volatile int*)__null) = 7970; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7971 | #endif |
7972 | |
7973 | AUTO_PROFILER_LABEL("ConnectionPool::Finish", DOM)mozilla::AutoProfilerLabel raiiObject7973( "ConnectionPool::Finish" , nullptr, JS::ProfilingCategoryPair::DOM); |
7974 | |
7975 | RefPtr<FinishCallbackWrapper> wrapper = |
7976 | new FinishCallbackWrapper(this, aTransactionId, aCallback); |
7977 | |
7978 | Dispatch(aTransactionId, wrapper); |
7979 | |
7980 | #ifdef DEBUG1 |
7981 | transactionInfo->mFinished.Flip(); |
7982 | #endif |
7983 | } |
7984 | |
7985 | void ConnectionPool::WaitForDatabaseToComplete(const nsCString& aDatabaseId, |
7986 | nsIRunnable* aCallback) { |
7987 | AssertIsOnOwningThread(); |
7988 | MOZ_ASSERT(!aDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseId.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseId.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7988); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 7988; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7989 | MOZ_ASSERT(aCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 7989); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCallback" ")" ); do { *((volatile int*)__null) = 7989; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
7990 | |
7991 | AUTO_PROFILER_LABEL("ConnectionPool::WaitForDatabaseToComplete", DOM)mozilla::AutoProfilerLabel raiiObject7991( "ConnectionPool::WaitForDatabaseToComplete" , nullptr, JS::ProfilingCategoryPair::DOM); |
7992 | |
7993 | if (!CloseDatabaseWhenIdleInternal(aDatabaseId)) { |
7994 | Unused << aCallback->Run(); |
7995 | return; |
7996 | } |
7997 | |
7998 | mCompleteCallbacks.EmplaceBack( |
7999 | MakeUnique<DatabaseCompleteCallback>(aDatabaseId, aCallback)); |
8000 | } |
8001 | |
8002 | void ConnectionPool::Shutdown() { |
8003 | AssertIsOnOwningThread(); |
8004 | MOZ_ASSERT(!mShutdownComplete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mShutdownComplete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mShutdownComplete))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mShutdownComplete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8004); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mShutdownComplete" ")"); do { *((volatile int*)__null) = 8004; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8005 | |
8006 | AUTO_PROFILER_LABEL("ConnectionPool::Shutdown", DOM)mozilla::AutoProfilerLabel raiiObject8006( "ConnectionPool::Shutdown" , nullptr, JS::ProfilingCategoryPair::DOM); |
8007 | |
8008 | mShutdownRequested.Flip(); |
8009 | |
8010 | CancelIdleTimer(); |
8011 | MOZ_ASSERT(mTargetIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mTargetIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mTargetIdleTime.IsNull()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mTargetIdleTime.IsNull()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8011); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mTargetIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 8011; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8012 | |
8013 | mIdleTimer = nullptr; |
8014 | |
8015 | CloseIdleDatabases(); |
8016 | |
8017 | if (!mDatabases.Count()) { |
8018 | MOZ_ASSERT(!mTransactions.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mTransactions.Count()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8018); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Count()" ")"); do { *((volatile int*)__null) = 8018; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8019 | |
8020 | Cleanup(); |
8021 | |
8022 | MOZ_ASSERT(mShutdownComplete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mShutdownComplete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mShutdownComplete))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mShutdownComplete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8022); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mShutdownComplete" ")"); do { *((volatile int*)__null) = 8022; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8023 | |
8024 | mIOTarget->Shutdown(); |
8025 | |
8026 | return; |
8027 | } |
8028 | |
8029 | MOZ_ALWAYS_TRUE(SpinEventLoopUntil("ConnectionPool::Shutdown"_ns, [&]() {do { if ((__builtin_expect(!!(SpinEventLoopUntil("ConnectionPool::Shutdown"_ns , [&]() { return static_cast<bool>(mShutdownComplete ); })), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "SpinEventLoopUntil(\"ConnectionPool::Shutdown\"_ns, [&]() { return static_cast<bool>(mShutdownComplete); })" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8031); AnnotateMozCrashReason("MOZ_CRASH(" "SpinEventLoopUntil(\"ConnectionPool::Shutdown\"_ns, [&]() { return static_cast<bool>(mShutdownComplete); })" ")"); do { *((volatile int*)__null) = 8031; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8030 | return static_cast<bool>(mShutdownComplete);do { if ((__builtin_expect(!!(SpinEventLoopUntil("ConnectionPool::Shutdown"_ns , [&]() { return static_cast<bool>(mShutdownComplete ); })), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "SpinEventLoopUntil(\"ConnectionPool::Shutdown\"_ns, [&]() { return static_cast<bool>(mShutdownComplete); })" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8031); AnnotateMozCrashReason("MOZ_CRASH(" "SpinEventLoopUntil(\"ConnectionPool::Shutdown\"_ns, [&]() { return static_cast<bool>(mShutdownComplete); })" ")"); do { *((volatile int*)__null) = 8031; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8031 | }))do { if ((__builtin_expect(!!(SpinEventLoopUntil("ConnectionPool::Shutdown"_ns , [&]() { return static_cast<bool>(mShutdownComplete ); })), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "SpinEventLoopUntil(\"ConnectionPool::Shutdown\"_ns, [&]() { return static_cast<bool>(mShutdownComplete); })" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8031); AnnotateMozCrashReason("MOZ_CRASH(" "SpinEventLoopUntil(\"ConnectionPool::Shutdown\"_ns, [&]() { return static_cast<bool>(mShutdownComplete); })" ")"); do { *((volatile int*)__null) = 8031; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8032 | |
8033 | mIOTarget->Shutdown(); |
8034 | } |
8035 | |
8036 | void ConnectionPool::Cleanup() { |
8037 | AssertIsOnOwningThread(); |
8038 | MOZ_ASSERT(mShutdownRequested)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mShutdownRequested)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mShutdownRequested))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mShutdownRequested" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8038); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mShutdownRequested" ")"); do { *((volatile int*)__null) = 8038; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8039 | MOZ_ASSERT(!mShutdownComplete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mShutdownComplete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mShutdownComplete))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mShutdownComplete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8039); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mShutdownComplete" ")"); do { *((volatile int*)__null) = 8039; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8040 | MOZ_ASSERT(!mDatabases.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabases.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDatabases.Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mDatabases.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8040); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabases.Count()" ")"); do { *((volatile int*)__null) = 8040; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8041 | MOZ_ASSERT(!mTransactions.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mTransactions.Count()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8041); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Count()" ")"); do { *((volatile int*)__null) = 8041; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8042 | |
8043 | AUTO_PROFILER_LABEL("ConnectionPool::Cleanup", DOM)mozilla::AutoProfilerLabel raiiObject8043( "ConnectionPool::Cleanup" , nullptr, JS::ProfilingCategoryPair::DOM); |
8044 | |
8045 | if (!mCompleteCallbacks.IsEmpty()) { |
8046 | // Run all callbacks manually now. |
8047 | |
8048 | { |
8049 | auto completeCallbacks = std::move(mCompleteCallbacks); |
8050 | for (const auto& completeCallback : completeCallbacks) { |
8051 | MOZ_ASSERT(completeCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(completeCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(completeCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("completeCallback" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8051); AnnotateMozCrashReason("MOZ_ASSERT" "(" "completeCallback" ")"); do { *((volatile int*)__null) = 8051; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8052 | MOZ_ASSERT(completeCallback->mCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(completeCallback->mCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(completeCallback->mCallback ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "completeCallback->mCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8052); AnnotateMozCrashReason("MOZ_ASSERT" "(" "completeCallback->mCallback" ")"); do { *((volatile int*)__null) = 8052; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8053 | |
8054 | Unused << completeCallback->mCallback->Run(); |
8055 | } |
8056 | |
8057 | // We expect no new callbacks being completed by running the existing |
8058 | // ones. |
8059 | MOZ_ASSERT(mCompleteCallbacks.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mCompleteCallbacks.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mCompleteCallbacks.IsEmpty() ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "mCompleteCallbacks.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8059); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCompleteCallbacks.IsEmpty()" ")"); do { *((volatile int*)__null) = 8059; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8060 | } |
8061 | |
8062 | // And make sure they get processed. |
8063 | nsIThread* currentThread = NS_GetCurrentThread(); |
8064 | MOZ_ASSERT(currentThread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(currentThread)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(currentThread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("currentThread", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8064); AnnotateMozCrashReason("MOZ_ASSERT" "(" "currentThread" ")"); do { *((volatile int*)__null) = 8064; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8065 | |
8066 | MOZ_ALWAYS_SUCCEEDS(NS_ProcessPendingEvents(currentThread))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (NS_ProcessPendingEvents(currentThread))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(NS_ProcessPendingEvents(currentThread))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8066); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(NS_ProcessPendingEvents(currentThread))" ")"); do { *((volatile int*)__null) = 8066; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8067 | } |
8068 | |
8069 | mShutdownComplete.Flip(); |
8070 | } |
8071 | |
8072 | void ConnectionPool::AdjustIdleTimer() { |
8073 | AssertIsOnOwningThread(); |
8074 | MOZ_ASSERT(mIdleTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIdleTimer)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mIdleTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mIdleTimer", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8074); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleTimer" ")"); do { *((volatile int*)__null) = 8074; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8075 | |
8076 | AUTO_PROFILER_LABEL("ConnectionPool::AdjustIdleTimer", DOM)mozilla::AutoProfilerLabel raiiObject8076( "ConnectionPool::AdjustIdleTimer" , nullptr, JS::ProfilingCategoryPair::DOM); |
8077 | |
8078 | // Figure out the next time at which we should release idle resources. This |
8079 | // includes both databases and threads. |
8080 | TimeStamp newTargetIdleTime; |
8081 | MOZ_ASSERT(newTargetIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(newTargetIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(newTargetIdleTime.IsNull())) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("newTargetIdleTime.IsNull()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8081); AnnotateMozCrashReason("MOZ_ASSERT" "(" "newTargetIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 8081; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8082 | |
8083 | if (!mIdleDatabases.IsEmpty()) { |
8084 | newTargetIdleTime = mIdleDatabases[0].mIdleTime; |
8085 | } |
8086 | |
8087 | MOZ_ASSERT_IF(newTargetIdleTime.IsNull(), mIdleDatabases.IsEmpty())do { if (newTargetIdleTime.IsNull()) { do { static_assert( mozilla ::detail::AssertionConditionType<decltype(mIdleDatabases.IsEmpty ())>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mIdleDatabases.IsEmpty()))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("mIdleDatabases.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8087); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleDatabases.IsEmpty()" ")"); do { *((volatile int*)__null) = 8087; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
8088 | |
8089 | // Cancel the timer if it was running and the new target time is different. |
8090 | if (!mTargetIdleTime.IsNull() && |
8091 | (newTargetIdleTime.IsNull() || mTargetIdleTime != newTargetIdleTime)) { |
8092 | CancelIdleTimer(); |
8093 | |
8094 | MOZ_ASSERT(mTargetIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mTargetIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mTargetIdleTime.IsNull()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mTargetIdleTime.IsNull()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8094); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mTargetIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 8094; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8095 | } |
8096 | |
8097 | // Schedule the timer if we have a target time different than before. |
8098 | if (!newTargetIdleTime.IsNull() && |
8099 | (mTargetIdleTime.IsNull() || mTargetIdleTime != newTargetIdleTime)) { |
8100 | double delta = (newTargetIdleTime - TimeStamp::NowLoRes()).ToMilliseconds(); |
8101 | |
8102 | uint32_t delay; |
8103 | if (delta > 0) { |
8104 | delay = uint32_t(std::min(delta, double(UINT32_MAX(4294967295U)))); |
8105 | } else { |
8106 | delay = 0; |
8107 | } |
8108 | |
8109 | MOZ_ALWAYS_SUCCEEDS(mIdleTimer->InitWithNamedFuncCallback(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, "ConnectionPool::IdleTimerCallback" ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, \"ConnectionPool::IdleTimerCallback\"))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8111); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, \"ConnectionPool::IdleTimerCallback\"))" ")"); do { *((volatile int*)__null) = 8111; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8110 | IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT,do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, "ConnectionPool::IdleTimerCallback" ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, \"ConnectionPool::IdleTimerCallback\"))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8111); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, \"ConnectionPool::IdleTimerCallback\"))" ")"); do { *((volatile int*)__null) = 8111; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8111 | "ConnectionPool::IdleTimerCallback"))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, "ConnectionPool::IdleTimerCallback" ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, \"ConnectionPool::IdleTimerCallback\"))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8111); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(mIdleTimer->InitWithNamedFuncCallback( IdleTimerCallback, this, delay, nsITimer::TYPE_ONE_SHOT, \"ConnectionPool::IdleTimerCallback\"))" ")"); do { *((volatile int*)__null) = 8111; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8112 | |
8113 | mTargetIdleTime = newTargetIdleTime; |
8114 | } |
8115 | } |
8116 | |
8117 | void ConnectionPool::CancelIdleTimer() { |
8118 | AssertIsOnOwningThread(); |
8119 | MOZ_ASSERT(mIdleTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIdleTimer)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mIdleTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mIdleTimer", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8119); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleTimer" ")"); do { *((volatile int*)__null) = 8119; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8120 | |
8121 | if (!mTargetIdleTime.IsNull()) { |
8122 | MOZ_ALWAYS_SUCCEEDS(mIdleTimer->Cancel())do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mIdleTimer->Cancel())), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(mIdleTimer->Cancel())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8122); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(mIdleTimer->Cancel())" ")"); do { *((volatile int*)__null) = 8122; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8123 | |
8124 | mTargetIdleTime = TimeStamp(); |
8125 | MOZ_ASSERT(mTargetIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mTargetIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mTargetIdleTime.IsNull()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mTargetIdleTime.IsNull()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8125); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mTargetIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 8125; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8126 | } |
8127 | } |
8128 | |
8129 | void ConnectionPool::CloseIdleDatabases() { |
8130 | AssertIsOnOwningThread(); |
8131 | MOZ_ASSERT(mShutdownRequested)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mShutdownRequested)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mShutdownRequested))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mShutdownRequested" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8131); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mShutdownRequested" ")"); do { *((volatile int*)__null) = 8131; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8132 | |
8133 | AUTO_PROFILER_LABEL("ConnectionPool::CloseIdleDatabases", DOM)mozilla::AutoProfilerLabel raiiObject8133( "ConnectionPool::CloseIdleDatabases" , nullptr, JS::ProfilingCategoryPair::DOM); |
8134 | |
8135 | if (!mIdleDatabases.IsEmpty()) { |
8136 | for (IdleDatabaseInfo& idleInfo : mIdleDatabases) { |
8137 | CloseDatabase(*idleInfo.mDatabaseInfo.ref()); |
8138 | } |
8139 | mIdleDatabases.Clear(); |
8140 | } |
8141 | |
8142 | if (!mDatabasesPerformingIdleMaintenance.IsEmpty()) { |
8143 | for (PerformingIdleMaintenanceDatabaseInfo& performingIdleMaintenanceInfo : |
8144 | mDatabasesPerformingIdleMaintenance) { |
8145 | CloseDatabase(*performingIdleMaintenanceInfo.mDatabaseInfo); |
8146 | } |
8147 | mDatabasesPerformingIdleMaintenance.Clear(); |
8148 | } |
8149 | } |
8150 | |
8151 | bool ConnectionPool::ScheduleTransaction(TransactionInfo& aTransactionInfo, |
8152 | bool aFromQueuedTransactions) { |
8153 | AssertIsOnOwningThread(); |
8154 | |
8155 | AUTO_PROFILER_LABEL("ConnectionPool::ScheduleTransaction", DOM)mozilla::AutoProfilerLabel raiiObject8155( "ConnectionPool::ScheduleTransaction" , nullptr, JS::ProfilingCategoryPair::DOM); |
8156 | |
8157 | DatabaseInfo& dbInfo = aTransactionInfo.mDatabaseInfo; |
8158 | |
8159 | dbInfo.mIdle = false; |
8160 | |
8161 | if (dbInfo.mClosing) { |
8162 | MOZ_ASSERT(!mIdleDatabases.Contains(&dbInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mIdleDatabases.Contains(&dbInfo))>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(! !(!mIdleDatabases.Contains(&dbInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mIdleDatabases.Contains(&dbInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8162); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mIdleDatabases.Contains(&dbInfo)" ")"); do { *((volatile int*)__null) = 8162; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8163 | MOZ_ASSERT(do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo.mTransactionsScheduledDuringClose.Contains(& aTransactionInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!dbInfo.mTransactionsScheduledDuringClose .Contains(&aTransactionInfo)))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("!dbInfo.mTransactionsScheduledDuringClose.Contains(&aTransactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8164); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo.mTransactionsScheduledDuringClose.Contains(&aTransactionInfo)" ")"); do { *((volatile int*)__null) = 8164; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
8164 | !dbInfo.mTransactionsScheduledDuringClose.Contains(&aTransactionInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo.mTransactionsScheduledDuringClose.Contains(& aTransactionInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!dbInfo.mTransactionsScheduledDuringClose .Contains(&aTransactionInfo)))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("!dbInfo.mTransactionsScheduledDuringClose.Contains(&aTransactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8164); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo.mTransactionsScheduledDuringClose.Contains(&aTransactionInfo)" ")"); do { *((volatile int*)__null) = 8164; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8165 | |
8166 | dbInfo.mTransactionsScheduledDuringClose.AppendElement( |
8167 | WrapNotNullUnchecked(&aTransactionInfo)); |
8168 | return true; |
8169 | } |
8170 | |
8171 | if (!dbInfo.mEventTarget) { |
8172 | const uint32_t serialNumber = SerialNumber(); |
8173 | const nsCString serialName = |
8174 | nsPrintfCString("IndexedDB #%" PRIu32"u", serialNumber); |
8175 | |
8176 | dbInfo.mEventTarget = |
8177 | TaskQueue::Create(do_AddRef(mIOTarget), serialName.get()); |
8178 | MOZ_ASSERT(dbInfo.mEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo.mEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbInfo.mEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8178); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mEventTarget" ")"); do { *((volatile int*)__null) = 8178; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8179 | IDB_DEBUG_LOG(("ConnectionPool created task queue %" PRIu32"u", serialNumber)); |
8180 | } |
8181 | |
8182 | // The number of active operations equals the number of databases minus idle |
8183 | // databases. The maximum number of database operations which can make |
8184 | // progress at the same time is kMaxConnectionThreadCount. If we are at this |
8185 | // limit, all idle processing is interrupted to make room for user |
8186 | // transactions. |
8187 | if (mDatabases.Count() >= |
8188 | (mIdleDatabases.Length() + kMaxConnectionThreadCount) && |
8189 | !mDatabasesPerformingIdleMaintenance.IsEmpty()) { |
8190 | const auto& busyDbs = mDatabasesPerformingIdleMaintenance; |
8191 | for (auto dbInfo = busyDbs.rbegin(); dbInfo != busyDbs.rend(); ++dbInfo) { |
8192 | (*dbInfo).mIdleConnectionRunnable->Interrupt(); |
8193 | } |
8194 | } |
8195 | |
8196 | if (aTransactionInfo.mIsWriteTransaction) { |
8197 | if (dbInfo.mRunningWriteTransaction) { |
8198 | // SQLite only allows one write transaction at a time so queue this |
8199 | // transaction for later. |
8200 | MOZ_ASSERT(do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8201); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo)" ")"); do { *((volatile int*)__null) = 8201; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
8201 | !dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8201); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo.mScheduledWriteTransactions.Contains(&aTransactionInfo)" ")"); do { *((volatile int*)__null) = 8201; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8202 | |
8203 | dbInfo.mScheduledWriteTransactions.AppendElement( |
8204 | WrapNotNullUnchecked(&aTransactionInfo)); |
8205 | return true; |
8206 | } |
8207 | |
8208 | dbInfo.mRunningWriteTransaction = SomeRef(aTransactionInfo); |
8209 | dbInfo.mNeedsCheckpoint = true; |
8210 | } |
8211 | |
8212 | MOZ_ASSERT(!aTransactionInfo.mRunning)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aTransactionInfo.mRunning)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aTransactionInfo.mRunning)) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aTransactionInfo.mRunning" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8212); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aTransactionInfo.mRunning" ")"); do { *((volatile int*)__null) = 8212; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8213 | aTransactionInfo.mRunning = true; |
8214 | |
8215 | nsTArray<nsCOMPtr<nsIRunnable>>& queuedRunnables = |
8216 | aTransactionInfo.mQueuedRunnables; |
8217 | |
8218 | if (!queuedRunnables.IsEmpty()) { |
8219 | for (auto& queuedRunnable : queuedRunnables) { |
8220 | MOZ_ALWAYS_SUCCEEDS(dbInfo.Dispatch(queuedRunnable.forget()))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (dbInfo.Dispatch(queuedRunnable.forget()))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(dbInfo.Dispatch(queuedRunnable.forget()))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8220); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(dbInfo.Dispatch(queuedRunnable.forget()))" ")"); do { *((volatile int*)__null) = 8220; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8221 | } |
8222 | |
8223 | queuedRunnables.Clear(); |
8224 | } |
8225 | |
8226 | return true; |
8227 | } |
8228 | |
8229 | void ConnectionPool::NoteFinishedTransaction(uint64_t aTransactionId) { |
8230 | AssertIsOnOwningThread(); |
8231 | |
8232 | AUTO_PROFILER_LABEL("ConnectionPool::NoteFinishedTransaction", DOM)mozilla::AutoProfilerLabel raiiObject8232( "ConnectionPool::NoteFinishedTransaction" , nullptr, JS::ProfilingCategoryPair::DOM); |
8233 | |
8234 | auto* const transactionInfo = mTransactions.Get(aTransactionId); |
8235 | MOZ_ASSERT(transactionInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(transactionInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(transactionInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("transactionInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8235); AnnotateMozCrashReason("MOZ_ASSERT" "(" "transactionInfo" ")"); do { *((volatile int*)__null) = 8235; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8236 | MOZ_ASSERT(transactionInfo->mRunning)do { static_assert( mozilla::detail::AssertionConditionType< decltype(transactionInfo->mRunning)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(transactionInfo->mRunning ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "transactionInfo->mRunning", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8236); AnnotateMozCrashReason("MOZ_ASSERT" "(" "transactionInfo->mRunning" ")"); do { *((volatile int*)__null) = 8236; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8237 | MOZ_ASSERT(transactionInfo->mFinished)do { static_assert( mozilla::detail::AssertionConditionType< decltype(transactionInfo->mFinished)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(transactionInfo->mFinished ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "transactionInfo->mFinished", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8237); AnnotateMozCrashReason("MOZ_ASSERT" "(" "transactionInfo->mFinished" ")"); do { *((volatile int*)__null) = 8237; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8238 | |
8239 | transactionInfo->mRunning = false; |
8240 | |
8241 | DatabaseInfo& dbInfo = transactionInfo->mDatabaseInfo; |
8242 | MOZ_ASSERT(mDatabases.Get(transactionInfo->mDatabaseId) == &dbInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabases.Get(transactionInfo->mDatabaseId) == & dbInfo)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mDatabases.Get(transactionInfo->mDatabaseId) == & dbInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mDatabases.Get(transactionInfo->mDatabaseId) == &dbInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8242); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabases.Get(transactionInfo->mDatabaseId) == &dbInfo" ")"); do { *((volatile int*)__null) = 8242; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8243 | MOZ_ASSERT(dbInfo.mEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo.mEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbInfo.mEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8243); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mEventTarget" ")"); do { *((volatile int*)__null) = 8243; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8244 | |
8245 | // Schedule the next write transaction if there are any queued. |
8246 | if (dbInfo.mRunningWriteTransaction && |
8247 | dbInfo.mRunningWriteTransaction.refEquals(*transactionInfo)) { |
8248 | MOZ_ASSERT(transactionInfo->mIsWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(transactionInfo->mIsWriteTransaction)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(transactionInfo->mIsWriteTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("transactionInfo->mIsWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8248); AnnotateMozCrashReason("MOZ_ASSERT" "(" "transactionInfo->mIsWriteTransaction" ")"); do { *((volatile int*)__null) = 8248; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8249 | MOZ_ASSERT(dbInfo.mNeedsCheckpoint)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo.mNeedsCheckpoint)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mNeedsCheckpoint))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("dbInfo.mNeedsCheckpoint" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8249); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mNeedsCheckpoint" ")"); do { *((volatile int*)__null) = 8249; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8250 | |
8251 | dbInfo.mRunningWriteTransaction = Nothing(); |
8252 | |
8253 | if (!dbInfo.mScheduledWriteTransactions.IsEmpty()) { |
8254 | const auto nextWriteTransaction = dbInfo.mScheduledWriteTransactions[0]; |
8255 | |
8256 | dbInfo.mScheduledWriteTransactions.RemoveElementAt(0); |
8257 | |
8258 | MOZ_ALWAYS_TRUE(ScheduleTransaction(*nextWriteTransaction,do { if ((__builtin_expect(!!(ScheduleTransaction(*nextWriteTransaction , false)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "ScheduleTransaction(*nextWriteTransaction, false)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8259); AnnotateMozCrashReason("MOZ_CRASH(" "ScheduleTransaction(*nextWriteTransaction, false)" ")"); do { *((volatile int*)__null) = 8259; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8259 | /* aFromQueuedTransactions */ false))do { if ((__builtin_expect(!!(ScheduleTransaction(*nextWriteTransaction , false)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "ScheduleTransaction(*nextWriteTransaction, false)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8259); AnnotateMozCrashReason("MOZ_CRASH(" "ScheduleTransaction(*nextWriteTransaction, false)" ")"); do { *((volatile int*)__null) = 8259; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8260 | } |
8261 | } |
8262 | |
8263 | for (const auto& objectStoreName : transactionInfo->mObjectStoreNames) { |
8264 | TransactionInfoPair* blockInfo = |
8265 | dbInfo.mBlockingTransactions.Get(objectStoreName); |
8266 | MOZ_ASSERT(blockInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(blockInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(blockInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("blockInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8266); AnnotateMozCrashReason("MOZ_ASSERT" "(" "blockInfo" ")" ); do { *((volatile int*)__null) = 8266; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8267 | |
8268 | if (transactionInfo->mIsWriteTransaction && blockInfo->mLastBlockingReads && |
8269 | blockInfo->mLastBlockingReads.refEquals(*transactionInfo)) { |
8270 | blockInfo->mLastBlockingReads = Nothing(); |
8271 | } |
8272 | |
8273 | blockInfo->mLastBlockingWrites.RemoveElement(transactionInfo); |
8274 | } |
8275 | |
8276 | transactionInfo->RemoveBlockingTransactions(); |
8277 | |
8278 | if (transactionInfo->mIsWriteTransaction) { |
8279 | MOZ_ASSERT(dbInfo.mWriteTransactionCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo.mWriteTransactionCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mWriteTransactionCount ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "dbInfo.mWriteTransactionCount", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8279); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mWriteTransactionCount" ")"); do { *((volatile int*)__null) = 8279; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8280 | dbInfo.mWriteTransactionCount--; |
8281 | } else { |
8282 | MOZ_ASSERT(dbInfo.mReadTransactionCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbInfo.mReadTransactionCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbInfo.mReadTransactionCount ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "dbInfo.mReadTransactionCount", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8282); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbInfo.mReadTransactionCount" ")"); do { *((volatile int*)__null) = 8282; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8283 | dbInfo.mReadTransactionCount--; |
8284 | } |
8285 | |
8286 | mTransactions.Remove(aTransactionId); |
8287 | |
8288 | if (!dbInfo.TotalTransactionCount()) { |
8289 | MOZ_ASSERT(!dbInfo.mIdle)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!dbInfo.mIdle)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!dbInfo.mIdle))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!dbInfo.mIdle", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8289); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!dbInfo.mIdle" ")"); do { *((volatile int*)__null) = 8289; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8290 | dbInfo.mIdle = true; |
8291 | |
8292 | NoteIdleDatabase(dbInfo); |
8293 | } |
8294 | } |
8295 | |
8296 | void ConnectionPool::ScheduleQueuedTransactions() { |
8297 | AssertIsOnOwningThread(); |
8298 | MOZ_ASSERT(!mQueuedTransactions.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mQueuedTransactions.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mQueuedTransactions.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mQueuedTransactions.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8298); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mQueuedTransactions.IsEmpty()" ")"); do { *((volatile int*)__null) = 8298; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8299 | |
8300 | AUTO_PROFILER_LABEL("ConnectionPool::ScheduleQueuedTransactions", DOM)mozilla::AutoProfilerLabel raiiObject8300( "ConnectionPool::ScheduleQueuedTransactions" , nullptr, JS::ProfilingCategoryPair::DOM); |
8301 | |
8302 | const auto foundIt = std::find_if( |
8303 | mQueuedTransactions.begin(), mQueuedTransactions.end(), |
8304 | [&me = *this](const auto& queuedTransaction) { |
8305 | return !me.ScheduleTransaction(*queuedTransaction, |
8306 | /* aFromQueuedTransactions */ true); |
8307 | }); |
8308 | |
8309 | mQueuedTransactions.RemoveElementsRange(mQueuedTransactions.begin(), foundIt); |
8310 | |
8311 | AdjustIdleTimer(); |
8312 | } |
8313 | |
8314 | void ConnectionPool::NoteIdleDatabase(DatabaseInfo& aDatabaseInfo) { |
8315 | AssertIsOnOwningThread(); |
8316 | MOZ_ASSERT(!aDatabaseInfo.TotalTransactionCount())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseInfo.TotalTransactionCount())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!aDatabaseInfo.TotalTransactionCount()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseInfo.TotalTransactionCount()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8316); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseInfo.TotalTransactionCount()" ")"); do { *((volatile int*)__null) = 8316; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8317 | MOZ_ASSERT(aDatabaseInfo.mEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabaseInfo.mEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabaseInfo.mEventTarget)) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDatabaseInfo.mEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8317); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabaseInfo.mEventTarget" ")"); do { *((volatile int*)__null) = 8317; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8318 | MOZ_ASSERT(!mIdleDatabases.Contains(&aDatabaseInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mIdleDatabases.Contains(&aDatabaseInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mIdleDatabases.Contains(&aDatabaseInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mIdleDatabases.Contains(&aDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8318); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mIdleDatabases.Contains(&aDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8318; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8319 | |
8320 | AUTO_PROFILER_LABEL("ConnectionPool::NoteIdleDatabase", DOM)mozilla::AutoProfilerLabel raiiObject8320( "ConnectionPool::NoteIdleDatabase" , nullptr, JS::ProfilingCategoryPair::DOM); |
8321 | |
8322 | const bool otherDatabasesWaiting = !mQueuedTransactions.IsEmpty(); |
8323 | |
8324 | // We check mShutdownRequested because when it is true, mIdleTimer is null. |
8325 | if (mShutdownRequested || otherDatabasesWaiting || |
8326 | aDatabaseInfo.mCloseOnIdle) { |
8327 | // Make sure we close the connection if we're shutting down or giving the |
8328 | // thread to another database. |
8329 | CloseDatabase(aDatabaseInfo); |
8330 | |
8331 | if (otherDatabasesWaiting) { |
8332 | ScheduleQueuedTransactions(); |
8333 | } |
8334 | |
8335 | return; |
8336 | } |
8337 | |
8338 | mIdleDatabases.InsertElementSorted(IdleDatabaseInfo{aDatabaseInfo}); |
8339 | |
8340 | AdjustIdleTimer(); |
8341 | } |
8342 | |
8343 | void ConnectionPool::NoteClosedDatabase(DatabaseInfo& aDatabaseInfo) { |
8344 | AssertIsOnOwningThread(); |
8345 | MOZ_ASSERT(aDatabaseInfo.mClosing)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabaseInfo.mClosing)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabaseInfo.mClosing))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aDatabaseInfo.mClosing" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8345); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabaseInfo.mClosing" ")"); do { *((volatile int*)__null) = 8345; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8346 | MOZ_ASSERT(!mIdleDatabases.Contains(&aDatabaseInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mIdleDatabases.Contains(&aDatabaseInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mIdleDatabases.Contains(&aDatabaseInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mIdleDatabases.Contains(&aDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8346); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mIdleDatabases.Contains(&aDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8346; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8347 | |
8348 | AUTO_PROFILER_LABEL("ConnectionPool::NoteClosedDatabase", DOM)mozilla::AutoProfilerLabel raiiObject8348( "ConnectionPool::NoteClosedDatabase" , nullptr, JS::ProfilingCategoryPair::DOM); |
8349 | |
8350 | aDatabaseInfo.mClosing = false; |
8351 | |
8352 | // Schedule any transactions that were started while we were closing the |
8353 | // connection. |
8354 | if (!mQueuedTransactions.IsEmpty()) { |
8355 | ScheduleQueuedTransactions(); |
8356 | } else if (!aDatabaseInfo.TotalTransactionCount() && !mShutdownRequested) { |
8357 | AdjustIdleTimer(); |
8358 | } |
8359 | |
8360 | // Schedule any transactions that were started while we were closing the |
8361 | // connection. |
8362 | if (aDatabaseInfo.TotalTransactionCount()) { |
8363 | auto& scheduledTransactions = |
8364 | aDatabaseInfo.mTransactionsScheduledDuringClose; |
8365 | |
8366 | MOZ_ASSERT(!scheduledTransactions.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!scheduledTransactions.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!scheduledTransactions.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!scheduledTransactions.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8366); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!scheduledTransactions.IsEmpty()" ")"); do { *((volatile int*)__null) = 8366; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8367 | |
8368 | for (const auto& scheduledTransaction : scheduledTransactions) { |
8369 | Unused << ScheduleTransaction(*scheduledTransaction, |
8370 | /* aFromQueuedTransactions */ false); |
8371 | } |
8372 | |
8373 | scheduledTransactions.Clear(); |
8374 | |
8375 | return; |
8376 | } |
8377 | |
8378 | // There are no more transactions and the connection has been closed. We're |
8379 | // done with this database. |
8380 | { |
8381 | MutexAutoLock lock(mDatabasesMutex); |
8382 | |
8383 | mDatabases.Remove(aDatabaseInfo.mDatabaseId); |
8384 | } |
8385 | |
8386 | // That just deleted |aDatabaseInfo|, we must not access that below. |
8387 | |
8388 | // See if we need to fire any complete callbacks now that the database is |
8389 | // finished. |
8390 | mCompleteCallbacks.RemoveLastElements( |
8391 | mCompleteCallbacks.end() - |
8392 | std::remove_if(mCompleteCallbacks.begin(), mCompleteCallbacks.end(), |
8393 | [&me = *this](const auto& completeCallback) { |
8394 | return me.MaybeFireCallback(completeCallback.get()); |
8395 | })); |
8396 | |
8397 | // If that was the last database and we're supposed to be shutting down then |
8398 | // we are finished. |
8399 | if (mShutdownRequested && !mDatabases.Count()) { |
8400 | MOZ_ASSERT(!mTransactions.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mTransactions.Count()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8400); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Count()" ")"); do { *((volatile int*)__null) = 8400; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8401 | Cleanup(); |
8402 | } |
8403 | } |
8404 | |
8405 | bool ConnectionPool::MaybeFireCallback(DatabaseCompleteCallback* aCallback) { |
8406 | AssertIsOnOwningThread(); |
8407 | MOZ_ASSERT(aCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8407); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCallback" ")" ); do { *((volatile int*)__null) = 8407; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8408 | MOZ_ASSERT(!aCallback->mDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aCallback->mDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aCallback->mDatabaseId.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!aCallback->mDatabaseId.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8408); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aCallback->mDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 8408; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8409 | MOZ_ASSERT(aCallback->mCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCallback->mCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCallback->mCallback))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aCallback->mCallback" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8409); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCallback->mCallback" ")"); do { *((volatile int*)__null) = 8409; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8410 | |
8411 | AUTO_PROFILER_LABEL("ConnectionPool::MaybeFireCallback", DOM)mozilla::AutoProfilerLabel raiiObject8411( "ConnectionPool::MaybeFireCallback" , nullptr, JS::ProfilingCategoryPair::DOM); |
8412 | |
8413 | if (mDatabases.Get(aCallback->mDatabaseId)) { |
8414 | return false; |
8415 | } |
8416 | |
8417 | Unused << aCallback->mCallback->Run(); |
8418 | return true; |
8419 | } |
8420 | |
8421 | void ConnectionPool::PerformIdleDatabaseMaintenance( |
8422 | DatabaseInfo& aDatabaseInfo) { |
8423 | AssertIsOnOwningThread(); |
8424 | MOZ_ASSERT(!aDatabaseInfo.TotalTransactionCount())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseInfo.TotalTransactionCount())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!aDatabaseInfo.TotalTransactionCount()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseInfo.TotalTransactionCount()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8424); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseInfo.TotalTransactionCount()" ")"); do { *((volatile int*)__null) = 8424; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8425 | MOZ_ASSERT(aDatabaseInfo.mEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabaseInfo.mEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabaseInfo.mEventTarget)) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDatabaseInfo.mEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8425); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabaseInfo.mEventTarget" ")"); do { *((volatile int*)__null) = 8425; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8426 | MOZ_ASSERT(aDatabaseInfo.mIdle)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabaseInfo.mIdle)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabaseInfo.mIdle))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDatabaseInfo.mIdle" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8426); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabaseInfo.mIdle" ")"); do { *((volatile int*)__null) = 8426; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8427 | MOZ_ASSERT(!aDatabaseInfo.mCloseOnIdle)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseInfo.mCloseOnIdle)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseInfo.mCloseOnIdle) )), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseInfo.mCloseOnIdle" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8427); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseInfo.mCloseOnIdle" ")"); do { *((volatile int*)__null) = 8427; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8428 | MOZ_ASSERT(!aDatabaseInfo.mClosing)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseInfo.mClosing)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseInfo.mClosing))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseInfo.mClosing" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8428); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseInfo.mClosing" ")"); do { *((volatile int*)__null) = 8428; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8429 | MOZ_ASSERT(mIdleDatabases.Contains(&aDatabaseInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIdleDatabases.Contains(&aDatabaseInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mIdleDatabases.Contains(&aDatabaseInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mIdleDatabases.Contains(&aDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8429); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleDatabases.Contains(&aDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8429; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8430 | MOZ_ASSERT(!mDatabasesPerformingIdleMaintenance.Contains(&aDatabaseInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabasesPerformingIdleMaintenance.Contains(&aDatabaseInfo ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!mDatabasesPerformingIdleMaintenance.Contains(&aDatabaseInfo )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mDatabasesPerformingIdleMaintenance.Contains(&aDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8430); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabasesPerformingIdleMaintenance.Contains(&aDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8430; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8431 | |
8432 | const bool neededCheckpoint = aDatabaseInfo.mNeedsCheckpoint; |
8433 | |
8434 | aDatabaseInfo.mNeedsCheckpoint = false; |
8435 | aDatabaseInfo.mIdle = false; |
8436 | |
8437 | auto idleConnectionRunnable = |
8438 | MakeRefPtr<IdleConnectionRunnable>(aDatabaseInfo, neededCheckpoint); |
8439 | |
8440 | mDatabasesPerformingIdleMaintenance.AppendElement( |
8441 | PerformingIdleMaintenanceDatabaseInfo{aDatabaseInfo, |
8442 | idleConnectionRunnable}); |
8443 | |
8444 | MOZ_ALWAYS_SUCCEEDS(aDatabaseInfo.mEventTarget->Dispatch(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aDatabaseInfo.mEventTarget->Dispatch( idleConnectionRunnable .forget(), nsIEventTarget::DISPATCH_NORMAL))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aDatabaseInfo.mEventTarget->Dispatch( idleConnectionRunnable.forget(), nsIEventTarget::DISPATCH_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8445); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aDatabaseInfo.mEventTarget->Dispatch( idleConnectionRunnable.forget(), nsIEventTarget::DISPATCH_NORMAL))" ")"); do { *((volatile int*)__null) = 8445; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8445 | idleConnectionRunnable.forget(), NS_DISPATCH_NORMAL))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aDatabaseInfo.mEventTarget->Dispatch( idleConnectionRunnable .forget(), nsIEventTarget::DISPATCH_NORMAL))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aDatabaseInfo.mEventTarget->Dispatch( idleConnectionRunnable.forget(), nsIEventTarget::DISPATCH_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8445); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aDatabaseInfo.mEventTarget->Dispatch( idleConnectionRunnable.forget(), nsIEventTarget::DISPATCH_NORMAL))" ")"); do { *((volatile int*)__null) = 8445; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8446 | } |
8447 | |
8448 | void ConnectionPool::CloseDatabase(DatabaseInfo& aDatabaseInfo) const { |
8449 | AssertIsOnOwningThread(); |
8450 | MOZ_DIAGNOSTIC_ASSERT(!aDatabaseInfo.TotalTransactionCount())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseInfo.TotalTransactionCount())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!aDatabaseInfo.TotalTransactionCount()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseInfo.TotalTransactionCount()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8450); AnnotateMozCrashReason("MOZ_DIAGNOSTIC_ASSERT" "(" "!aDatabaseInfo.TotalTransactionCount()" ")"); do { *((volatile int*)__null) = 8450; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8451 | MOZ_ASSERT(aDatabaseInfo.mEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabaseInfo.mEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabaseInfo.mEventTarget)) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDatabaseInfo.mEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8451); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabaseInfo.mEventTarget" ")"); do { *((volatile int*)__null) = 8451; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8452 | MOZ_ASSERT(!aDatabaseInfo.mClosing)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseInfo.mClosing)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseInfo.mClosing))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseInfo.mClosing" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8452); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseInfo.mClosing" ")"); do { *((volatile int*)__null) = 8452; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8453 | |
8454 | aDatabaseInfo.mIdle = false; |
8455 | aDatabaseInfo.mNeedsCheckpoint = false; |
8456 | aDatabaseInfo.mClosing = true; |
8457 | |
8458 | MOZ_ALWAYS_SUCCEEDS(aDatabaseInfo.Dispatch(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aDatabaseInfo.Dispatch( MakeAndAddRef<CloseConnectionRunnable >(aDatabaseInfo)))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aDatabaseInfo.Dispatch( MakeAndAddRef<CloseConnectionRunnable>(aDatabaseInfo)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8459); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aDatabaseInfo.Dispatch( MakeAndAddRef<CloseConnectionRunnable>(aDatabaseInfo)))" ")"); do { *((volatile int*)__null) = 8459; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8459 | MakeAndAddRef<CloseConnectionRunnable>(aDatabaseInfo)))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (aDatabaseInfo.Dispatch( MakeAndAddRef<CloseConnectionRunnable >(aDatabaseInfo)))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(aDatabaseInfo.Dispatch( MakeAndAddRef<CloseConnectionRunnable>(aDatabaseInfo)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8459); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(aDatabaseInfo.Dispatch( MakeAndAddRef<CloseConnectionRunnable>(aDatabaseInfo)))" ")"); do { *((volatile int*)__null) = 8459; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8460 | } |
8461 | |
8462 | bool ConnectionPool::CloseDatabaseWhenIdleInternal( |
8463 | const nsACString& aDatabaseId) { |
8464 | AssertIsOnOwningThread(); |
8465 | MOZ_ASSERT(!aDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseId.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseId.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8465); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 8465; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8466 | |
8467 | AUTO_PROFILER_LABEL("ConnectionPool::CloseDatabaseWhenIdleInternal", DOM)mozilla::AutoProfilerLabel raiiObject8467( "ConnectionPool::CloseDatabaseWhenIdleInternal" , nullptr, JS::ProfilingCategoryPair::DOM); |
8468 | |
8469 | if (DatabaseInfo* dbInfo = mDatabases.Get(aDatabaseId)) { |
8470 | if (mIdleDatabases.RemoveElement(dbInfo) || |
8471 | mDatabasesPerformingIdleMaintenance.RemoveElement(dbInfo)) { |
8472 | CloseDatabase(*dbInfo); |
8473 | AdjustIdleTimer(); |
8474 | } else { |
8475 | dbInfo->mCloseOnIdle.EnsureFlipped(); |
8476 | } |
8477 | |
8478 | return true; |
8479 | } |
8480 | |
8481 | return false; |
8482 | } |
8483 | |
8484 | ConnectionPool::ConnectionRunnable::ConnectionRunnable( |
8485 | DatabaseInfo& aDatabaseInfo) |
8486 | : Runnable("dom::indexedDB::ConnectionPool::ConnectionRunnable"), |
8487 | mDatabaseInfo(aDatabaseInfo), |
8488 | mOwningEventTarget(GetCurrentSerialEventTarget()) { |
8489 | AssertIsOnBackgroundThread(); |
8490 | MOZ_ASSERT(aDatabaseInfo.mConnectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDatabaseInfo.mConnectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDatabaseInfo.mConnectionPool ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aDatabaseInfo.mConnectionPool", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8490); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDatabaseInfo.mConnectionPool" ")"); do { *((volatile int*)__null) = 8490; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8491 | aDatabaseInfo.mConnectionPool->AssertIsOnOwningThread(); |
8492 | MOZ_ASSERT(mOwningEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOwningEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOwningEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOwningEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8492); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOwningEventTarget" ")"); do { *((volatile int*)__null) = 8492; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8493 | } |
8494 | |
8495 | NS_IMETHODIMPnsresult |
8496 | ConnectionPool::IdleConnectionRunnable::Run() { |
8497 | MOZ_ASSERT(!mDatabaseInfo.mIdle)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabaseInfo.mIdle)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDatabaseInfo.mIdle))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mDatabaseInfo.mIdle" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8497); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabaseInfo.mIdle" ")"); do { *((volatile int*)__null) = 8497; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8498 | |
8499 | const nsCOMPtr<nsIEventTarget> owningThread = std::move(mOwningEventTarget); |
8500 | |
8501 | if (owningThread) { |
8502 | mDatabaseInfo.AssertIsOnConnectionThread(); |
8503 | |
8504 | // The connection could be null if EnsureConnection() didn't run or was not |
8505 | // successful in TransactionDatabaseOperationBase::RunOnConnectionThread(). |
8506 | if (mDatabaseInfo.mConnection) { |
8507 | mDatabaseInfo.mConnection->DoIdleProcessing(mNeedsCheckpoint, |
8508 | mInterrupted); |
8509 | } |
8510 | |
8511 | MOZ_ALWAYS_SUCCEEDS(owningThread->Dispatch(this, NS_DISPATCH_NORMAL))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (owningThread->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(owningThread->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8511); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(owningThread->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL))" ")"); do { *((volatile int*)__null) = 8511; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8512 | return NS_OK; |
8513 | } |
8514 | |
8515 | AssertIsOnBackgroundThread(); |
8516 | |
8517 | RefPtr<ConnectionPool> connectionPool = mDatabaseInfo.mConnectionPool; |
8518 | MOZ_ASSERT(connectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(connectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(connectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("connectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8518); AnnotateMozCrashReason("MOZ_ASSERT" "(" "connectionPool" ")"); do { *((volatile int*)__null) = 8518; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8519 | |
8520 | if (mDatabaseInfo.mClosing || mDatabaseInfo.TotalTransactionCount()) { |
8521 | MOZ_ASSERT(!connectionPool->mDatabasesPerformingIdleMaintenance.Contains(do { static_assert( mozilla::detail::AssertionConditionType< decltype(!connectionPool->mDatabasesPerformingIdleMaintenance .Contains( &mDatabaseInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!connectionPool->mDatabasesPerformingIdleMaintenance .Contains( &mDatabaseInfo)))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("!connectionPool->mDatabasesPerformingIdleMaintenance.Contains( &mDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8522); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!connectionPool->mDatabasesPerformingIdleMaintenance.Contains( &mDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8522; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
8522 | &mDatabaseInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!connectionPool->mDatabasesPerformingIdleMaintenance .Contains( &mDatabaseInfo))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!connectionPool->mDatabasesPerformingIdleMaintenance .Contains( &mDatabaseInfo)))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("!connectionPool->mDatabasesPerformingIdleMaintenance.Contains( &mDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8522); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!connectionPool->mDatabasesPerformingIdleMaintenance.Contains( &mDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8522; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8523 | } else { |
8524 | MOZ_ALWAYS_TRUE(do { if ((__builtin_expect(!!(connectionPool->mDatabasesPerformingIdleMaintenance .RemoveElement( &mDatabaseInfo)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement( &mDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8526); AnnotateMozCrashReason("MOZ_CRASH(" "connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement( &mDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8526; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8525 | connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement(do { if ((__builtin_expect(!!(connectionPool->mDatabasesPerformingIdleMaintenance .RemoveElement( &mDatabaseInfo)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement( &mDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8526); AnnotateMozCrashReason("MOZ_CRASH(" "connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement( &mDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8526; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8526 | &mDatabaseInfo))do { if ((__builtin_expect(!!(connectionPool->mDatabasesPerformingIdleMaintenance .RemoveElement( &mDatabaseInfo)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement( &mDatabaseInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8526); AnnotateMozCrashReason("MOZ_CRASH(" "connectionPool->mDatabasesPerformingIdleMaintenance.RemoveElement( &mDatabaseInfo)" ")"); do { *((volatile int*)__null) = 8526; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8527 | |
8528 | connectionPool->NoteIdleDatabase(mDatabaseInfo); |
8529 | } |
8530 | |
8531 | return NS_OK; |
8532 | } |
8533 | |
8534 | NS_IMETHODIMPnsresult |
8535 | ConnectionPool::CloseConnectionRunnable::Run() { |
8536 | AUTO_PROFILER_LABEL("ConnectionPool::CloseConnectionRunnable::Run", DOM)mozilla::AutoProfilerLabel raiiObject8536( "ConnectionPool::CloseConnectionRunnable::Run" , nullptr, JS::ProfilingCategoryPair::DOM); |
8537 | |
8538 | if (mOwningEventTarget) { |
8539 | MOZ_ASSERT(mDatabaseInfo.mClosing)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabaseInfo.mClosing)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabaseInfo.mClosing))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabaseInfo.mClosing" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8539); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabaseInfo.mClosing" ")"); do { *((volatile int*)__null) = 8539; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8540 | |
8541 | const nsCOMPtr<nsIEventTarget> owningThread = std::move(mOwningEventTarget); |
8542 | |
8543 | // The connection could be null if EnsureConnection() didn't run or was not |
8544 | // successful in TransactionDatabaseOperationBase::RunOnConnectionThread(). |
8545 | if (mDatabaseInfo.mConnection) { |
8546 | mDatabaseInfo.AssertIsOnConnectionThread(); |
8547 | |
8548 | mDatabaseInfo.mConnection->Close(); |
8549 | |
8550 | IDB_DEBUG_LOG(("ConnectionPool closed connection 0x%p", |
8551 | mDatabaseInfo.mConnection.get())); |
8552 | |
8553 | mDatabaseInfo.mConnection = nullptr; |
8554 | |
8555 | #ifdef DEBUG1 |
8556 | mDatabaseInfo.mDEBUGConnectionEventTarget = nullptr; |
8557 | #endif |
8558 | } |
8559 | |
8560 | MOZ_ALWAYS_SUCCEEDS(owningThread->Dispatch(this, NS_DISPATCH_NORMAL))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (owningThread->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(owningThread->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8560); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(owningThread->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL))" ")"); do { *((volatile int*)__null) = 8560; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8561 | return NS_OK; |
8562 | } |
8563 | |
8564 | RefPtr<ConnectionPool> connectionPool = mDatabaseInfo.mConnectionPool; |
8565 | MOZ_ASSERT(connectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(connectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(connectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("connectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8565); AnnotateMozCrashReason("MOZ_ASSERT" "(" "connectionPool" ")"); do { *((volatile int*)__null) = 8565; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8566 | |
8567 | connectionPool->NoteClosedDatabase(mDatabaseInfo); |
8568 | return NS_OK; |
8569 | } |
8570 | |
8571 | ConnectionPool::DatabaseInfo::DatabaseInfo(ConnectionPool* aConnectionPool, |
8572 | const nsACString& aDatabaseId) |
8573 | : mConnectionPool(aConnectionPool), |
8574 | mDatabaseId(aDatabaseId), |
8575 | mReadTransactionCount(0), |
8576 | mWriteTransactionCount(0), |
8577 | mNeedsCheckpoint(false), |
8578 | mIdle(false), |
8579 | mClosing(false) |
8580 | #ifdef DEBUG1 |
8581 | , |
8582 | mDEBUGConnectionEventTarget(nullptr) |
8583 | #endif |
8584 | { |
8585 | AssertIsOnBackgroundThread(); |
8586 | MOZ_ASSERT(aConnectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aConnectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aConnectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aConnectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8586); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aConnectionPool" ")"); do { *((volatile int*)__null) = 8586; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8587 | aConnectionPool->AssertIsOnOwningThread(); |
8588 | MOZ_ASSERT(!aDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aDatabaseId.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aDatabaseId.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8588); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 8588; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8589 | |
8590 | MOZ_COUNT_CTOR(ConnectionPool::DatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::DatabaseInfo >, "Token '" "ConnectionPool::DatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::DatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::DatabaseInfo" , sizeof(*this)); } while (0); |
8591 | } |
8592 | |
8593 | ConnectionPool::DatabaseInfo::~DatabaseInfo() { |
8594 | AssertIsOnBackgroundThread(); |
8595 | MOZ_ASSERT(!mConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8595); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mConnection" ")"); do { *((volatile int*)__null) = 8595; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8596 | MOZ_ASSERT(mScheduledWriteTransactions.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mScheduledWriteTransactions.IsEmpty())>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(! !(mScheduledWriteTransactions.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mScheduledWriteTransactions.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8596); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mScheduledWriteTransactions.IsEmpty()" ")"); do { *((volatile int*)__null) = 8596; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8597 | MOZ_ASSERT(!mRunningWriteTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mRunningWriteTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mRunningWriteTransaction))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mRunningWriteTransaction" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8597); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mRunningWriteTransaction" ")"); do { *((volatile int*)__null) = 8597; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8598 | MOZ_ASSERT(!TotalTransactionCount())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!TotalTransactionCount())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!TotalTransactionCount()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!TotalTransactionCount()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8598); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!TotalTransactionCount()" ")"); do { *((volatile int*)__null) = 8598; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8599 | |
8600 | MOZ_COUNT_DTOR(ConnectionPool::DatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::DatabaseInfo >, "Token '" "ConnectionPool::DatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::DatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::DatabaseInfo" , sizeof(*this)); } while (0); |
8601 | } |
8602 | |
8603 | nsresult ConnectionPool::DatabaseInfo::Dispatch( |
8604 | already_AddRefed<nsIRunnable> aRunnable) { |
8605 | nsCOMPtr<nsIRunnable> runnable = aRunnable; |
8606 | |
8607 | #ifdef DEBUG1 |
8608 | if (kDEBUGTransactionThreadSleepMS) { |
8609 | runnable = MakeRefPtr<TransactionRunnable>(std::move(runnable)); |
8610 | } |
8611 | #endif |
8612 | |
8613 | return mEventTarget->Dispatch(runnable.forget(), NS_DISPATCH_NORMALnsIEventTarget::DISPATCH_NORMAL); |
8614 | } |
8615 | |
8616 | ConnectionPool::DatabaseCompleteCallback::DatabaseCompleteCallback( |
8617 | const nsCString& aDatabaseId, nsIRunnable* aCallback) |
8618 | : mDatabaseId(aDatabaseId), mCallback(aCallback) { |
8619 | AssertIsOnBackgroundThread(); |
8620 | MOZ_ASSERT(!mDatabaseId.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mDatabaseId.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mDatabaseId.IsEmpty()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mDatabaseId.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8620); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mDatabaseId.IsEmpty()" ")"); do { *((volatile int*)__null) = 8620; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8621 | MOZ_ASSERT(aCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8621); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCallback" ")" ); do { *((volatile int*)__null) = 8621; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8622 | |
8623 | MOZ_COUNT_CTOR(ConnectionPool::DatabaseCompleteCallback)do { static_assert(std::is_class_v<ConnectionPool::DatabaseCompleteCallback >, "Token '" "ConnectionPool::DatabaseCompleteCallback" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::DatabaseCompleteCallback>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::DatabaseCompleteCallback" , sizeof(*this)); } while (0); |
8624 | } |
8625 | |
8626 | ConnectionPool::DatabaseCompleteCallback::~DatabaseCompleteCallback() { |
8627 | AssertIsOnBackgroundThread(); |
8628 | |
8629 | MOZ_COUNT_DTOR(ConnectionPool::DatabaseCompleteCallback)do { static_assert(std::is_class_v<ConnectionPool::DatabaseCompleteCallback >, "Token '" "ConnectionPool::DatabaseCompleteCallback" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::DatabaseCompleteCallback>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::DatabaseCompleteCallback" , sizeof(*this)); } while (0); |
8630 | } |
8631 | |
8632 | ConnectionPool::FinishCallbackWrapper::FinishCallbackWrapper( |
8633 | ConnectionPool* aConnectionPool, uint64_t aTransactionId, |
8634 | FinishCallback* aCallback) |
8635 | : Runnable("dom::indexedDB::ConnectionPool::FinishCallbackWrapper"), |
8636 | mConnectionPool(aConnectionPool), |
8637 | mCallback(aCallback), |
8638 | mOwningEventTarget(GetCurrentSerialEventTarget()), |
8639 | mTransactionId(aTransactionId), |
8640 | mHasRunOnce(false) { |
8641 | AssertIsOnBackgroundThread(); |
8642 | MOZ_ASSERT(aConnectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aConnectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aConnectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aConnectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8642); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aConnectionPool" ")"); do { *((volatile int*)__null) = 8642; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8643 | MOZ_ASSERT(aCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8643); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aCallback" ")" ); do { *((volatile int*)__null) = 8643; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8644 | MOZ_ASSERT(mOwningEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOwningEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOwningEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOwningEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8644); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOwningEventTarget" ")"); do { *((volatile int*)__null) = 8644; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8645 | } |
8646 | |
8647 | ConnectionPool::FinishCallbackWrapper::~FinishCallbackWrapper() { |
8648 | MOZ_ASSERT(!mConnectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mConnectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mConnectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mConnectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8648); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mConnectionPool" ")"); do { *((volatile int*)__null) = 8648; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8649 | MOZ_ASSERT(!mCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8649); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mCallback" ")"); do { *((volatile int*)__null) = 8649; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8650 | } |
8651 | |
8652 | nsresult ConnectionPool::FinishCallbackWrapper::Run() { |
8653 | MOZ_ASSERT(mConnectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mConnectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mConnectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mConnectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8653); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mConnectionPool" ")"); do { *((volatile int*)__null) = 8653; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8654 | MOZ_ASSERT(mCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8654); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCallback" ")" ); do { *((volatile int*)__null) = 8654; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8655 | MOZ_ASSERT(mOwningEventTarget)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOwningEventTarget)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOwningEventTarget))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOwningEventTarget" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8655); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOwningEventTarget" ")"); do { *((volatile int*)__null) = 8655; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8656 | |
8657 | AUTO_PROFILER_LABEL("ConnectionPool::FinishCallbackWrapper::Run", DOM)mozilla::AutoProfilerLabel raiiObject8657( "ConnectionPool::FinishCallbackWrapper::Run" , nullptr, JS::ProfilingCategoryPair::DOM); |
8658 | |
8659 | if (!mHasRunOnce) { |
8660 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8660); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 8660; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8661 | |
8662 | mHasRunOnce = true; |
8663 | |
8664 | Unused << mCallback->Run(); |
8665 | |
8666 | MOZ_ALWAYS_SUCCEEDS(mOwningEventTarget->Dispatch(this, NS_DISPATCH_NORMAL))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mOwningEventTarget->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(mOwningEventTarget->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8666); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(mOwningEventTarget->Dispatch(this, nsIEventTarget::DISPATCH_NORMAL))" ")"); do { *((volatile int*)__null) = 8666; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8667 | |
8668 | return NS_OK; |
8669 | } |
8670 | |
8671 | mConnectionPool->AssertIsOnOwningThread(); |
8672 | MOZ_ASSERT(mHasRunOnce)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mHasRunOnce)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mHasRunOnce))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mHasRunOnce", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8672); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mHasRunOnce" ")"); do { *((volatile int*)__null) = 8672; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8673 | |
8674 | RefPtr<ConnectionPool> connectionPool = std::move(mConnectionPool); |
8675 | RefPtr<FinishCallback> callback = std::move(mCallback); |
8676 | |
8677 | callback->TransactionFinishedBeforeUnblock(); |
8678 | |
8679 | connectionPool->NoteFinishedTransaction(mTransactionId); |
8680 | |
8681 | callback->TransactionFinishedAfterUnblock(); |
8682 | |
8683 | return NS_OK; |
8684 | } |
8685 | |
8686 | uint32_t ConnectionPool::sSerialNumber = 0u; |
8687 | |
8688 | #ifdef DEBUG1 |
8689 | |
8690 | ConnectionPool::TransactionRunnable::TransactionRunnable( |
8691 | nsCOMPtr<nsIRunnable> aRunnable) |
8692 | : Runnable("dom::indexedDB::ConnectionPool::TransactionRunnable"), |
8693 | mRunnable(std::move(aRunnable)) { |
8694 | AssertIsOnBackgroundThread(); |
8695 | MOZ_ASSERT(kDEBUGTransactionThreadSleepMS)do { static_assert( mozilla::detail::AssertionConditionType< decltype(kDEBUGTransactionThreadSleepMS)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(kDEBUGTransactionThreadSleepMS ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "kDEBUGTransactionThreadSleepMS", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8695); AnnotateMozCrashReason("MOZ_ASSERT" "(" "kDEBUGTransactionThreadSleepMS" ")"); do { *((volatile int*)__null) = 8695; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8696 | } |
8697 | |
8698 | nsresult ConnectionPool::TransactionRunnable::Run() { |
8699 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8699); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 8699; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8700 | |
8701 | QM_TRY(MOZ_TO_RESULT(mRunnable->Run())){auto tryResult966 = (ToResult(mRunnable->Run())); static_assert (std::is_empty_v<typename decltype(tryResult966)::ok_type> ); if ((__builtin_expect(!!(tryResult966.isErr()), 0))) { mozilla ::dom::quota::HandleError("ToResult(mRunnable->Run())", tryResult966 .inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8701, mozilla::dom::quota::Severity::Error); return tryResult966 .propagateErr(); }}; |
8702 | |
8703 | MOZ_ALWAYS_TRUE(PR_Sleep(PR_MillisecondsToInterval(do { if ((__builtin_expect(!!(PR_Sleep(PR_MillisecondsToInterval ( kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "PR_Sleep(PR_MillisecondsToInterval( kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8704); AnnotateMozCrashReason("MOZ_CRASH(" "PR_Sleep(PR_MillisecondsToInterval( kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS" ")"); do { *((volatile int*)__null) = 8704; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
8704 | kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS)do { if ((__builtin_expect(!!(PR_Sleep(PR_MillisecondsToInterval ( kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "PR_Sleep(PR_MillisecondsToInterval( kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8704); AnnotateMozCrashReason("MOZ_CRASH(" "PR_Sleep(PR_MillisecondsToInterval( kDEBUGTransactionThreadSleepMS)) == PR_SUCCESS" ")"); do { *((volatile int*)__null) = 8704; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
8705 | |
8706 | return NS_OK; |
8707 | } |
8708 | |
8709 | #endif |
8710 | |
8711 | ConnectionPool::IdleResource::IdleResource(const TimeStamp& aIdleTime) |
8712 | : mIdleTime(aIdleTime) { |
8713 | AssertIsOnBackgroundThread(); |
8714 | MOZ_ASSERT(!aIdleTime.IsNull())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aIdleTime.IsNull())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aIdleTime.IsNull()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!aIdleTime.IsNull()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8714); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aIdleTime.IsNull()" ")"); do { *((volatile int*)__null) = 8714; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8715 | |
8716 | MOZ_COUNT_CTOR(ConnectionPool::IdleResource)do { static_assert(std::is_class_v<ConnectionPool::IdleResource >, "Token '" "ConnectionPool::IdleResource" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::IdleResource>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::IdleResource" , sizeof(*this)); } while (0); |
8717 | } |
8718 | |
8719 | ConnectionPool::IdleResource::~IdleResource() { |
8720 | AssertIsOnBackgroundThread(); |
8721 | |
8722 | MOZ_COUNT_DTOR(ConnectionPool::IdleResource)do { static_assert(std::is_class_v<ConnectionPool::IdleResource >, "Token '" "ConnectionPool::IdleResource" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::IdleResource>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::IdleResource" , sizeof(*this)); } while (0); |
8723 | } |
8724 | |
8725 | ConnectionPool::IdleDatabaseInfo::IdleDatabaseInfo(DatabaseInfo& aDatabaseInfo) |
8726 | : IdleResource( |
8727 | TimeStamp::NowLoRes() + |
8728 | (aDatabaseInfo.mIdle |
8729 | ? TimeDuration::FromMilliseconds(kConnectionIdleMaintenanceMS) |
8730 | : TimeDuration::FromMilliseconds(kConnectionIdleCloseMS))), |
8731 | mDatabaseInfo(WrapNotNullUnchecked(&aDatabaseInfo)) { |
8732 | AssertIsOnBackgroundThread(); |
8733 | |
8734 | MOZ_COUNT_CTOR(ConnectionPool::IdleDatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::IdleDatabaseInfo >, "Token '" "ConnectionPool::IdleDatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::IdleDatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::IdleDatabaseInfo" , sizeof(*this)); } while (0); |
8735 | } |
8736 | |
8737 | ConnectionPool::IdleDatabaseInfo::~IdleDatabaseInfo() { |
8738 | AssertIsOnBackgroundThread(); |
8739 | |
8740 | MOZ_COUNT_DTOR(ConnectionPool::IdleDatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::IdleDatabaseInfo >, "Token '" "ConnectionPool::IdleDatabaseInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::IdleDatabaseInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::IdleDatabaseInfo" , sizeof(*this)); } while (0); |
8741 | } |
8742 | |
8743 | ConnectionPool::PerformingIdleMaintenanceDatabaseInfo:: |
8744 | PerformingIdleMaintenanceDatabaseInfo( |
8745 | DatabaseInfo& aDatabaseInfo, |
8746 | RefPtr<IdleConnectionRunnable> aIdleConnectionRunnable) |
8747 | : mDatabaseInfo(WrapNotNullUnchecked(&aDatabaseInfo)), |
8748 | mIdleConnectionRunnable(std::move(aIdleConnectionRunnable)) { |
8749 | AssertIsOnBackgroundThread(); |
8750 | MOZ_ASSERT(mIdleConnectionRunnable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mIdleConnectionRunnable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mIdleConnectionRunnable))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("mIdleConnectionRunnable" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8750); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mIdleConnectionRunnable" ")"); do { *((volatile int*)__null) = 8750; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8751 | |
8752 | MOZ_COUNT_CTOR(ConnectionPool::PerformingIdleMaintenanceDatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::PerformingIdleMaintenanceDatabaseInfo >, "Token '" "ConnectionPool::PerformingIdleMaintenanceDatabaseInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ConnectionPool::PerformingIdleMaintenanceDatabaseInfo >::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::PerformingIdleMaintenanceDatabaseInfo" , sizeof(*this)); } while (0); |
8753 | } |
8754 | |
8755 | ConnectionPool::PerformingIdleMaintenanceDatabaseInfo:: |
8756 | ~PerformingIdleMaintenanceDatabaseInfo() { |
8757 | AssertIsOnBackgroundThread(); |
8758 | |
8759 | MOZ_COUNT_DTOR(ConnectionPool::PerformingIdleMaintenanceDatabaseInfo)do { static_assert(std::is_class_v<ConnectionPool::PerformingIdleMaintenanceDatabaseInfo >, "Token '" "ConnectionPool::PerformingIdleMaintenanceDatabaseInfo" "' is not a class type."); static_assert(!std::is_base_of< nsISupports, ConnectionPool::PerformingIdleMaintenanceDatabaseInfo >::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::PerformingIdleMaintenanceDatabaseInfo" , sizeof(*this)); } while (0); |
8760 | } |
8761 | |
8762 | ConnectionPool::TransactionInfo::TransactionInfo( |
8763 | DatabaseInfo& aDatabaseInfo, const nsID& aBackgroundChildLoggingId, |
8764 | const nsACString& aDatabaseId, uint64_t aTransactionId, |
8765 | int64_t aLoggingSerialNumber, const nsTArray<nsString>& aObjectStoreNames, |
8766 | bool aIsWriteTransaction, TransactionDatabaseOperationBase* aTransactionOp) |
8767 | : mDatabaseInfo(aDatabaseInfo), |
8768 | mBackgroundChildLoggingId(aBackgroundChildLoggingId), |
8769 | mDatabaseId(aDatabaseId), |
8770 | mTransactionId(aTransactionId), |
8771 | mLoggingSerialNumber(aLoggingSerialNumber), |
8772 | mObjectStoreNames(aObjectStoreNames.Clone()), |
8773 | mIsWriteTransaction(aIsWriteTransaction), |
8774 | mRunning(false) { |
8775 | AssertIsOnBackgroundThread(); |
8776 | aDatabaseInfo.mConnectionPool->AssertIsOnOwningThread(); |
8777 | |
8778 | MOZ_COUNT_CTOR(ConnectionPool::TransactionInfo)do { static_assert(std::is_class_v<ConnectionPool::TransactionInfo >, "Token '" "ConnectionPool::TransactionInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::TransactionInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::TransactionInfo" , sizeof(*this)); } while (0); |
8779 | |
8780 | if (aTransactionOp) { |
8781 | mQueuedRunnables.AppendElement(aTransactionOp); |
8782 | } |
8783 | } |
8784 | |
8785 | ConnectionPool::TransactionInfo::~TransactionInfo() { |
8786 | AssertIsOnBackgroundThread(); |
8787 | MOZ_ASSERT(!mBlockedOn.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mBlockedOn.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mBlockedOn.Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mBlockedOn.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8787); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mBlockedOn.Count()" ")"); do { *((volatile int*)__null) = 8787; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8788 | MOZ_ASSERT(mQueuedRunnables.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mQueuedRunnables.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mQueuedRunnables.IsEmpty())) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mQueuedRunnables.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8788); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mQueuedRunnables.IsEmpty()" ")"); do { *((volatile int*)__null) = 8788; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8789 | MOZ_ASSERT(!mRunning)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mRunning)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mRunning))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mRunning", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8789); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mRunning" ")" ); do { *((volatile int*)__null) = 8789; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8790 | MOZ_ASSERT(mFinished)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFinished)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFinished))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFinished", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8790); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFinished" ")" ); do { *((volatile int*)__null) = 8790; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8791 | |
8792 | MOZ_COUNT_DTOR(ConnectionPool::TransactionInfo)do { static_assert(std::is_class_v<ConnectionPool::TransactionInfo >, "Token '" "ConnectionPool::TransactionInfo" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::TransactionInfo>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::TransactionInfo" , sizeof(*this)); } while (0); |
8793 | } |
8794 | |
8795 | void ConnectionPool::TransactionInfo::AddBlockingTransaction( |
8796 | TransactionInfo& aTransactionInfo) { |
8797 | AssertIsOnBackgroundThread(); |
8798 | |
8799 | // XXX Does it really make sense to have both mBlocking and mBlockingOrdered, |
8800 | // just to reduce the algorithmic complexity of this Contains check? This was |
8801 | // mentioned in the context of Bug 1290853, but no real justification was |
8802 | // given. There was the suggestion of encapsulating this in an |
8803 | // insertion-ordered hashtable implementation, which seems like a good idea. |
8804 | // If we had that, this would be the appropriate data structure to use here. |
8805 | if (mBlocking.EnsureInserted(&aTransactionInfo)) { |
8806 | mBlockingOrdered.AppendElement(WrapNotNullUnchecked(&aTransactionInfo)); |
8807 | } |
8808 | } |
8809 | |
8810 | void ConnectionPool::TransactionInfo::RemoveBlockingTransactions() { |
8811 | AssertIsOnBackgroundThread(); |
8812 | |
8813 | for (const auto blockedInfo : mBlockingOrdered) { |
8814 | blockedInfo->MaybeUnblock(*this); |
8815 | } |
8816 | |
8817 | mBlocking.Clear(); |
8818 | mBlockingOrdered.Clear(); |
8819 | } |
8820 | |
8821 | void ConnectionPool::TransactionInfo::MaybeUnblock( |
8822 | TransactionInfo& aTransactionInfo) { |
8823 | AssertIsOnBackgroundThread(); |
8824 | MOZ_ASSERT(mBlockedOn.Contains(&aTransactionInfo))do { static_assert( mozilla::detail::AssertionConditionType< decltype(mBlockedOn.Contains(&aTransactionInfo))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mBlockedOn.Contains(&aTransactionInfo)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mBlockedOn.Contains(&aTransactionInfo)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8824); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mBlockedOn.Contains(&aTransactionInfo)" ")"); do { *((volatile int*)__null) = 8824; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8825 | |
8826 | mBlockedOn.Remove(&aTransactionInfo); |
8827 | if (mBlockedOn.IsEmpty()) { |
8828 | ConnectionPool* connectionPool = mDatabaseInfo.mConnectionPool; |
8829 | MOZ_ASSERT(connectionPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(connectionPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(connectionPool))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("connectionPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8829); AnnotateMozCrashReason("MOZ_ASSERT" "(" "connectionPool" ")"); do { *((volatile int*)__null) = 8829; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8830 | connectionPool->AssertIsOnOwningThread(); |
8831 | |
8832 | Unused << connectionPool->ScheduleTransaction( |
8833 | *this, |
8834 | /* aFromQueuedTransactions */ false); |
8835 | } |
8836 | } |
8837 | |
8838 | #if defined(DEBUG1) || defined(NS_BUILD_REFCNT_LOGGING1) |
8839 | ConnectionPool::TransactionInfoPair::TransactionInfoPair() { |
8840 | AssertIsOnBackgroundThread(); |
8841 | |
8842 | MOZ_COUNT_CTOR(ConnectionPool::TransactionInfoPair)do { static_assert(std::is_class_v<ConnectionPool::TransactionInfoPair >, "Token '" "ConnectionPool::TransactionInfoPair" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::TransactionInfoPair>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogCtor((void*)this, "ConnectionPool::TransactionInfoPair" , sizeof(*this)); } while (0); |
8843 | } |
8844 | |
8845 | ConnectionPool::TransactionInfoPair::~TransactionInfoPair() { |
8846 | AssertIsOnBackgroundThread(); |
8847 | |
8848 | MOZ_COUNT_DTOR(ConnectionPool::TransactionInfoPair)do { static_assert(std::is_class_v<ConnectionPool::TransactionInfoPair >, "Token '" "ConnectionPool::TransactionInfoPair" "' is not a class type." ); static_assert(!std::is_base_of<nsISupports, ConnectionPool ::TransactionInfoPair>::value, "nsISupports classes don't need to call MOZ_COUNT_CTOR or " "MOZ_COUNT_DTOR");; NS_LogDtor((void*)this, "ConnectionPool::TransactionInfoPair" , sizeof(*this)); } while (0); |
8849 | } |
8850 | #endif |
8851 | |
8852 | /******************************************************************************* |
8853 | * Metadata classes |
8854 | ******************************************************************************/ |
8855 | |
8856 | bool FullObjectStoreMetadata::HasLiveIndexes() const { |
8857 | AssertIsOnBackgroundThread(); |
8858 | |
8859 | return std::any_of(mIndexes.Values().cbegin(), mIndexes.Values().cend(), |
8860 | [](const auto& entry) { return !entry->mDeleted; }); |
8861 | } |
8862 | |
8863 | SafeRefPtr<FullDatabaseMetadata> FullDatabaseMetadata::Duplicate() const { |
8864 | AssertIsOnBackgroundThread(); |
8865 | |
8866 | // FullDatabaseMetadata contains two hash tables of pointers that we need to |
8867 | // duplicate so we can't just use the copy constructor. |
8868 | auto newMetadata = MakeSafeRefPtr<FullDatabaseMetadata>(mCommonMetadata); |
8869 | |
8870 | newMetadata->mDatabaseId = mDatabaseId; |
8871 | newMetadata->mFilePath = mFilePath; |
8872 | newMetadata->mNextObjectStoreId = mNextObjectStoreId; |
8873 | newMetadata->mNextIndexId = mNextIndexId; |
8874 | |
8875 | for (const auto& objectStoreEntry : mObjectStores) { |
8876 | const auto& objectStoreValue = objectStoreEntry.GetData(); |
8877 | |
8878 | auto newOSMetadata = MakeSafeRefPtr<FullObjectStoreMetadata>( |
8879 | objectStoreValue->mCommonMetadata, [&objectStoreValue] { |
8880 | const auto&& srcLocked = objectStoreValue->mAutoIncrementIds.Lock(); |
8881 | return *srcLocked; |
8882 | }()); |
8883 | |
8884 | for (const auto& indexEntry : objectStoreValue->mIndexes) { |
8885 | const auto& value = indexEntry.GetData(); |
8886 | |
8887 | auto newIndexMetadata = MakeSafeRefPtr<FullIndexMetadata>(); |
8888 | |
8889 | newIndexMetadata->mCommonMetadata = value->mCommonMetadata; |
8890 | |
8891 | if (NS_WARN_IF(!newOSMetadata->mIndexes.InsertOrUpdate(NS_warn_if_impl(!newOSMetadata->mIndexes.InsertOrUpdate( indexEntry .GetKey(), std::move(newIndexMetadata), fallible), "!newOSMetadata->mIndexes.InsertOrUpdate( indexEntry.GetKey(), std::move(newIndexMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8892) |
8892 | indexEntry.GetKey(), std::move(newIndexMetadata), fallible))NS_warn_if_impl(!newOSMetadata->mIndexes.InsertOrUpdate( indexEntry .GetKey(), std::move(newIndexMetadata), fallible), "!newOSMetadata->mIndexes.InsertOrUpdate( indexEntry.GetKey(), std::move(newIndexMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8892)) { |
8893 | return nullptr; |
8894 | } |
8895 | } |
8896 | |
8897 | MOZ_ASSERT(objectStoreValue->mIndexes.Count() ==do { static_assert( mozilla::detail::AssertionConditionType< decltype(objectStoreValue->mIndexes.Count() == newOSMetadata ->mIndexes.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(objectStoreValue->mIndexes .Count() == newOSMetadata->mIndexes.Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("objectStoreValue->mIndexes.Count() == newOSMetadata->mIndexes.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8898); AnnotateMozCrashReason("MOZ_ASSERT" "(" "objectStoreValue->mIndexes.Count() == newOSMetadata->mIndexes.Count()" ")"); do { *((volatile int*)__null) = 8898; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
8898 | newOSMetadata->mIndexes.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(objectStoreValue->mIndexes.Count() == newOSMetadata ->mIndexes.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(objectStoreValue->mIndexes .Count() == newOSMetadata->mIndexes.Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("objectStoreValue->mIndexes.Count() == newOSMetadata->mIndexes.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8898); AnnotateMozCrashReason("MOZ_ASSERT" "(" "objectStoreValue->mIndexes.Count() == newOSMetadata->mIndexes.Count()" ")"); do { *((volatile int*)__null) = 8898; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8899 | |
8900 | if (NS_WARN_IF(!newMetadata->mObjectStores.InsertOrUpdate(NS_warn_if_impl(!newMetadata->mObjectStores.InsertOrUpdate ( objectStoreEntry.GetKey(), std::move(newOSMetadata), fallible ), "!newMetadata->mObjectStores.InsertOrUpdate( objectStoreEntry.GetKey(), std::move(newOSMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8901) |
8901 | objectStoreEntry.GetKey(), std::move(newOSMetadata), fallible))NS_warn_if_impl(!newMetadata->mObjectStores.InsertOrUpdate ( objectStoreEntry.GetKey(), std::move(newOSMetadata), fallible ), "!newMetadata->mObjectStores.InsertOrUpdate( objectStoreEntry.GetKey(), std::move(newOSMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8901)) { |
8902 | return nullptr; |
8903 | } |
8904 | } |
8905 | |
8906 | MOZ_ASSERT(mObjectStores.Count() == newMetadata->mObjectStores.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(mObjectStores.Count() == newMetadata->mObjectStores .Count())>::isValid, "invalid assertion condition"); if (( __builtin_expect(!!(!(!!(mObjectStores.Count() == newMetadata ->mObjectStores.Count()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mObjectStores.Count() == newMetadata->mObjectStores.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8906); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mObjectStores.Count() == newMetadata->mObjectStores.Count()" ")"); do { *((volatile int*)__null) = 8906; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8907 | |
8908 | return newMetadata; |
8909 | } |
8910 | |
8911 | DatabaseLoggingInfo::~DatabaseLoggingInfo() { |
8912 | AssertIsOnBackgroundThread(); |
8913 | |
8914 | if (gLoggingInfoHashtable) { |
8915 | const nsID& backgroundChildLoggingId = |
8916 | mLoggingInfo.backgroundChildLoggingId(); |
8917 | |
8918 | MOZ_ASSERT(gLoggingInfoHashtable->Get(backgroundChildLoggingId) == this)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gLoggingInfoHashtable->Get(backgroundChildLoggingId ) == this)>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(gLoggingInfoHashtable->Get(backgroundChildLoggingId ) == this))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("gLoggingInfoHashtable->Get(backgroundChildLoggingId) == this" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8918); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gLoggingInfoHashtable->Get(backgroundChildLoggingId) == this" ")"); do { *((volatile int*)__null) = 8918; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8919 | |
8920 | gLoggingInfoHashtable->Remove(backgroundChildLoggingId); |
8921 | } |
8922 | } |
8923 | |
8924 | /******************************************************************************* |
8925 | * Factory |
8926 | ******************************************************************************/ |
8927 | |
8928 | Factory::Factory(RefPtr<DatabaseLoggingInfo> aLoggingInfo, |
8929 | const nsACString& aSystemLocale) |
8930 | : mSystemLocale(aSystemLocale), |
8931 | mLoggingInfo(std::move(aLoggingInfo)) |
8932 | #ifdef DEBUG1 |
8933 | , |
8934 | mActorDestroyed(false) |
8935 | #endif |
8936 | { |
8937 | AssertIsOnBackgroundThread(); |
8938 | MOZ_ASSERT(!QuotaClient::IsShuttingDownOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!QuotaClient::IsShuttingDownOnBackgroundThread())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!QuotaClient::IsShuttingDownOnBackgroundThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!QuotaClient::IsShuttingDownOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8938); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!QuotaClient::IsShuttingDownOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 8938; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8939 | } |
8940 | |
8941 | Factory::~Factory() { MOZ_ASSERT(mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8941); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mActorDestroyed" ")"); do { *((volatile int*)__null) = 8941; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } |
8942 | |
8943 | // static |
8944 | SafeRefPtr<Factory> Factory::Create(const LoggingInfo& aLoggingInfo, |
8945 | const nsACString& aSystemLocale) { |
8946 | AssertIsOnBackgroundThread(); |
8947 | MOZ_ASSERT(!QuotaClient::IsShuttingDownOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!QuotaClient::IsShuttingDownOnBackgroundThread())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!QuotaClient::IsShuttingDownOnBackgroundThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!QuotaClient::IsShuttingDownOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8947); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!QuotaClient::IsShuttingDownOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 8947; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8948 | |
8949 | // Balanced in ActoryDestroy(). |
8950 | IncreaseBusyCount(); |
8951 | |
8952 | MOZ_ASSERT(gLoggingInfoHashtable)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gLoggingInfoHashtable)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gLoggingInfoHashtable))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("gLoggingInfoHashtable" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8952); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gLoggingInfoHashtable" ")"); do { *((volatile int*)__null) = 8952; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8953 | RefPtr<DatabaseLoggingInfo> loggingInfo = |
8954 | gLoggingInfoHashtable->WithEntryHandle( |
8955 | aLoggingInfo.backgroundChildLoggingId(), [&](auto&& entry) { |
8956 | if (entry) { |
8957 | [[maybe_unused]] const auto& loggingInfo = entry.Data(); |
8958 | MOZ_ASSERT(aLoggingInfo.backgroundChildLoggingId() ==do { static_assert( mozilla::detail::AssertionConditionType< decltype(aLoggingInfo.backgroundChildLoggingId() == loggingInfo ->Id())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aLoggingInfo.backgroundChildLoggingId () == loggingInfo->Id()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aLoggingInfo.backgroundChildLoggingId() == loggingInfo->Id()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8959); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aLoggingInfo.backgroundChildLoggingId() == loggingInfo->Id()" ")"); do { *((volatile int*)__null) = 8959; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
8959 | loggingInfo->Id())do { static_assert( mozilla::detail::AssertionConditionType< decltype(aLoggingInfo.backgroundChildLoggingId() == loggingInfo ->Id())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aLoggingInfo.backgroundChildLoggingId () == loggingInfo->Id()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aLoggingInfo.backgroundChildLoggingId() == loggingInfo->Id()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8959); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aLoggingInfo.backgroundChildLoggingId() == loggingInfo->Id()" ")"); do { *((volatile int*)__null) = 8959; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8960 | #if !FUZZING |
8961 | NS_WARNING_ASSERTION(do { if (!(aLoggingInfo.nextTransactionSerialNumber() == loggingInfo ->mLoggingInfo.nextTransactionSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextTransactionSerialNumber() == loggingInfo->mLoggingInfo.nextTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8964); } } while (false) |
8962 | aLoggingInfo.nextTransactionSerialNumber() ==do { if (!(aLoggingInfo.nextTransactionSerialNumber() == loggingInfo ->mLoggingInfo.nextTransactionSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextTransactionSerialNumber() == loggingInfo->mLoggingInfo.nextTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8964); } } while (false) |
8963 | loggingInfo->mLoggingInfo.nextTransactionSerialNumber(),do { if (!(aLoggingInfo.nextTransactionSerialNumber() == loggingInfo ->mLoggingInfo.nextTransactionSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextTransactionSerialNumber() == loggingInfo->mLoggingInfo.nextTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8964); } } while (false) |
8964 | "NextTransactionSerialNumber doesn't match!")do { if (!(aLoggingInfo.nextTransactionSerialNumber() == loggingInfo ->mLoggingInfo.nextTransactionSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextTransactionSerialNumber() == loggingInfo->mLoggingInfo.nextTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8964); } } while (false); |
8965 | NS_WARNING_ASSERTION(do { if (!(aLoggingInfo.nextVersionChangeTransactionSerialNumber () == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber ())) { NS_DebugBreak(NS_DEBUG_WARNING, "NextVersionChangeTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextVersionChangeTransactionSerialNumber() == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8969); } } while (false) |
8966 | aLoggingInfo.nextVersionChangeTransactionSerialNumber() ==do { if (!(aLoggingInfo.nextVersionChangeTransactionSerialNumber () == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber ())) { NS_DebugBreak(NS_DEBUG_WARNING, "NextVersionChangeTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextVersionChangeTransactionSerialNumber() == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8969); } } while (false) |
8967 | loggingInfo->mLoggingInfodo { if (!(aLoggingInfo.nextVersionChangeTransactionSerialNumber () == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber ())) { NS_DebugBreak(NS_DEBUG_WARNING, "NextVersionChangeTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextVersionChangeTransactionSerialNumber() == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8969); } } while (false) |
8968 | .nextVersionChangeTransactionSerialNumber(),do { if (!(aLoggingInfo.nextVersionChangeTransactionSerialNumber () == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber ())) { NS_DebugBreak(NS_DEBUG_WARNING, "NextVersionChangeTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextVersionChangeTransactionSerialNumber() == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8969); } } while (false) |
8969 | "NextVersionChangeTransactionSerialNumber doesn't match!")do { if (!(aLoggingInfo.nextVersionChangeTransactionSerialNumber () == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber ())) { NS_DebugBreak(NS_DEBUG_WARNING, "NextVersionChangeTransactionSerialNumber doesn't match!" , "aLoggingInfo.nextVersionChangeTransactionSerialNumber() == loggingInfo->mLoggingInfo .nextVersionChangeTransactionSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8969); } } while (false); |
8970 | NS_WARNING_ASSERTION(do { if (!(aLoggingInfo.nextRequestSerialNumber() == loggingInfo ->mLoggingInfo.nextRequestSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextRequestSerialNumber doesn't match!", "aLoggingInfo.nextRequestSerialNumber() == loggingInfo->mLoggingInfo.nextRequestSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8973); } } while (false) |
8971 | aLoggingInfo.nextRequestSerialNumber() ==do { if (!(aLoggingInfo.nextRequestSerialNumber() == loggingInfo ->mLoggingInfo.nextRequestSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextRequestSerialNumber doesn't match!", "aLoggingInfo.nextRequestSerialNumber() == loggingInfo->mLoggingInfo.nextRequestSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8973); } } while (false) |
8972 | loggingInfo->mLoggingInfo.nextRequestSerialNumber(),do { if (!(aLoggingInfo.nextRequestSerialNumber() == loggingInfo ->mLoggingInfo.nextRequestSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextRequestSerialNumber doesn't match!", "aLoggingInfo.nextRequestSerialNumber() == loggingInfo->mLoggingInfo.nextRequestSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8973); } } while (false) |
8973 | "NextRequestSerialNumber doesn't match!")do { if (!(aLoggingInfo.nextRequestSerialNumber() == loggingInfo ->mLoggingInfo.nextRequestSerialNumber())) { NS_DebugBreak (NS_DEBUG_WARNING, "NextRequestSerialNumber doesn't match!", "aLoggingInfo.nextRequestSerialNumber() == loggingInfo->mLoggingInfo.nextRequestSerialNumber()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8973); } } while (false); |
8974 | #endif // !FUZZING |
8975 | } else { |
8976 | entry.Insert(new DatabaseLoggingInfo(aLoggingInfo)); |
8977 | } |
8978 | |
8979 | return do_AddRef(entry.Data()); |
8980 | }); |
8981 | |
8982 | return MakeSafeRefPtr<Factory>(std::move(loggingInfo), aSystemLocale); |
8983 | } |
8984 | |
8985 | void Factory::ActorDestroy(ActorDestroyReason aWhy) { |
8986 | AssertIsOnBackgroundThread(); |
8987 | MOZ_ASSERT(!mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8987); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mActorDestroyed" ")"); do { *((volatile int*)__null) = 8987; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
8988 | |
8989 | #ifdef DEBUG1 |
8990 | mActorDestroyed = true; |
8991 | #endif |
8992 | |
8993 | // Match the IncreaseBusyCount in Create(). |
8994 | DecreaseBusyCount(); |
8995 | } |
8996 | |
8997 | mozilla::ipc::IPCResult Factory::RecvDeleteMe() { |
8998 | AssertIsOnBackgroundThread(); |
8999 | MOZ_ASSERT(!mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 8999); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mActorDestroyed" ")"); do { *((volatile int*)__null) = 8999; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9000 | |
9001 | QM_WARNONLY_TRY(OkIf(PBackgroundIDBFactoryParent::Send__delete__(this))){auto tryResult967 = (OkIf(PBackgroundIDBFactoryParent::Send__delete__ (this))); static_assert(std::is_empty_v<typename decltype( tryResult967)::ok_type>); if ((__builtin_expect(!!(tryResult967 .isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(PBackgroundIDBFactoryParent::Send__delete__(this))" , tryResult967.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9001, mozilla::dom::quota::Severity::Warning); }}; |
9002 | |
9003 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9004 | } |
9005 | |
9006 | PBackgroundIDBFactoryRequestParent* |
9007 | Factory::AllocPBackgroundIDBFactoryRequestParent( |
9008 | const FactoryRequestParams& aParams) { |
9009 | AssertIsOnBackgroundThread(); |
9010 | MOZ_ASSERT(aParams.type() != FactoryRequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != FactoryRequestParams::T__None)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aParams.type() != FactoryRequestParams::T__None))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != FactoryRequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9010); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != FactoryRequestParams::T__None" ")"); do { *((volatile int*)__null) = 9010; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9011 | |
9012 | if (NS_WARN_IF(QuotaClient::IsShuttingDownOnBackgroundThread())NS_warn_if_impl(QuotaClient::IsShuttingDownOnBackgroundThread (), "QuotaClient::IsShuttingDownOnBackgroundThread()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9012)) { |
9013 | return nullptr; |
9014 | } |
9015 | |
9016 | const CommonFactoryRequestParams* commonParams; |
9017 | |
9018 | switch (aParams.type()) { |
9019 | case FactoryRequestParams::TOpenDatabaseRequestParams: { |
9020 | const OpenDatabaseRequestParams& params = |
9021 | aParams.get_OpenDatabaseRequestParams(); |
9022 | commonParams = ¶ms.commonParams(); |
9023 | break; |
9024 | } |
9025 | |
9026 | case FactoryRequestParams::TDeleteDatabaseRequestParams: { |
9027 | const DeleteDatabaseRequestParams& params = |
9028 | aParams.get_DeleteDatabaseRequestParams(); |
9029 | commonParams = ¶ms.commonParams(); |
9030 | break; |
9031 | } |
9032 | |
9033 | default: |
9034 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9034); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 9034; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
9035 | } |
9036 | |
9037 | MOZ_ASSERT(commonParams)do { static_assert( mozilla::detail::AssertionConditionType< decltype(commonParams)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(commonParams))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("commonParams", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9037); AnnotateMozCrashReason("MOZ_ASSERT" "(" "commonParams" ")"); do { *((volatile int*)__null) = 9037; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9038 | |
9039 | const DatabaseMetadata& metadata = commonParams->metadata(); |
9040 | |
9041 | if (NS_AUUF_OR_WARN_IF(!IsValidPersistenceType(metadata.persistenceType()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!IsValidPersistenceType(metadata.persistenceType())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9041); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!IsValidPersistenceType(metadata.persistenceType())" ")"); do { *((volatile int*)__null) = 9041; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!IsValidPersistenceType(metadata.persistenceType())))) { |
9042 | return nullptr; |
9043 | } |
9044 | |
9045 | const PrincipalInfo& principalInfo = commonParams->principalInfo(); |
9046 | |
9047 | if (NS_AUUF_OR_WARN_IF(!quota::IsPrincipalInfoValid(principalInfo))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!quota::IsPrincipalInfoValid(principalInfo)" ")" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9047); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!quota::IsPrincipalInfoValid(principalInfo)" ")"); do { *(( volatile int*)__null) = 9047; __attribute__((nomerge)) ::abort (); } while (false); } } while (false); } return aCond; }((!quota ::IsPrincipalInfoValid(principalInfo)))) { |
9048 | IPC_FAIL(this, "Invalid principal!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Invalid principal!" )); |
9049 | return nullptr; |
9050 | } |
9051 | |
9052 | MOZ_ASSERT(principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9053); AnnotateMozCrashReason("MOZ_ASSERT" "(" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo" ")"); do { *((volatile int*)__null) = 9053; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9053 | principalInfo.type() == PrincipalInfo::TContentPrincipalInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9053); AnnotateMozCrashReason("MOZ_ASSERT" "(" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || principalInfo.type() == PrincipalInfo::TContentPrincipalInfo" ")"); do { *((volatile int*)__null) = 9053; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9054 | |
9055 | if (NS_AUUF_OR_WARN_IF([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9057); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9057; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT )) |
9056 | principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9057); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9057; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT )) |
9057 | metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9057); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9057; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TSystemPrincipalInfo && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT ))) { |
9058 | return nullptr; |
9059 | } |
9060 | |
9061 | if (NS_AUUF_OR_WARN_IF([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9065); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9065; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo ().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT)) |
9062 | principalInfo.type() == PrincipalInfo::TContentPrincipalInfo &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9065); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9065; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo ().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT)) |
9063 | QuotaManager::IsOriginInternal([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9065); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9065; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo ().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT)) |
9064 | principalInfo.get_ContentPrincipalInfo().originNoSuffix()) &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9065); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9065; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo ().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT)) |
9065 | metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9065); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT" ")"); do { *((volatile int*)__null) = 9065; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((principalInfo.type() == PrincipalInfo::TContentPrincipalInfo && QuotaManager::IsOriginInternal( principalInfo.get_ContentPrincipalInfo ().originNoSuffix()) && metadata.persistenceType() != PERSISTENCE_TYPE_PERSISTENT))) { |
9066 | return nullptr; |
9067 | } |
9068 | |
9069 | Maybe<ContentParentId> contentParentId = GetContentParentId(); |
9070 | |
9071 | auto actor = [&]() -> RefPtr<FactoryRequestOp> { |
9072 | if (aParams.type() == FactoryRequestParams::TOpenDatabaseRequestParams) { |
9073 | return MakeRefPtr<OpenDatabaseOp>(SafeRefPtrFromThis(), contentParentId, |
9074 | *commonParams); |
9075 | } else { |
9076 | return MakeRefPtr<DeleteDatabaseOp>(SafeRefPtrFromThis(), contentParentId, |
9077 | *commonParams); |
9078 | } |
9079 | }(); |
9080 | |
9081 | gFactoryOps->AppendElement(actor); |
9082 | |
9083 | // Balanced in CleanupMetadata() which is/must always called by SendResults(). |
9084 | IncreaseBusyCount(); |
9085 | |
9086 | // Transfer ownership to IPDL. |
9087 | return actor.forget().take(); |
9088 | } |
9089 | |
9090 | mozilla::ipc::IPCResult Factory::RecvPBackgroundIDBFactoryRequestConstructor( |
9091 | PBackgroundIDBFactoryRequestParent* aActor, |
9092 | const FactoryRequestParams& aParams) { |
9093 | AssertIsOnBackgroundThread(); |
9094 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9094); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 9094; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9095 | MOZ_ASSERT(aParams.type() != FactoryRequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != FactoryRequestParams::T__None)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aParams.type() != FactoryRequestParams::T__None))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != FactoryRequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9095); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != FactoryRequestParams::T__None" ")"); do { *((volatile int*)__null) = 9095; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9096 | MOZ_ASSERT(!QuotaClient::IsShuttingDownOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!QuotaClient::IsShuttingDownOnBackgroundThread())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!QuotaClient::IsShuttingDownOnBackgroundThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!QuotaClient::IsShuttingDownOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9096); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!QuotaClient::IsShuttingDownOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 9096; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9097 | |
9098 | auto* op = static_cast<FactoryRequestOp*>(aActor); |
9099 | |
9100 | MOZ_ALWAYS_SUCCEEDS(NS_DispatchToCurrentThread(op))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (NS_DispatchToCurrentThread(op))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(NS_DispatchToCurrentThread(op))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9100); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(NS_DispatchToCurrentThread(op))" ")"); do { *((volatile int*)__null) = 9100; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9101 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9102 | } |
9103 | |
9104 | bool Factory::DeallocPBackgroundIDBFactoryRequestParent( |
9105 | PBackgroundIDBFactoryRequestParent* aActor) { |
9106 | AssertIsOnBackgroundThread(); |
9107 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9107); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 9107; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9108 | |
9109 | // Transfer ownership back from IPDL. |
9110 | RefPtr<FactoryRequestOp> op = |
9111 | dont_AddRef(static_cast<FactoryRequestOp*>(aActor)); |
9112 | return true; |
9113 | } |
9114 | |
9115 | mozilla::ipc::IPCResult Factory::RecvGetDatabases( |
9116 | const PersistenceType& aPersistenceType, |
9117 | const PrincipalInfo& aPrincipalInfo, GetDatabasesResolver&& aResolve) { |
9118 | AssertIsOnBackgroundThread(); |
9119 | |
9120 | auto ResolveGetDatabasesAndReturn = [&aResolve](const nsresult rv) { |
9121 | aResolve(rv); |
9122 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9123 | }; |
9124 | |
9125 | QM_TRY(MOZ_TO_RESULT(!QuotaClient::IsShuttingDownOnBackgroundThread()),{auto tryResult968 = (ToResult(!QuotaClient::IsShuttingDownOnBackgroundThread ())); static_assert(std::is_empty_v<typename decltype(tryResult968 )::ok_type>); if ((__builtin_expect(!!(tryResult968.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult968 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(!QuotaClient::IsShuttingDownOnBackgroundThread())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9126, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(!QuotaClient::IsShuttingDownOnBackgroundThread())" , tryTempError, ResolveGetDatabasesAndReturn); }} |
9126 | ResolveGetDatabasesAndReturn){auto tryResult968 = (ToResult(!QuotaClient::IsShuttingDownOnBackgroundThread ())); static_assert(std::is_empty_v<typename decltype(tryResult968 )::ok_type>); if ((__builtin_expect(!!(tryResult968.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult968 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(!QuotaClient::IsShuttingDownOnBackgroundThread())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9126, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(!QuotaClient::IsShuttingDownOnBackgroundThread())" , tryTempError, ResolveGetDatabasesAndReturn); }}; |
9127 | |
9128 | QM_TRY(MOZ_TO_RESULT(IsValidPersistenceType(aPersistenceType)),{auto tryResult969 = (ToResult(IsValidPersistenceType(aPersistenceType ))); static_assert(std::is_empty_v<typename decltype(tryResult969 )::ok_type>); if ((__builtin_expect(!!(tryResult969.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult969 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(IsValidPersistenceType(aPersistenceType))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9129, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(IsValidPersistenceType(aPersistenceType))" , tryTempError, mozilla::dom::quota::detail::IpcFailCustomRetVal (mozilla::WrapNotNull(this))); }} |
9129 | QM_IPC_FAIL(this)){auto tryResult969 = (ToResult(IsValidPersistenceType(aPersistenceType ))); static_assert(std::is_empty_v<typename decltype(tryResult969 )::ok_type>); if ((__builtin_expect(!!(tryResult969.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult969 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(IsValidPersistenceType(aPersistenceType))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9129, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(IsValidPersistenceType(aPersistenceType))" , tryTempError, mozilla::dom::quota::detail::IpcFailCustomRetVal (mozilla::WrapNotNull(this))); }}; |
9130 | |
9131 | QM_TRY(MOZ_TO_RESULT(quota::IsPrincipalInfoValid(aPrincipalInfo)),{auto tryResult970 = (ToResult(quota::IsPrincipalInfoValid(aPrincipalInfo ))); static_assert(std::is_empty_v<typename decltype(tryResult970 )::ok_type>); if ((__builtin_expect(!!(tryResult970.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult970 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(quota::IsPrincipalInfoValid(aPrincipalInfo))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9132, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(quota::IsPrincipalInfoValid(aPrincipalInfo))" , tryTempError, mozilla::dom::quota::detail::IpcFailCustomRetVal (mozilla::WrapNotNull(this))); }} |
9132 | QM_IPC_FAIL(this)){auto tryResult970 = (ToResult(quota::IsPrincipalInfoValid(aPrincipalInfo ))); static_assert(std::is_empty_v<typename decltype(tryResult970 )::ok_type>); if ((__builtin_expect(!!(tryResult970.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult970 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(quota::IsPrincipalInfoValid(aPrincipalInfo))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9132, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(quota::IsPrincipalInfoValid(aPrincipalInfo))" , tryTempError, mozilla::dom::quota::detail::IpcFailCustomRetVal (mozilla::WrapNotNull(this))); }}; |
9133 | |
9134 | MOZ_ASSERT(aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9135); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo" ")"); do { *((volatile int*)__null) = 9135; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9135 | aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9135); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aPrincipalInfo.type() == PrincipalInfo::TSystemPrincipalInfo || aPrincipalInfo.type() == PrincipalInfo::TContentPrincipalInfo" ")"); do { *((volatile int*)__null) = 9135; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9136 | |
9137 | PersistenceType persistenceType = |
9138 | IDBFactory::GetPersistenceType(aPrincipalInfo); |
9139 | |
9140 | QM_TRY(MOZ_TO_RESULT(aPersistenceType == persistenceType), QM_IPC_FAIL(this)){auto tryResult971 = (ToResult(aPersistenceType == persistenceType )); static_assert(std::is_empty_v<typename decltype(tryResult971 )::ok_type>); if ((__builtin_expect(!!(tryResult971.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult971 .unwrapErr(); mozilla::dom::quota::HandleError("ToResult(aPersistenceType == persistenceType)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9140, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(aPersistenceType == persistenceType)" , tryTempError, mozilla::dom::quota::detail::IpcFailCustomRetVal (mozilla::WrapNotNull(this))); }}; |
9141 | |
9142 | Maybe<ContentParentId> contentParentId = GetContentParentId(); |
9143 | |
9144 | auto op = MakeRefPtr<GetDatabasesOp>(SafeRefPtrFromThis(), contentParentId, |
9145 | aPersistenceType, aPrincipalInfo, |
9146 | std::move(aResolve)); |
9147 | |
9148 | gFactoryOps->AppendElement(op); |
9149 | |
9150 | // Balanced in CleanupMetadata() which is/must always called by SendResults(). |
9151 | IncreaseBusyCount(); |
9152 | |
9153 | MOZ_ALWAYS_SUCCEEDS(NS_DispatchToCurrentThread(op))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (NS_DispatchToCurrentThread(op))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(NS_DispatchToCurrentThread(op))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9153); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(NS_DispatchToCurrentThread(op))" ")"); do { *((volatile int*)__null) = 9153; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9154 | |
9155 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9156 | } |
9157 | |
9158 | Maybe<ContentParentId> Factory::GetContentParentId() const { |
9159 | uint64_t childID = BackgroundParent::GetChildID(Manager()); |
9160 | if (childID) { |
9161 | // If childID is not zero we are dealing with an other-process actor. We |
9162 | // want to initialize OpenDatabaseOp/DeleteDatabaseOp here with the ID |
9163 | // (and later also Database) in that case, so Database::IsOwnedByProcess |
9164 | // can find Databases belonging to a particular content process when |
9165 | // QuotaClient::AbortOperationsForProcess is called which is currently used |
9166 | // to abort operations for content processes only. |
9167 | return Some(ContentParentId(childID)); |
9168 | } |
9169 | |
9170 | return Nothing(); |
9171 | } |
9172 | |
9173 | /******************************************************************************* |
9174 | * WaitForTransactionsHelper |
9175 | ******************************************************************************/ |
9176 | |
9177 | void WaitForTransactionsHelper::WaitForTransactions() { |
9178 | MOZ_ASSERT(mState == State::Initial)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Initial)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Initial))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mState == State::Initial" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9178); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial" ")"); do { *((volatile int*)__null) = 9178; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9179 | |
9180 | Unused << this->Run(); |
9181 | } |
9182 | |
9183 | void WaitForTransactionsHelper::MaybeWaitForTransactions() { |
9184 | AssertIsOnBackgroundThread(); |
9185 | MOZ_ASSERT(mState == State::Initial)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Initial)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState == State::Initial))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mState == State::Initial" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9185); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial" ")"); do { *((volatile int*)__null) = 9185; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9186 | |
9187 | RefPtr<ConnectionPool> connectionPool = gConnectionPool.get(); |
9188 | if (connectionPool) { |
9189 | mState = State::WaitingForTransactions; |
9190 | |
9191 | connectionPool->WaitForDatabaseToComplete(mDatabaseId, this); |
9192 | |
9193 | return; |
9194 | } |
9195 | |
9196 | CallCallback(); |
9197 | } |
9198 | |
9199 | void WaitForTransactionsHelper::CallCallback() { |
9200 | AssertIsOnBackgroundThread(); |
9201 | MOZ_ASSERT(mState == State::Initial ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Initial || mState == State::WaitingForTransactions )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mState == State::Initial || mState == State::WaitingForTransactions ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "mState == State::Initial || mState == State::WaitingForTransactions" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9202); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial || mState == State::WaitingForTransactions" ")"); do { *((volatile int*)__null) = 9202; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9202 | mState == State::WaitingForTransactions)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState == State::Initial || mState == State::WaitingForTransactions )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mState == State::Initial || mState == State::WaitingForTransactions ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "mState == State::Initial || mState == State::WaitingForTransactions" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9202); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState == State::Initial || mState == State::WaitingForTransactions" ")"); do { *((volatile int*)__null) = 9202; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9203 | |
9204 | const nsCOMPtr<nsIRunnable> callback = std::move(mCallback); |
9205 | |
9206 | callback->Run(); |
9207 | |
9208 | mState = State::Complete; |
9209 | } |
9210 | |
9211 | NS_IMETHODIMPnsresult |
9212 | WaitForTransactionsHelper::Run() { |
9213 | MOZ_ASSERT(mState != State::Complete)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mState != State::Complete)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mState != State::Complete))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("mState != State::Complete" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9213); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mState != State::Complete" ")"); do { *((volatile int*)__null) = 9213; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9214 | MOZ_ASSERT(mCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mCallback)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mCallback", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9214); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCallback" ")" ); do { *((volatile int*)__null) = 9214; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9215 | |
9216 | switch (mState) { |
9217 | case State::Initial: |
9218 | MaybeWaitForTransactions(); |
9219 | break; |
9220 | |
9221 | case State::WaitingForTransactions: |
9222 | CallCallback(); |
9223 | break; |
9224 | |
9225 | default: |
9226 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9226); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 9226; __attribute__((nomerge )) ::abort(); } while (false); } while (false); |
9227 | } |
9228 | |
9229 | return NS_OK; |
9230 | } |
9231 | |
9232 | /******************************************************************************* |
9233 | * Database |
9234 | ******************************************************************************/ |
9235 | |
9236 | Database::Database(SafeRefPtr<Factory> aFactory, |
9237 | const PrincipalInfo& aPrincipalInfo, |
9238 | const Maybe<ContentParentId>& aOptionalContentParentId, |
9239 | const quota::OriginMetadata& aOriginMetadata, |
9240 | uint32_t aTelemetryId, |
9241 | SafeRefPtr<FullDatabaseMetadata> aMetadata, |
9242 | SafeRefPtr<DatabaseFileManager> aFileManager, |
9243 | RefPtr<ClientDirectoryLock> aDirectoryLock, |
9244 | bool aInPrivateBrowsing, |
9245 | const Maybe<const CipherKey>& aMaybeKey) |
9246 | : mFactory(std::move(aFactory)), |
9247 | mMetadata(std::move(aMetadata)), |
9248 | mFileManager(std::move(aFileManager)), |
9249 | mDirectoryLock(std::move(aDirectoryLock)), |
9250 | mPrincipalInfo(aPrincipalInfo), |
9251 | mOptionalContentParentId(aOptionalContentParentId), |
9252 | mOriginMetadata(aOriginMetadata), |
9253 | mId(mMetadata->mDatabaseId), |
9254 | mFilePath(mMetadata->mFilePath), |
9255 | mKey(aMaybeKey), |
9256 | mTelemetryId(aTelemetryId), |
9257 | mPersistenceType(mMetadata->mCommonMetadata.persistenceType()), |
9258 | mInPrivateBrowsing(aInPrivateBrowsing), |
9259 | mBackgroundThread(GetCurrentSerialEventTarget()) |
9260 | #ifdef DEBUG1 |
9261 | , |
9262 | mAllBlobsUnmapped(false) |
9263 | #endif |
9264 | { |
9265 | AssertIsOnBackgroundThread(); |
9266 | MOZ_ASSERT(mFactory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFactory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFactory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFactory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9266); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFactory" ")" ); do { *((volatile int*)__null) = 9266; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9267 | MOZ_ASSERT(mMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9267); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mMetadata" ")" ); do { *((volatile int*)__null) = 9267; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9268 | MOZ_ASSERT(mFileManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mFileManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mFileManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mFileManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9268); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mFileManager" ")"); do { *((volatile int*)__null) = 9268; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9269 | |
9270 | MOZ_ASSERT(mDirectoryLock)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDirectoryLock)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDirectoryLock))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDirectoryLock" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9270); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDirectoryLock" ")"); do { *((volatile int*)__null) = 9270; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9271 | MOZ_ASSERT(mDirectoryLock->Id() >= 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDirectoryLock->Id() >= 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDirectoryLock->Id() >= 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("mDirectoryLock->Id() >= 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9271); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDirectoryLock->Id() >= 0" ")"); do { *((volatile int*)__null) = 9271; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9272 | mDirectoryLockId = mDirectoryLock->Id(); |
9273 | } |
9274 | |
9275 | template <typename T> |
9276 | bool Database::InvalidateAll(const nsTBaseHashSet<nsPtrHashKey<T>>& aTable) { |
9277 | AssertIsOnBackgroundThread(); |
9278 | |
9279 | const uint32_t count = aTable.Count(); |
9280 | if (!count) { |
9281 | return true; |
9282 | } |
9283 | |
9284 | // XXX Does this really need to be fallible? |
9285 | QM_TRY_INSPECT(const auto& elementsToInvalidate,auto tryResult972 = (TransformIntoNewArray( aTable, [](const auto & entry) { return entry; }, fallible)); if ((__builtin_expect (!!(tryResult972.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult972.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9288, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, false); } const auto& elementsToInvalidate = tryResult972.inspect(); |
9286 | TransformIntoNewArray(auto tryResult972 = (TransformIntoNewArray( aTable, [](const auto & entry) { return entry; }, fallible)); if ((__builtin_expect (!!(tryResult972.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult972.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9288, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, false); } const auto& elementsToInvalidate = tryResult972.inspect(); |
9287 | aTable, [](const auto& entry) { return entry; }, fallible),auto tryResult972 = (TransformIntoNewArray( aTable, [](const auto & entry) { return entry; }, fallible)); if ((__builtin_expect (!!(tryResult972.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult972.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9288, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, false); } const auto& elementsToInvalidate = tryResult972.inspect(); |
9288 | false)auto tryResult972 = (TransformIntoNewArray( aTable, [](const auto & entry) { return entry; }, fallible)); if ((__builtin_expect (!!(tryResult972.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult972.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9288, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArray( aTable, [](const auto& entry) { return entry; }, fallible)" , tryTempError, false); } const auto& elementsToInvalidate = tryResult972.inspect();; |
9289 | |
9290 | IDB_REPORT_INTERNAL_ERR()mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9290, "UnknownErr"); |
9291 | |
9292 | for (const auto& elementToInvalidate : elementsToInvalidate) { |
9293 | MOZ_ASSERT(elementToInvalidate)do { static_assert( mozilla::detail::AssertionConditionType< decltype(elementToInvalidate)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(elementToInvalidate))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("elementToInvalidate" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9293); AnnotateMozCrashReason("MOZ_ASSERT" "(" "elementToInvalidate" ")"); do { *((volatile int*)__null) = 9293; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9294 | |
9295 | elementToInvalidate->Invalidate(); |
9296 | } |
9297 | |
9298 | return true; |
9299 | } |
9300 | |
9301 | void Database::Invalidate() { |
9302 | AssertIsOnBackgroundThread(); |
9303 | |
9304 | if (mInvalidated) { |
9305 | return; |
9306 | } |
9307 | |
9308 | mInvalidated.Flip(); |
9309 | |
9310 | if (mActorWasAlive && !mActorDestroyed) { |
9311 | Unused << SendInvalidate(); |
9312 | } |
9313 | |
9314 | QM_WARNONLY_TRY(OkIf(InvalidateAll(mTransactions))){auto tryResult973 = (OkIf(InvalidateAll(mTransactions))); static_assert (std::is_empty_v<typename decltype(tryResult973)::ok_type> ); if ((__builtin_expect(!!(tryResult973.isErr()), 0))) { mozilla ::dom::quota::HandleError("OkIf(InvalidateAll(mTransactions))" , tryResult973.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9314, mozilla::dom::quota::Severity::Warning); }}; |
9315 | |
9316 | MOZ_ALWAYS_TRUE(CloseInternal())do { if ((__builtin_expect(!!(CloseInternal()), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "CloseInternal()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9316); AnnotateMozCrashReason("MOZ_CRASH(" "CloseInternal()" ")"); do { *((volatile int*)__null) = 9316; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9317 | } |
9318 | |
9319 | nsresult Database::EnsureConnection() { |
9320 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9320); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 9320; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9321 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9321); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 9321; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9322 | |
9323 | AUTO_PROFILER_LABEL("Database::EnsureConnection", DOM)mozilla::AutoProfilerLabel raiiObject9323( "Database::EnsureConnection" , nullptr, JS::ProfilingCategoryPair::DOM); |
9324 | |
9325 | if (!mConnection || !mConnection->HasStorageConnection()) { |
9326 | QM_TRY_UNWRAP(mConnection, gConnectionPool->GetOrCreateConnection(*this))auto tryResult974 = (gConnectionPool->GetOrCreateConnection (*this)); if ((__builtin_expect(!!(tryResult974.isErr()), 0)) ) { mozilla::dom::quota::HandleError("gConnectionPool->GetOrCreateConnection(*this)" , tryResult974.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9326, mozilla::dom::quota::Severity::Error); return tryResult974 .propagateErr(); } mConnection = tryResult974.unwrap();; |
9327 | } |
9328 | |
9329 | AssertIsOnConnectionThread(); |
9330 | |
9331 | return NS_OK; |
9332 | } |
9333 | |
9334 | bool Database::RegisterTransaction(TransactionBase& aTransaction) { |
9335 | AssertIsOnBackgroundThread(); |
9336 | MOZ_ASSERT(!mTransactions.Contains(&aTransaction))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Contains(&aTransaction))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mTransactions.Contains(&aTransaction)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Contains(&aTransaction)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9336); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Contains(&aTransaction)" ")"); do { *((volatile int*)__null) = 9336; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9337 | MOZ_ASSERT(mDirectoryLock)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDirectoryLock)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDirectoryLock))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDirectoryLock" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9337); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDirectoryLock" ")"); do { *((volatile int*)__null) = 9337; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9338 | MOZ_ASSERT(!mInvalidated)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mInvalidated)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mInvalidated))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mInvalidated", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9338); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mInvalidated" ")"); do { *((volatile int*)__null) = 9338; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9339 | MOZ_ASSERT(!mClosed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mClosed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mClosed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mClosed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9339); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mClosed" ")" ); do { *((volatile int*)__null) = 9339; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9340 | |
9341 | if (NS_WARN_IF(!mTransactions.Insert(&aTransaction, fallible))NS_warn_if_impl(!mTransactions.Insert(&aTransaction, fallible ), "!mTransactions.Insert(&aTransaction, fallible)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9341)) { |
9342 | return false; |
9343 | } |
9344 | |
9345 | return true; |
9346 | } |
9347 | |
9348 | void Database::UnregisterTransaction(TransactionBase& aTransaction) { |
9349 | AssertIsOnBackgroundThread(); |
9350 | MOZ_ASSERT(mTransactions.Contains(&aTransaction))do { static_assert( mozilla::detail::AssertionConditionType< decltype(mTransactions.Contains(&aTransaction))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mTransactions.Contains(&aTransaction)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mTransactions.Contains(&aTransaction)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9350); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mTransactions.Contains(&aTransaction)" ")"); do { *((volatile int*)__null) = 9350; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9351 | |
9352 | mTransactions.Remove(&aTransaction); |
9353 | |
9354 | MaybeCloseConnection(); |
9355 | } |
9356 | |
9357 | void Database::SetActorAlive() { |
9358 | AssertIsOnBackgroundThread(); |
9359 | MOZ_ASSERT(!mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9359); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mActorDestroyed" ")"); do { *((volatile int*)__null) = 9359; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9360 | |
9361 | mActorWasAlive.Flip(); |
9362 | } |
9363 | |
9364 | void Database::MapBlob(const IPCBlob& aIPCBlob, |
9365 | SafeRefPtr<DatabaseFileInfo> aFileInfo) { |
9366 | AssertIsOnBackgroundThread(); |
9367 | |
9368 | const RemoteLazyStream& stream = aIPCBlob.inputStream(); |
9369 | MOZ_ASSERT(stream.type() == RemoteLazyStream::TRemoteLazyInputStream)do { static_assert( mozilla::detail::AssertionConditionType< decltype(stream.type() == RemoteLazyStream::TRemoteLazyInputStream )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(stream.type() == RemoteLazyStream::TRemoteLazyInputStream ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "stream.type() == RemoteLazyStream::TRemoteLazyInputStream", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9369); AnnotateMozCrashReason("MOZ_ASSERT" "(" "stream.type() == RemoteLazyStream::TRemoteLazyInputStream" ")"); do { *((volatile int*)__null) = 9369; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9370 | |
9371 | nsID id{}; |
9372 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (stream.get_RemoteLazyInputStream()->GetInternalStreamID(id ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(stream.get_RemoteLazyInputStream()->GetInternalStreamID(id))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9373); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(stream.get_RemoteLazyInputStream()->GetInternalStreamID(id))" ")"); do { *((volatile int*)__null) = 9373; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ) |
9373 | stream.get_RemoteLazyInputStream()->GetInternalStreamID(id))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (stream.get_RemoteLazyInputStream()->GetInternalStreamID(id ))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(stream.get_RemoteLazyInputStream()->GetInternalStreamID(id))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9373); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(stream.get_RemoteLazyInputStream()->GetInternalStreamID(id))" ")"); do { *((volatile int*)__null) = 9373; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9374 | |
9375 | MOZ_ASSERT(!mMappedBlobs.Contains(id))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mMappedBlobs.Contains(id))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mMappedBlobs.Contains(id))) ), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mMappedBlobs.Contains(id)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9375); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mMappedBlobs.Contains(id)" ")"); do { *((volatile int*)__null) = 9375; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9376 | mMappedBlobs.InsertOrUpdate(id, std::move(aFileInfo)); |
9377 | |
9378 | RefPtr<UnmapBlobCallback> callback = |
9379 | new UnmapBlobCallback(SafeRefPtrFromThis()); |
9380 | |
9381 | auto storage = RemoteLazyInputStreamStorage::Get(); |
9382 | MOZ_ASSERT(storage.isOk())do { static_assert( mozilla::detail::AssertionConditionType< decltype(storage.isOk())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(storage.isOk()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("storage.isOk()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9382); AnnotateMozCrashReason("MOZ_ASSERT" "(" "storage.isOk()" ")"); do { *((volatile int*)__null) = 9382; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9383 | storage.inspect()->StoreCallback(id, callback); |
9384 | } |
9385 | |
9386 | void Database::Stringify(nsACString& aResult) const { |
9387 | AssertIsOnBackgroundThread(); |
9388 | |
9389 | constexpr auto kQuotaGenericDelimiterString = "|"_ns; |
9390 | |
9391 | aResult.Append( |
9392 | "DirectoryLock:"_ns + IntToCString(!!mDirectoryLock) + |
9393 | kQuotaGenericDelimiterString + |
9394 | // |
9395 | "Transactions:"_ns + IntToCString(mTransactions.Count()) + |
9396 | kQuotaGenericDelimiterString + |
9397 | // |
9398 | "OtherProcessActor:"_ns + |
9399 | IntToCString( |
9400 | BackgroundParent::IsOtherProcessActor(GetBackgroundParent())) + |
9401 | kQuotaGenericDelimiterString + |
9402 | // |
9403 | "Origin:"_ns + AnonymizedOriginString(mOriginMetadata.mOrigin) + |
9404 | kQuotaGenericDelimiterString + |
9405 | // |
9406 | "PersistenceType:"_ns + PersistenceTypeToString(mPersistenceType) + |
9407 | kQuotaGenericDelimiterString + |
9408 | // |
9409 | "Closed:"_ns + IntToCString(static_cast<bool>(mClosed)) + |
9410 | kQuotaGenericDelimiterString + |
9411 | // |
9412 | "Invalidated:"_ns + IntToCString(static_cast<bool>(mInvalidated)) + |
9413 | kQuotaGenericDelimiterString + |
9414 | // |
9415 | "ActorWasAlive:"_ns + IntToCString(static_cast<bool>(mActorWasAlive)) + |
9416 | kQuotaGenericDelimiterString + |
9417 | // |
9418 | "ActorDestroyed:"_ns + IntToCString(static_cast<bool>(mActorDestroyed))); |
9419 | } |
9420 | |
9421 | SafeRefPtr<DatabaseFileInfo> Database::GetBlob(const IPCBlob& aIPCBlob) { |
9422 | AssertIsOnBackgroundThread(); |
9423 | |
9424 | RefPtr<RemoteLazyInputStream> lazyStream; |
9425 | switch (aIPCBlob.inputStream().type()) { |
9426 | case RemoteLazyStream::TIPCStream: { |
9427 | const InputStreamParams& inputStreamParams = |
9428 | aIPCBlob.inputStream().get_IPCStream().stream(); |
9429 | if (inputStreamParams.type() != |
9430 | InputStreamParams::TRemoteLazyInputStreamParams) { |
9431 | return nullptr; |
9432 | } |
9433 | lazyStream = inputStreamParams.get_RemoteLazyInputStreamParams().stream(); |
9434 | break; |
9435 | } |
9436 | case RemoteLazyStream::TRemoteLazyInputStream: |
9437 | lazyStream = aIPCBlob.inputStream().get_RemoteLazyInputStream(); |
9438 | break; |
9439 | default: |
9440 | MOZ_ASSERT_UNREACHABLE("Unknown RemoteLazyStream type")do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" "MOZ_ASSERT_UNREACHABLE: " "Unknown RemoteLazyStream type" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9440); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "MOZ_ASSERT_UNREACHABLE: " "Unknown RemoteLazyStream type" ")" ); do { *((volatile int*)__null) = 9440; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9441 | return nullptr; |
9442 | } |
9443 | |
9444 | if (!lazyStream) { |
9445 | MOZ_ASSERT_UNREACHABLE("Unexpected null stream")do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" "MOZ_ASSERT_UNREACHABLE: " "Unexpected null stream" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9445); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "MOZ_ASSERT_UNREACHABLE: " "Unexpected null stream" ")"); do { *((volatile int*)__null) = 9445; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); |
9446 | return nullptr; |
9447 | } |
9448 | |
9449 | nsID id{}; |
9450 | nsresult rv = lazyStream->GetInternalStreamID(id); |
9451 | if (NS_FAILED(rv)((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { |
9452 | MOZ_ASSERT_UNREACHABLE(do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" "MOZ_ASSERT_UNREACHABLE: " "Received RemoteLazyInputStream doesn't have an actor connection" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9453); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "MOZ_ASSERT_UNREACHABLE: " "Received RemoteLazyInputStream doesn't have an actor connection" ")"); do { *((volatile int*)__null) = 9453; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9453 | "Received RemoteLazyInputStream doesn't have an actor connection")do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" "MOZ_ASSERT_UNREACHABLE: " "Received RemoteLazyInputStream doesn't have an actor connection" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9453); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "MOZ_ASSERT_UNREACHABLE: " "Received RemoteLazyInputStream doesn't have an actor connection" ")"); do { *((volatile int*)__null) = 9453; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9454 | return nullptr; |
9455 | } |
9456 | |
9457 | const auto fileInfo = mMappedBlobs.Lookup(id); |
9458 | return fileInfo ? fileInfo->clonePtr() : nullptr; |
9459 | } |
9460 | |
9461 | void Database::UnmapBlob(const nsID& aID) { |
9462 | AssertIsOnBackgroundThread(); |
9463 | |
9464 | MOZ_ASSERT_IF(!mAllBlobsUnmapped, mMappedBlobs.Contains(aID))do { if (!mAllBlobsUnmapped) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(mMappedBlobs.Contains(aID ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mMappedBlobs.Contains(aID)))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("mMappedBlobs.Contains(aID)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9464); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mMappedBlobs.Contains(aID)" ")"); do { *((volatile int*)__null) = 9464; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
9465 | mMappedBlobs.Remove(aID); |
9466 | } |
9467 | |
9468 | void Database::UnmapAllBlobs() { |
9469 | AssertIsOnBackgroundThread(); |
9470 | |
9471 | #ifdef DEBUG1 |
9472 | mAllBlobsUnmapped = true; |
9473 | #endif |
9474 | |
9475 | mMappedBlobs.Clear(); |
9476 | } |
9477 | |
9478 | bool Database::CloseInternal() { |
9479 | AssertIsOnBackgroundThread(); |
9480 | |
9481 | if (mClosed) { |
9482 | if (NS_WARN_IF(!IsInvalidated())NS_warn_if_impl(!IsInvalidated(), "!IsInvalidated()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9482)) { |
9483 | // Signal misbehaving child for sending the close message twice. |
9484 | return false; |
9485 | } |
9486 | |
9487 | // Ignore harmless race when we just invalidated the database. |
9488 | return true; |
9489 | } |
9490 | |
9491 | mClosed.Flip(); |
9492 | |
9493 | if (gConnectionPool) { |
9494 | gConnectionPool->CloseDatabaseWhenIdle(Id()); |
9495 | } |
9496 | |
9497 | DatabaseActorInfo* info; |
9498 | MOZ_ALWAYS_TRUE(gLiveDatabaseHashtable->Get(Id(), &info))do { if ((__builtin_expect(!!(gLiveDatabaseHashtable->Get( Id(), &info)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "gLiveDatabaseHashtable->Get(Id(), &info)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9498); AnnotateMozCrashReason("MOZ_CRASH(" "gLiveDatabaseHashtable->Get(Id(), &info)" ")"); do { *((volatile int*)__null) = 9498; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9499 | |
9500 | MOZ_ASSERT(info->mLiveDatabases.Contains(this))do { static_assert( mozilla::detail::AssertionConditionType< decltype(info->mLiveDatabases.Contains(this))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(info->mLiveDatabases.Contains(this)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("info->mLiveDatabases.Contains(this)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9500); AnnotateMozCrashReason("MOZ_ASSERT" "(" "info->mLiveDatabases.Contains(this)" ")"); do { *((volatile int*)__null) = 9500; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9501 | |
9502 | if (info->mWaitingFactoryOp) { |
9503 | info->mWaitingFactoryOp->NoteDatabaseClosed(this); |
9504 | } |
9505 | |
9506 | MaybeCloseConnection(); |
9507 | |
9508 | return true; |
9509 | } |
9510 | |
9511 | void Database::MaybeCloseConnection() { |
9512 | AssertIsOnBackgroundThread(); |
9513 | |
9514 | if (!mTransactions.Count() && IsClosed() && mDirectoryLock) { |
9515 | nsCOMPtr<nsIRunnable> callback = |
9516 | NewRunnableMethod("dom::indexedDB::Database::ConnectionClosedCallback", |
9517 | this, &Database::ConnectionClosedCallback); |
9518 | |
9519 | RefPtr<WaitForTransactionsHelper> helper = |
9520 | new WaitForTransactionsHelper(Id(), callback); |
9521 | helper->WaitForTransactions(); |
9522 | } |
9523 | } |
9524 | |
9525 | void Database::ConnectionClosedCallback() { |
9526 | AssertIsOnBackgroundThread(); |
9527 | MOZ_ASSERT(mClosed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mClosed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mClosed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mClosed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9527); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mClosed" ")" ); do { *((volatile int*)__null) = 9527; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9528 | MOZ_ASSERT(!mTransactions.Count())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mTransactions.Count())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mTransactions.Count()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mTransactions.Count()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9528); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mTransactions.Count()" ")"); do { *((volatile int*)__null) = 9528; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9529 | |
9530 | DropDirectoryLock(mDirectoryLock); |
9531 | |
9532 | CleanupMetadata(); |
9533 | |
9534 | UnmapAllBlobs(); |
9535 | |
9536 | if (IsInvalidated() && IsActorAlive()) { |
9537 | // Step 3 and 4 of "5.2 Closing a Database": |
9538 | // 1. Wait for all transactions to complete. |
9539 | // 2. Fire a close event if forced flag is set, i.e., IsInvalidated() in our |
9540 | // implementation. |
9541 | Unused << SendCloseAfterInvalidationComplete(); |
9542 | } |
9543 | } |
9544 | |
9545 | void Database::CleanupMetadata() { |
9546 | AssertIsOnBackgroundThread(); |
9547 | |
9548 | DatabaseActorInfo* info; |
9549 | MOZ_ALWAYS_TRUE(gLiveDatabaseHashtable->Get(Id(), &info))do { if ((__builtin_expect(!!(gLiveDatabaseHashtable->Get( Id(), &info)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "gLiveDatabaseHashtable->Get(Id(), &info)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9549); AnnotateMozCrashReason("MOZ_CRASH(" "gLiveDatabaseHashtable->Get(Id(), &info)" ")"); do { *((volatile int*)__null) = 9549; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9550 | MOZ_ALWAYS_TRUE(info->mLiveDatabases.RemoveElement(this))do { if ((__builtin_expect(!!(info->mLiveDatabases.RemoveElement (this)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "info->mLiveDatabases.RemoveElement(this)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9550); AnnotateMozCrashReason("MOZ_CRASH(" "info->mLiveDatabases.RemoveElement(this)" ")"); do { *((volatile int*)__null) = 9550; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9551 | |
9552 | QuotaManager::MaybeRecordQuotaClientShutdownStep( |
9553 | quota::Client::IDB, "Live database entry removed"_ns); |
9554 | |
9555 | if (info->mLiveDatabases.IsEmpty()) { |
9556 | MOZ_ASSERT(!info->mWaitingFactoryOp ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(!info->mWaitingFactoryOp || !info->mWaitingFactoryOp ->HasBlockedDatabases())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!info->mWaitingFactoryOp || !info->mWaitingFactoryOp->HasBlockedDatabases()))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("!info->mWaitingFactoryOp || !info->mWaitingFactoryOp->HasBlockedDatabases()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9557); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!info->mWaitingFactoryOp || !info->mWaitingFactoryOp->HasBlockedDatabases()" ")"); do { *((volatile int*)__null) = 9557; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9557 | !info->mWaitingFactoryOp->HasBlockedDatabases())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!info->mWaitingFactoryOp || !info->mWaitingFactoryOp ->HasBlockedDatabases())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!info->mWaitingFactoryOp || !info->mWaitingFactoryOp->HasBlockedDatabases()))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("!info->mWaitingFactoryOp || !info->mWaitingFactoryOp->HasBlockedDatabases()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9557); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!info->mWaitingFactoryOp || !info->mWaitingFactoryOp->HasBlockedDatabases()" ")"); do { *((volatile int*)__null) = 9557; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9558 | gLiveDatabaseHashtable->Remove(Id()); |
9559 | |
9560 | QuotaManager::MaybeRecordQuotaClientShutdownStep( |
9561 | quota::Client::IDB, "gLiveDatabaseHashtable entry removed"_ns); |
9562 | } |
9563 | |
9564 | // Match the IncreaseBusyCount in OpenDatabaseOp::EnsureDatabaseActor(). |
9565 | DecreaseBusyCount(); |
9566 | } |
9567 | |
9568 | void Database::ActorDestroy(ActorDestroyReason aWhy) { |
9569 | AssertIsOnBackgroundThread(); |
9570 | |
9571 | mActorDestroyed.Flip(); |
9572 | |
9573 | if (!IsInvalidated()) { |
9574 | Invalidate(); |
9575 | } |
9576 | } |
9577 | |
9578 | PBackgroundIDBDatabaseFileParent* |
9579 | Database::AllocPBackgroundIDBDatabaseFileParent(const IPCBlob& aIPCBlob) { |
9580 | AssertIsOnBackgroundThread(); |
9581 | |
9582 | SafeRefPtr<DatabaseFileInfo> fileInfo = GetBlob(aIPCBlob); |
9583 | RefPtr<DatabaseFile> actor; |
9584 | |
9585 | if (fileInfo) { |
9586 | actor = new DatabaseFile(std::move(fileInfo)); |
9587 | } else { |
9588 | // This is a blob we haven't seen before. |
9589 | fileInfo = mFileManager->CreateFileInfo(); |
9590 | if (NS_WARN_IF(!fileInfo)NS_warn_if_impl(!fileInfo, "!fileInfo", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9590)) { |
9591 | return nullptr; |
9592 | } |
9593 | |
9594 | actor = new DatabaseFile(IPCBlobUtils::Deserialize(aIPCBlob), |
9595 | std::move(fileInfo)); |
9596 | } |
9597 | |
9598 | MOZ_ASSERT(actor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(actor)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(actor))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("actor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9598); AnnotateMozCrashReason("MOZ_ASSERT" "(" "actor" ")") ; do { *((volatile int*)__null) = 9598; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9599 | |
9600 | return actor.forget().take(); |
9601 | } |
9602 | |
9603 | bool Database::DeallocPBackgroundIDBDatabaseFileParent( |
9604 | PBackgroundIDBDatabaseFileParent* aActor) { |
9605 | AssertIsOnBackgroundThread(); |
9606 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9606); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 9606; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9607 | |
9608 | RefPtr<DatabaseFile> actor = dont_AddRef(static_cast<DatabaseFile*>(aActor)); |
9609 | return true; |
9610 | } |
9611 | |
9612 | already_AddRefed<PBackgroundIDBTransactionParent> |
9613 | Database::AllocPBackgroundIDBTransactionParent( |
9614 | const nsTArray<nsString>& aObjectStoreNames, const Mode& aMode, |
9615 | const Durability& aDurability) { |
9616 | AssertIsOnBackgroundThread(); |
9617 | |
9618 | // Once a database is closed it must not try to open new transactions. |
9619 | if (NS_WARN_IF(mClosed)NS_warn_if_impl(mClosed, "mClosed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9619)) { |
9620 | MOZ_ASSERT_UNLESS_FUZZING(mInvalidated)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInvalidated)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mInvalidated))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInvalidated", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9620); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInvalidated" ")"); do { *((volatile int*)__null) = 9620; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9621 | return nullptr; |
9622 | } |
9623 | |
9624 | if (NS_AUUF_OR_WARN_IF(aObjectStoreNames.IsEmpty())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aObjectStoreNames.IsEmpty()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9624); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aObjectStoreNames.IsEmpty()" ")"); do { *((volatile int*)__null ) = 9624; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((aObjectStoreNames.IsEmpty ()))) { |
9625 | return nullptr; |
9626 | } |
9627 | |
9628 | if (NS_AUUF_OR_WARN_IF(aMode != IDBTransaction::Mode::ReadOnly &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9631); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9631; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction ::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode ::Cleanup)) |
9629 | aMode != IDBTransaction::Mode::ReadWrite &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9631); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9631; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction ::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode ::Cleanup)) |
9630 | aMode != IDBTransaction::Mode::ReadWriteFlush &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9631); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9631; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction ::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode ::Cleanup)) |
9631 | aMode != IDBTransaction::Mode::Cleanup)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9631); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9631; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aMode != IDBTransaction::Mode::ReadOnly && aMode != IDBTransaction::Mode::ReadWrite && aMode != IDBTransaction ::Mode::ReadWriteFlush && aMode != IDBTransaction::Mode ::Cleanup))) { |
9632 | return nullptr; |
9633 | } |
9634 | |
9635 | if (NS_AUUF_OR_WARN_IF(aDurability != IDBTransaction::Durability::Default &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9637); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed" ")"); do { *((volatile int*)__null) = 9637; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed)) |
9636 | aDurability != IDBTransaction::Durability::Strict &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9637); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed" ")"); do { *((volatile int*)__null) = 9637; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed)) |
9637 | aDurability != IDBTransaction::Durability::Relaxed)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9637); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed" ")"); do { *((volatile int*)__null) = 9637; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((aDurability != IDBTransaction::Durability::Default && aDurability != IDBTransaction::Durability::Strict && aDurability != IDBTransaction::Durability::Relaxed))) { |
9638 | return nullptr; |
9639 | } |
9640 | |
9641 | const ObjectStoreTable& objectStores = mMetadata->mObjectStores; |
9642 | const uint32_t nameCount = aObjectStoreNames.Length(); |
9643 | |
9644 | if (NS_AUUF_OR_WARN_IF(nameCount > objectStores.Count())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "nameCount > objectStores.Count()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9644); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "nameCount > objectStores.Count()" ")"); do { *((volatile int*)__null) = 9644; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((nameCount > objectStores.Count()))) { |
9645 | return nullptr; |
9646 | } |
9647 | |
9648 | QM_TRY_UNWRAP(auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9649 | auto objectStoreMetadatas,auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9650 | TransformIntoNewArrayAbortOnErr(auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9651 | aObjectStoreNames,auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9652 | [lastName = Maybe<const nsString&>{},auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9653 | &objectStores](const nsString& name) mutableauto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9654 | -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> {auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9655 | if (lastName) {auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9656 | // Make sure that this name is sorted properly and not aauto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9657 | // duplicate.auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9658 | if (NS_AUUF_OR_WARN_IF(name <= lastName.ref())) {auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9659 | return Err(NS_ERROR_FAILURE);auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9660 | }auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9661 | }auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9662 | lastName = SomeRef(name);auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9663 | |
9664 | const auto foundIt =auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9665 | std::find_if(objectStores.cbegin(), objectStores.cend(),auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9666 | [&name](const auto& entry) {auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9667 | const auto& value = entry.GetData();auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9668 | MOZ_ASSERT(entry.GetKey());auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9669 | return name == value->mCommonMetadata.name() &&auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9670 | !value->mDeleted;auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9671 | });auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9672 | if (foundIt == objectStores.cend()) {auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9673 | MOZ_ASSERT_UNLESS_FUZZING(false, "ObjectStore not found.");auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9674 | return Err(NS_ERROR_FAILURE);auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9675 | }auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9676 | |
9677 | return foundIt->GetData().clonePtr();auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9678 | },auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9679 | fallible),auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap(); |
9680 | nullptr)auto tryResult975 = (TransformIntoNewArrayAbortOnErr( aObjectStoreNames , [lastName = Maybe<const nsString&>{}, &objectStores ](const nsString& name) mutable -> mozilla::Result< SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if ( lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond ), 0))) { do { static_assert( mozilla::detail::AssertionConditionType <decltype(false)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("false" " (" "name <= lastName.ref()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9658); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "name <= lastName.ref()" ")"); do { *((volatile int*)__null ) = 9658; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((name <= lastName.ref ()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef( name); const auto foundIt = std::find_if(objectStores.cbegin( ), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla ::detail::AssertionConditionType<decltype(entry.GetKey())> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("entry.GetKey()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9668); AnnotateMozCrashReason("MOZ_ASSERT" "(" "entry.GetKey()" ")"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted ; }); if (foundIt == objectStores.cend()) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(false)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "ObjectStore not found." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9673); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "ObjectStore not found." ")"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt ->GetData().clonePtr(); }, fallible)); if ((__builtin_expect (!!(tryResult975.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult975.unwrapErr(); mozilla::dom::quota ::HandleError("TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9680, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "TransformIntoNewArrayAbortOnErr( aObjectStoreNames, [lastName = Maybe<const nsString&>{}, &objectStores](const nsString& name) mutable -> mozilla::Result<SafeRefPtr<FullObjectStoreMetadata>, nsresult> { if (lastName) { if ([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"name <= lastName.ref()\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9658); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"name <= lastName.ref()\" \")\"); do { *((volatile int*)__null) = 9658; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((name <= lastName.ref()))) { return Err(NS_ERROR_FAILURE); } } lastName = SomeRef(name); const auto foundIt = std::find_if(objectStores.cbegin(), objectStores.cend(), [&name](const auto& entry) { const auto& value = entry.GetData(); do { static_assert( mozilla::detail::AssertionConditionType<decltype(entry.GetKey())>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(entry.GetKey()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"entry.GetKey()\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9668); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"entry.GetKey()\" \")\"); do { *((volatile int*)__null) = 9668; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return name == value->mCommonMetadata.name() && !value->mDeleted; }); if (foundIt == objectStores.cend()) { do { static_assert( mozilla::detail::AssertionConditionType<decltype(false)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"false\" \" (\" \"ObjectStore not found.\" \")\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 9673); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"false\" \") (\" \"ObjectStore not found.\" \")\"); do { *((volatile int*)__null) = 9673; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Err(NS_ERROR_FAILURE); } return foundIt->GetData().clonePtr(); }, fallible)" , tryTempError, nullptr); } auto objectStoreMetadatas = tryResult975 .unwrap();; |
9681 | |
9682 | return MakeSafeRefPtr<NormalTransaction>(SafeRefPtrFromThis(), aMode, |
9683 | aDurability, |
9684 | std::move(objectStoreMetadatas)) |
9685 | .forget(); |
9686 | } |
9687 | |
9688 | mozilla::ipc::IPCResult Database::RecvPBackgroundIDBTransactionConstructor( |
9689 | PBackgroundIDBTransactionParent* aActor, |
9690 | nsTArray<nsString>&& aObjectStoreNames, const Mode& aMode, |
9691 | const Durability& aDurability) { |
9692 | AssertIsOnBackgroundThread(); |
9693 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9693); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 9693; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9694 | MOZ_ASSERT(!aObjectStoreNames.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aObjectStoreNames.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aObjectStoreNames.IsEmpty() ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "!aObjectStoreNames.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9694); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aObjectStoreNames.IsEmpty()" ")"); do { *((volatile int*)__null) = 9694; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9695 | MOZ_ASSERT(aMode == IDBTransaction::Mode::ReadOnly ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction ::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMode == IDBTransaction::Mode ::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction ::Mode::Cleanup))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9698); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9698; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9696 | aMode == IDBTransaction::Mode::ReadWrite ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction ::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMode == IDBTransaction::Mode ::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction ::Mode::Cleanup))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9698); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9698; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9697 | aMode == IDBTransaction::Mode::ReadWriteFlush ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction ::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMode == IDBTransaction::Mode ::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction ::Mode::Cleanup))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9698); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9698; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9698 | aMode == IDBTransaction::Mode::Cleanup)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction ::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aMode == IDBTransaction::Mode ::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction ::Mode::Cleanup))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9698); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aMode == IDBTransaction::Mode::ReadOnly || aMode == IDBTransaction::Mode::ReadWrite || aMode == IDBTransaction::Mode::ReadWriteFlush || aMode == IDBTransaction::Mode::Cleanup" ")"); do { *((volatile int*)__null) = 9698; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9699 | MOZ_ASSERT(aDurability == IDBTransaction::Durability::Default ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDurability == IDBTransaction ::Durability::Default || aDurability == IDBTransaction::Durability ::Strict || aDurability == IDBTransaction::Durability::Relaxed ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9701); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed" ")"); do { *((volatile int*)__null) = 9701; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9700 | aDurability == IDBTransaction::Durability::Strict ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDurability == IDBTransaction ::Durability::Default || aDurability == IDBTransaction::Durability ::Strict || aDurability == IDBTransaction::Durability::Relaxed ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9701); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed" ")"); do { *((volatile int*)__null) = 9701; __attribute__((nomerge )) ::abort(); } while (false); } } while (false) |
9701 | aDurability == IDBTransaction::Durability::Relaxed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDurability == IDBTransaction ::Durability::Default || aDurability == IDBTransaction::Durability ::Strict || aDurability == IDBTransaction::Durability::Relaxed ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9701); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDurability == IDBTransaction::Durability::Default || aDurability == IDBTransaction::Durability::Strict || aDurability == IDBTransaction::Durability::Relaxed" ")"); do { *((volatile int*)__null) = 9701; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9702 | MOZ_ASSERT(!mClosed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mClosed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mClosed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mClosed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9702); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mClosed" ")" ); do { *((volatile int*)__null) = 9702; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9703 | |
9704 | if (IsInvalidated()) { |
9705 | // This is an expected race. We don't want the child to die here, just don't |
9706 | // actually do any work. |
9707 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9708 | } |
9709 | |
9710 | if (!gConnectionPool) { |
9711 | gConnectionPool = new ConnectionPool(); |
9712 | } |
9713 | |
9714 | auto* transaction = static_cast<NormalTransaction*>(aActor); |
9715 | |
9716 | RefPtr<StartTransactionOp> startOp = new StartTransactionOp( |
9717 | SafeRefPtr{transaction, AcquireStrongRefFromRawPtr{}}); |
9718 | |
9719 | uint64_t transactionId = startOp->StartOnConnectionPool( |
9720 | GetLoggingInfo()->Id(), mMetadata->mDatabaseId, |
9721 | transaction->LoggingSerialNumber(), aObjectStoreNames, |
9722 | aMode != IDBTransaction::Mode::ReadOnly); |
9723 | |
9724 | transaction->Init(transactionId); |
9725 | |
9726 | if (NS_WARN_IF(!RegisterTransaction(*transaction))NS_warn_if_impl(!RegisterTransaction(*transaction), "!RegisterTransaction(*transaction)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9726)) { |
9727 | IDB_REPORT_INTERNAL_ERR()mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9727, "UnknownErr"); |
9728 | transaction->Abort(NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR, /* aForce */ false); |
9729 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9730 | } |
9731 | |
9732 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9733 | } |
9734 | |
9735 | mozilla::ipc::IPCResult Database::RecvDeleteMe() { |
9736 | AssertIsOnBackgroundThread(); |
9737 | MOZ_ASSERT(!mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9737); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mActorDestroyed" ")"); do { *((volatile int*)__null) = 9737; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9738 | |
9739 | QM_WARNONLY_TRY(OkIf(PBackgroundIDBDatabaseParent::Send__delete__(this))){auto tryResult976 = (OkIf(PBackgroundIDBDatabaseParent::Send__delete__ (this))); static_assert(std::is_empty_v<typename decltype( tryResult976)::ok_type>); if ((__builtin_expect(!!(tryResult976 .isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(PBackgroundIDBDatabaseParent::Send__delete__(this))" , tryResult976.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9739, mozilla::dom::quota::Severity::Warning); }}; |
9740 | |
9741 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9742 | } |
9743 | |
9744 | mozilla::ipc::IPCResult Database::RecvBlocked() { |
9745 | AssertIsOnBackgroundThread(); |
9746 | |
9747 | if (NS_WARN_IF(mClosed)NS_warn_if_impl(mClosed, "mClosed", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9747)) { |
9748 | // Even though the sender checks the DB for not being closed, too, |
9749 | // there is a potential race with an ongoing origin clearing which |
9750 | // might have invalidated the DB in the meantime. Just ignore. |
9751 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9752 | } |
9753 | |
9754 | DatabaseActorInfo* info; |
9755 | MOZ_ALWAYS_TRUE(gLiveDatabaseHashtable->Get(Id(), &info))do { if ((__builtin_expect(!!(gLiveDatabaseHashtable->Get( Id(), &info)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "gLiveDatabaseHashtable->Get(Id(), &info)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9755); AnnotateMozCrashReason("MOZ_CRASH(" "gLiveDatabaseHashtable->Get(Id(), &info)" ")"); do { *((volatile int*)__null) = 9755; __attribute__((nomerge )) ::abort(); } while (false); } while (false); } } while (false ); |
9756 | MOZ_ASSERT(info->mLiveDatabases.Contains(this))do { static_assert( mozilla::detail::AssertionConditionType< decltype(info->mLiveDatabases.Contains(this))>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(info->mLiveDatabases.Contains(this)))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("info->mLiveDatabases.Contains(this)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9756); AnnotateMozCrashReason("MOZ_ASSERT" "(" "info->mLiveDatabases.Contains(this)" ")"); do { *((volatile int*)__null) = 9756; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9757 | |
9758 | if (NS_WARN_IF(!info->mWaitingFactoryOp)NS_warn_if_impl(!info->mWaitingFactoryOp, "!info->mWaitingFactoryOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9758)) { |
9759 | return IPC_FAIL(this, "Database info has no mWaitingFactoryOp!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Database info has no mWaitingFactoryOp!" )); |
9760 | } |
9761 | |
9762 | info->mWaitingFactoryOp->NoteDatabaseBlocked(this); |
9763 | |
9764 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9765 | } |
9766 | |
9767 | mozilla::ipc::IPCResult Database::RecvClose() { |
9768 | AssertIsOnBackgroundThread(); |
9769 | |
9770 | if (NS_WARN_IF(!CloseInternal())NS_warn_if_impl(!CloseInternal(), "!CloseInternal()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9770)) { |
9771 | return IPC_FAIL(this, "CloseInternal failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("CloseInternal failed!" )); |
9772 | } |
9773 | |
9774 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9775 | } |
9776 | |
9777 | void Database::StartTransactionOp::RunOnConnectionThread() { |
9778 | MOZ_ASSERT(!IsOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsOnBackgroundThread()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!IsOnBackgroundThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9778); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 9778; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9779 | MOZ_ASSERT(!HasFailed())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!HasFailed())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!HasFailed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!HasFailed()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9779); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!HasFailed()" ")"); do { *((volatile int*)__null) = 9779; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9780 | |
9781 | IDB_LOG_MARK_PARENT_TRANSACTION("Beginning database work", "DB Start",mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" ": " "Beginning database work" , "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" ": " "DB Start", mozilla::dom::indexedDB::LoggingIdString<true>(mBackgroundChildLoggingId ).get(), mTransactionLoggingSerialNumber) |
9782 | IDB_LOG_ID_STRING(mBackgroundChildLoggingId),mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" ": " "Beginning database work" , "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" ": " "DB Start", mozilla::dom::indexedDB::LoggingIdString<true>(mBackgroundChildLoggingId ).get(), mTransactionLoggingSerialNumber) |
9783 | mTransactionLoggingSerialNumber)mozilla::dom::indexedDB::LoggingHelper("IndexedDB %s: " "Parent" " " "Transaction[%" "l" "i" "]" ": " "Beginning database work" , "IndexedDB %s: " "P" " " "T[%" "l" "i" "]" ": " "DB Start", mozilla::dom::indexedDB::LoggingIdString<true>(mBackgroundChildLoggingId ).get(), mTransactionLoggingSerialNumber); |
9784 | |
9785 | TransactionDatabaseOperationBase::RunOnConnectionThread(); |
9786 | } |
9787 | |
9788 | nsresult Database::StartTransactionOp::DoDatabaseWork( |
9789 | DatabaseConnection* aConnection) { |
9790 | MOZ_ASSERT(aConnection)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aConnection)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aConnection))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aConnection", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9790); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aConnection" ")"); do { *((volatile int*)__null) = 9790; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9791 | aConnection->AssertIsOnConnectionThread(); |
9792 | |
9793 | Transaction().SetActiveOnConnectionThread(); |
9794 | |
9795 | if (Transaction().GetMode() == IDBTransaction::Mode::Cleanup) { |
9796 | DebugOnly<nsresult> rv = aConnection->DisableQuotaChecks(); |
9797 | NS_WARNING_ASSERTION(NS_SUCCEEDED(rv),do { if (!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1 ))))) { NS_DebugBreak(NS_DEBUG_WARNING, "DisableQuotaChecks failed, trying to continue " "cleanup transaction with quota checks enabled", "NS_SUCCEEDED(rv)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9799); } } while (false) |
9798 | "DisableQuotaChecks failed, trying to continue "do { if (!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1 ))))) { NS_DebugBreak(NS_DEBUG_WARNING, "DisableQuotaChecks failed, trying to continue " "cleanup transaction with quota checks enabled", "NS_SUCCEEDED(rv)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9799); } } while (false) |
9799 | "cleanup transaction with quota checks enabled")do { if (!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1 ))))) { NS_DebugBreak(NS_DEBUG_WARNING, "DisableQuotaChecks failed, trying to continue " "cleanup transaction with quota checks enabled", "NS_SUCCEEDED(rv)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9799); } } while (false); |
9800 | } |
9801 | |
9802 | if (Transaction().GetMode() != IDBTransaction::Mode::ReadOnly) { |
9803 | QM_TRY(MOZ_TO_RESULT({auto tryResult977 = (ToResult(aConnection->BeginWriteTransaction (Transaction().GetDurability()))); static_assert(std::is_empty_v <typename decltype(tryResult977)::ok_type>); if ((__builtin_expect (!!(tryResult977.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aConnection->BeginWriteTransaction(Transaction().GetDurability()))" , tryResult977.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9804, mozilla::dom::quota::Severity::Error); return tryResult977 .propagateErr(); }} |
9804 | aConnection->BeginWriteTransaction(Transaction().GetDurability()))){auto tryResult977 = (ToResult(aConnection->BeginWriteTransaction (Transaction().GetDurability()))); static_assert(std::is_empty_v <typename decltype(tryResult977)::ok_type>); if ((__builtin_expect (!!(tryResult977.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aConnection->BeginWriteTransaction(Transaction().GetDurability()))" , tryResult977.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9804, mozilla::dom::quota::Severity::Error); return tryResult977 .propagateErr(); }}; |
9805 | } |
9806 | |
9807 | return NS_OK; |
9808 | } |
9809 | |
9810 | nsresult Database::StartTransactionOp::SendSuccessResult() { |
9811 | // We don't need to do anything here. |
9812 | return NS_OK; |
9813 | } |
9814 | |
9815 | bool Database::StartTransactionOp::SendFailureResult( |
9816 | nsresult /* aResultCode */) { |
9817 | IDB_REPORT_INTERNAL_ERR()mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9817, "UnknownErr"); |
9818 | |
9819 | // Abort the transaction. |
9820 | return false; |
9821 | } |
9822 | |
9823 | void Database::StartTransactionOp::Cleanup() { |
9824 | #ifdef DEBUG1 |
9825 | // StartTransactionOp is not a normal database operation that is tied to an |
9826 | // actor. Do this to make our assertions happy. |
9827 | NoteActorDestroyed(); |
9828 | #endif |
9829 | |
9830 | TransactionDatabaseOperationBase::Cleanup(); |
9831 | } |
9832 | |
9833 | /******************************************************************************* |
9834 | * TransactionBase |
9835 | ******************************************************************************/ |
9836 | |
9837 | TransactionBase::TransactionBase(SafeRefPtr<Database> aDatabase, Mode aMode, |
9838 | Durability aDurability) |
9839 | : mDatabase(std::move(aDatabase)), |
9840 | mDatabaseId(mDatabase->Id()), |
9841 | mLoggingSerialNumber( |
9842 | mDatabase->GetLoggingInfo()->NextTransactionSN(aMode)), |
9843 | mActiveRequestCount(0), |
9844 | mInvalidatedOnAnyThread(false), |
9845 | mMode(aMode), |
9846 | mDurability(aDurability), |
9847 | mResultCode(NS_OK) { |
9848 | AssertIsOnBackgroundThread(); |
9849 | MOZ_ASSERT(mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDatabase", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9849); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDatabase" ")" ); do { *((volatile int*)__null) = 9849; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9850 | MOZ_ASSERT(mLoggingSerialNumber)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mLoggingSerialNumber)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mLoggingSerialNumber))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("mLoggingSerialNumber" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9850); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mLoggingSerialNumber" ")"); do { *((volatile int*)__null) = 9850; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9851 | } |
9852 | |
9853 | TransactionBase::~TransactionBase() { |
9854 | MOZ_ASSERT(!mActiveRequestCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mActiveRequestCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mActiveRequestCount))), 0)) ) { do { } while (false); MOZ_ReportAssertionFailure("!mActiveRequestCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9854); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mActiveRequestCount" ")"); do { *((volatile int*)__null) = 9854; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9855 | MOZ_ASSERT(mActorDestroyed)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mActorDestroyed)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mActorDestroyed))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mActorDestroyed" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9855); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mActorDestroyed" ")"); do { *((volatile int*)__null) = 9855; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9856 | MOZ_ASSERT_IF(mInitialized, mCommittedOrAborted)do { if (mInitialized) { do { static_assert( mozilla::detail:: AssertionConditionType<decltype(mCommittedOrAborted)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mCommittedOrAborted))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mCommittedOrAborted", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9856); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCommittedOrAborted" ")"); do { *((volatile int*)__null) = 9856; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } } while ( false); |
9857 | } |
9858 | |
9859 | void TransactionBase::Abort(nsresult aResultCode, bool aForce) { |
9860 | AssertIsOnBackgroundThread(); |
9861 | MOZ_ASSERT(NS_FAILED(aResultCode))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(NS_FAILED_impl(aResultCode )), 0))))>::isValid, "invalid assertion condition"); if (( __builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(NS_FAILED_impl (aResultCode)), 0)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("((bool)(__builtin_expect(!!(NS_FAILED_impl(aResultCode)), 0)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9861); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(NS_FAILED_impl(aResultCode)), 0)))" ")"); do { *((volatile int*)__null) = 9861; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9862 | |
9863 | if (NS_SUCCEEDED(mResultCode)((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1) ))) { |
9864 | mResultCode = aResultCode; |
9865 | } |
9866 | |
9867 | if (aForce) { |
9868 | mForceAborted.EnsureFlipped(); |
9869 | } |
9870 | |
9871 | MaybeCommitOrAbort(); |
9872 | } |
9873 | |
9874 | mozilla::ipc::IPCResult TransactionBase::RecvCommit( |
9875 | IProtocol* aActor, const Maybe<int64_t> aLastRequest) { |
9876 | AssertIsOnBackgroundThread(); |
9877 | |
9878 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9878)) { |
9879 | return IPC_FAIL(mozilla::ipc::IPCResult::Fail(WrapNotNull(aActor), __func__, ( "Attempt to commit an already comitted/aborted transaction!") ) |
9880 | aActor, "Attempt to commit an already comitted/aborted transaction!")mozilla::ipc::IPCResult::Fail(WrapNotNull(aActor), __func__, ( "Attempt to commit an already comitted/aborted transaction!") ); |
9881 | } |
9882 | |
9883 | mCommitOrAbortReceived.Flip(); |
9884 | mLastRequestBeforeCommit.init(aLastRequest); |
9885 | MaybeCommitOrAbort(); |
9886 | |
9887 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9888 | } |
9889 | |
9890 | mozilla::ipc::IPCResult TransactionBase::RecvAbort(IProtocol* aActor, |
9891 | nsresult aResultCode) { |
9892 | AssertIsOnBackgroundThread(); |
9893 | |
9894 | if (NS_WARN_IF(NS_SUCCEEDED(aResultCode))NS_warn_if_impl(((bool)(__builtin_expect(!!(!NS_FAILED_impl(aResultCode )), 1))), "NS_SUCCEEDED(aResultCode)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9894)) { |
9895 | return IPC_FAIL(aActor, "aResultCode must not be a success code!")mozilla::ipc::IPCResult::Fail(WrapNotNull(aActor), __func__, ( "aResultCode must not be a success code!")); |
9896 | } |
9897 | |
9898 | if (NS_WARN_IF(NS_ERROR_GET_MODULE(aResultCode) !=NS_warn_if_impl(NS_ERROR_GET_MODULE(aResultCode) != 33, "NS_ERROR_GET_MODULE(aResultCode) != NS_ERROR_MODULE_DOM_INDEXEDDB" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9899) |
9899 | NS_ERROR_MODULE_DOM_INDEXEDDB)NS_warn_if_impl(NS_ERROR_GET_MODULE(aResultCode) != 33, "NS_ERROR_GET_MODULE(aResultCode) != NS_ERROR_MODULE_DOM_INDEXEDDB" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9899)) { |
9900 | return IPC_FAIL(aActor, "aResultCode does not refer to IndexedDB!")mozilla::ipc::IPCResult::Fail(WrapNotNull(aActor), __func__, ( "aResultCode does not refer to IndexedDB!")); |
9901 | } |
9902 | |
9903 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9903)) { |
9904 | return IPC_FAIL(mozilla::ipc::IPCResult::Fail(WrapNotNull(aActor), __func__, ( "Attempt to abort an already comitted/aborted transaction!")) |
9905 | aActor, "Attempt to abort an already comitted/aborted transaction!")mozilla::ipc::IPCResult::Fail(WrapNotNull(aActor), __func__, ( "Attempt to abort an already comitted/aborted transaction!")); |
9906 | } |
9907 | |
9908 | mCommitOrAbortReceived.Flip(); |
9909 | Abort(aResultCode, /* aForce */ false); |
9910 | |
9911 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
9912 | } |
9913 | |
9914 | void TransactionBase::CommitOrAbort() { |
9915 | AssertIsOnBackgroundThread(); |
9916 | |
9917 | mCommittedOrAborted.Flip(); |
9918 | |
9919 | if (!mInitialized) { |
9920 | return; |
9921 | } |
9922 | |
9923 | // In case of a failed request and explicitly committed transaction, abort |
9924 | // (cf. https://w3c.github.io/IndexedDB/#async-execute-request step 5.3 |
9925 | // vs. 5.4). It's worth emphasizing this can only happen here when we are |
9926 | // committing explicitly, otherwise the decision is made by the child. |
9927 | if (NS_SUCCEEDED(mResultCode)((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1) )) && mLastFailedRequest && |
9928 | *mLastRequestBeforeCommit && |
9929 | *mLastFailedRequest == **mLastRequestBeforeCommit) { |
9930 | mResultCode = NS_ERROR_DOM_INDEXEDDB_ABORT_ERR; |
9931 | } |
9932 | |
9933 | RefPtr<CommitOp> commitOp = |
9934 | new CommitOp(SafeRefPtrFromThis(), ClampResultCode(mResultCode)); |
9935 | |
9936 | gConnectionPool->Finish(TransactionId(), commitOp); |
9937 | } |
9938 | |
9939 | SafeRefPtr<FullObjectStoreMetadata> |
9940 | TransactionBase::GetMetadataForObjectStoreId( |
9941 | IndexOrObjectStoreId aObjectStoreId) const { |
9942 | AssertIsOnBackgroundThread(); |
9943 | MOZ_ASSERT(aObjectStoreId)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aObjectStoreId)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aObjectStoreId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aObjectStoreId" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9943); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aObjectStoreId" ")"); do { *((volatile int*)__null) = 9943; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9944 | |
9945 | if (!aObjectStoreId) { |
9946 | return nullptr; |
9947 | } |
9948 | |
9949 | auto metadata = mDatabase->Metadata().mObjectStores.Lookup(aObjectStoreId); |
9950 | if (!metadata || (*metadata)->mDeleted) { |
9951 | return nullptr; |
9952 | } |
9953 | |
9954 | MOZ_ASSERT((*metadata)->mCommonMetadata.id() == aObjectStoreId)do { static_assert( mozilla::detail::AssertionConditionType< decltype((*metadata)->mCommonMetadata.id() == aObjectStoreId )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!((*metadata)->mCommonMetadata.id() == aObjectStoreId ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "(*metadata)->mCommonMetadata.id() == aObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9954); AnnotateMozCrashReason("MOZ_ASSERT" "(" "(*metadata)->mCommonMetadata.id() == aObjectStoreId" ")"); do { *((volatile int*)__null) = 9954; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9955 | |
9956 | return metadata->clonePtr(); |
9957 | } |
9958 | |
9959 | SafeRefPtr<FullIndexMetadata> TransactionBase::GetMetadataForIndexId( |
9960 | FullObjectStoreMetadata& aObjectStoreMetadata, |
9961 | IndexOrObjectStoreId aIndexId) const { |
9962 | AssertIsOnBackgroundThread(); |
9963 | MOZ_ASSERT(aIndexId)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aIndexId)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aIndexId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aIndexId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9963); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aIndexId" ")" ); do { *((volatile int*)__null) = 9963; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9964 | |
9965 | if (!aIndexId) { |
9966 | return nullptr; |
9967 | } |
9968 | |
9969 | auto metadata = aObjectStoreMetadata.mIndexes.Lookup(aIndexId); |
9970 | if (!metadata || (*metadata)->mDeleted) { |
9971 | return nullptr; |
9972 | } |
9973 | |
9974 | MOZ_ASSERT((*metadata)->mCommonMetadata.id() == aIndexId)do { static_assert( mozilla::detail::AssertionConditionType< decltype((*metadata)->mCommonMetadata.id() == aIndexId)> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!((*metadata)->mCommonMetadata.id() == aIndexId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("(*metadata)->mCommonMetadata.id() == aIndexId" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9974); AnnotateMozCrashReason("MOZ_ASSERT" "(" "(*metadata)->mCommonMetadata.id() == aIndexId" ")"); do { *((volatile int*)__null) = 9974; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9975 | |
9976 | return metadata->clonePtr(); |
9977 | } |
9978 | |
9979 | void TransactionBase::NoteModifiedAutoIncrementObjectStore( |
9980 | const SafeRefPtr<FullObjectStoreMetadata>& aMetadata) { |
9981 | AssertIsOnConnectionThread(); |
9982 | |
9983 | if (!mModifiedAutoIncrementObjectStoreMetadataArray.Contains(aMetadata)) { |
9984 | mModifiedAutoIncrementObjectStoreMetadataArray.AppendElement( |
9985 | aMetadata.clonePtr()); |
9986 | } |
9987 | } |
9988 | |
9989 | void TransactionBase::ForgetModifiedAutoIncrementObjectStore( |
9990 | FullObjectStoreMetadata& aMetadata) { |
9991 | AssertIsOnConnectionThread(); |
9992 | |
9993 | mModifiedAutoIncrementObjectStoreMetadataArray.RemoveElement(&aMetadata); |
9994 | } |
9995 | |
9996 | bool TransactionBase::VerifyRequestParams(const RequestParams& aParams) const { |
9997 | AssertIsOnBackgroundThread(); |
9998 | MOZ_ASSERT(aParams.type() != RequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != RequestParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != RequestParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != RequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 9998); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != RequestParams::T__None" ")"); do { *((volatile int*)__null) = 9998; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
9999 | |
10000 | switch (aParams.type()) { |
10001 | case RequestParams::TObjectStoreAddParams: { |
10002 | const ObjectStoreAddPutParams& params = |
10003 | aParams.get_ObjectStoreAddParams().commonParams(); |
10004 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10004); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params)" ")"); do { *((volatile int*)__null ) = 10004; __attribute__((nomerge)) ::abort(); } while (false ); } } while (false); } return aCond; }((!VerifyRequestParams (params)))) { |
10005 | return false; |
10006 | } |
10007 | break; |
10008 | } |
10009 | |
10010 | case RequestParams::TObjectStorePutParams: { |
10011 | const ObjectStoreAddPutParams& params = |
10012 | aParams.get_ObjectStorePutParams().commonParams(); |
10013 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10013); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params)" ")"); do { *((volatile int*)__null ) = 10013; __attribute__((nomerge)) ::abort(); } while (false ); } } while (false); } return aCond; }((!VerifyRequestParams (params)))) { |
10014 | return false; |
10015 | } |
10016 | break; |
10017 | } |
10018 | |
10019 | case RequestParams::TObjectStoreGetParams: { |
10020 | const ObjectStoreGetParams& params = aParams.get_ObjectStoreGetParams(); |
10021 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10022 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10023 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10023); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10023; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10024 | return false; |
10025 | } |
10026 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.keyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.keyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10026); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.keyRange())" ")"); do { *((volatile int*)__null) = 10026; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!VerifyRequestParams (params.keyRange())))) { |
10027 | return false; |
10028 | } |
10029 | break; |
10030 | } |
10031 | |
10032 | case RequestParams::TObjectStoreGetKeyParams: { |
10033 | const ObjectStoreGetKeyParams& params = |
10034 | aParams.get_ObjectStoreGetKeyParams(); |
10035 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10036 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10037 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10037); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10037; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10038 | return false; |
10039 | } |
10040 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.keyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.keyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10040); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.keyRange())" ")"); do { *((volatile int*)__null) = 10040; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!VerifyRequestParams (params.keyRange())))) { |
10041 | return false; |
10042 | } |
10043 | break; |
10044 | } |
10045 | |
10046 | case RequestParams::TObjectStoreGetAllParams: { |
10047 | const ObjectStoreGetAllParams& params = |
10048 | aParams.get_ObjectStoreGetAllParams(); |
10049 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10050 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10051 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10051); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10051; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10052 | return false; |
10053 | } |
10054 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10054); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.optionalKeyRange())" ")"); do { *((volatile int*)__null) = 10054; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!VerifyRequestParams(params.optionalKeyRange())))) { |
10055 | return false; |
10056 | } |
10057 | break; |
10058 | } |
10059 | |
10060 | case RequestParams::TObjectStoreGetAllKeysParams: { |
10061 | const ObjectStoreGetAllKeysParams& params = |
10062 | aParams.get_ObjectStoreGetAllKeysParams(); |
10063 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10064 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10065 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10065); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10065; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10066 | return false; |
10067 | } |
10068 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10068); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.optionalKeyRange())" ")"); do { *((volatile int*)__null) = 10068; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!VerifyRequestParams(params.optionalKeyRange())))) { |
10069 | return false; |
10070 | } |
10071 | break; |
10072 | } |
10073 | |
10074 | case RequestParams::TObjectStoreDeleteParams: { |
10075 | if (NS_AUUF_OR_WARN_IF(mMode != IDBTransaction::Mode::ReadWrite &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10078); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10078; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange)) |
10076 | mMode != IDBTransaction::Mode::ReadWriteFlush &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10078); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10078; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange)) |
10077 | mMode != IDBTransaction::Mode::Cleanup &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10078); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10078; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange)) |
10078 | mMode != IDBTransaction::Mode::VersionChange)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10078); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10078; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange))) { |
10079 | return false; |
10080 | } |
10081 | |
10082 | const ObjectStoreDeleteParams& params = |
10083 | aParams.get_ObjectStoreDeleteParams(); |
10084 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10085 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10086 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10086); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10086; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10087 | return false; |
10088 | } |
10089 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.keyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.keyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10089); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.keyRange())" ")"); do { *((volatile int*)__null) = 10089; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!VerifyRequestParams (params.keyRange())))) { |
10090 | return false; |
10091 | } |
10092 | break; |
10093 | } |
10094 | |
10095 | case RequestParams::TObjectStoreClearParams: { |
10096 | if (NS_AUUF_OR_WARN_IF(mMode != IDBTransaction::Mode::ReadWrite &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10099); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10099; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange)) |
10097 | mMode != IDBTransaction::Mode::ReadWriteFlush &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10099); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10099; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange)) |
10098 | mMode != IDBTransaction::Mode::Cleanup &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10099); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10099; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange)) |
10099 | mMode != IDBTransaction::Mode::VersionChange)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10099); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10099; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::Cleanup && mMode != IDBTransaction ::Mode::VersionChange))) { |
10100 | return false; |
10101 | } |
10102 | |
10103 | const ObjectStoreClearParams& params = |
10104 | aParams.get_ObjectStoreClearParams(); |
10105 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10106 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10107 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10107); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10107; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10108 | return false; |
10109 | } |
10110 | break; |
10111 | } |
10112 | |
10113 | case RequestParams::TObjectStoreCountParams: { |
10114 | const ObjectStoreCountParams& params = |
10115 | aParams.get_ObjectStoreCountParams(); |
10116 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10117 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10118 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10118); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10118; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10119 | return false; |
10120 | } |
10121 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10121); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.optionalKeyRange())" ")"); do { *((volatile int*)__null) = 10121; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!VerifyRequestParams(params.optionalKeyRange())))) { |
10122 | return false; |
10123 | } |
10124 | break; |
10125 | } |
10126 | |
10127 | case RequestParams::TIndexGetParams: { |
10128 | const IndexGetParams& params = aParams.get_IndexGetParams(); |
10129 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10130 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10131 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10131); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10131; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10132 | return false; |
10133 | } |
10134 | const SafeRefPtr<FullIndexMetadata> indexMetadata = |
10135 | GetMetadataForIndexId(*objectStoreMetadata, params.indexId()); |
10136 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10136); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10136 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10137 | return false; |
10138 | } |
10139 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.keyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.keyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10139); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.keyRange())" ")"); do { *((volatile int*)__null) = 10139; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!VerifyRequestParams (params.keyRange())))) { |
10140 | return false; |
10141 | } |
10142 | break; |
10143 | } |
10144 | |
10145 | case RequestParams::TIndexGetKeyParams: { |
10146 | const IndexGetKeyParams& params = aParams.get_IndexGetKeyParams(); |
10147 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10148 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10149 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10149); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10149; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10150 | return false; |
10151 | } |
10152 | const SafeRefPtr<FullIndexMetadata> indexMetadata = |
10153 | GetMetadataForIndexId(*objectStoreMetadata, params.indexId()); |
10154 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10154); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10154 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10155 | return false; |
10156 | } |
10157 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.keyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.keyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10157); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.keyRange())" ")"); do { *((volatile int*)__null) = 10157; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!VerifyRequestParams (params.keyRange())))) { |
10158 | return false; |
10159 | } |
10160 | break; |
10161 | } |
10162 | |
10163 | case RequestParams::TIndexGetAllParams: { |
10164 | const IndexGetAllParams& params = aParams.get_IndexGetAllParams(); |
10165 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10166 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10167 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10167); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10167; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10168 | return false; |
10169 | } |
10170 | const SafeRefPtr<FullIndexMetadata> indexMetadata = |
10171 | GetMetadataForIndexId(*objectStoreMetadata, params.indexId()); |
10172 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10172); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10172 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10173 | return false; |
10174 | } |
10175 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10175); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.optionalKeyRange())" ")"); do { *((volatile int*)__null) = 10175; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!VerifyRequestParams(params.optionalKeyRange())))) { |
10176 | return false; |
10177 | } |
10178 | break; |
10179 | } |
10180 | |
10181 | case RequestParams::TIndexGetAllKeysParams: { |
10182 | const IndexGetAllKeysParams& params = aParams.get_IndexGetAllKeysParams(); |
10183 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10184 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10185 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10185); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10185; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10186 | return false; |
10187 | } |
10188 | const SafeRefPtr<FullIndexMetadata> indexMetadata = |
10189 | GetMetadataForIndexId(*objectStoreMetadata, params.indexId()); |
10190 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10190); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10190 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10191 | return false; |
10192 | } |
10193 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10193); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.optionalKeyRange())" ")"); do { *((volatile int*)__null) = 10193; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!VerifyRequestParams(params.optionalKeyRange())))) { |
10194 | return false; |
10195 | } |
10196 | break; |
10197 | } |
10198 | |
10199 | case RequestParams::TIndexCountParams: { |
10200 | const IndexCountParams& params = aParams.get_IndexCountParams(); |
10201 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
10202 | GetMetadataForObjectStoreId(params.objectStoreId()); |
10203 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10203); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10203; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10204 | return false; |
10205 | } |
10206 | const SafeRefPtr<FullIndexMetadata> indexMetadata = |
10207 | GetMetadataForIndexId(*objectStoreMetadata, params.indexId()); |
10208 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10208); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10208 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10209 | return false; |
10210 | } |
10211 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(params.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(params.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10211); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(params.optionalKeyRange())" ")"); do { *((volatile int*)__null) = 10211; __attribute__((nomerge)) :: abort(); } while (false); } } while (false); } return aCond; } ((!VerifyRequestParams(params.optionalKeyRange())))) { |
10212 | return false; |
10213 | } |
10214 | break; |
10215 | } |
10216 | |
10217 | default: |
10218 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10218); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 10218; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
10219 | } |
10220 | |
10221 | return true; |
10222 | } |
10223 | |
10224 | bool TransactionBase::VerifyRequestParams( |
10225 | const SerializedKeyRange& aParams) const { |
10226 | AssertIsOnBackgroundThread(); |
10227 | |
10228 | // XXX Check more here? |
10229 | |
10230 | if (aParams.isOnly()) { |
10231 | if (NS_AUUF_OR_WARN_IF(aParams.lower().IsUnset())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aParams.lower().IsUnset()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10231); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aParams.lower().IsUnset()" ")"); do { *((volatile int*)__null ) = 10231; __attribute__((nomerge)) ::abort(); } while (false ); } } while (false); } return aCond; }((aParams.lower().IsUnset ()))) { |
10232 | return false; |
10233 | } |
10234 | if (NS_AUUF_OR_WARN_IF(!aParams.upper().IsUnset())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aParams.upper().IsUnset()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10234); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aParams.upper().IsUnset()" ")"); do { *((volatile int*)__null ) = 10234; __attribute__((nomerge)) ::abort(); } while (false ); } } while (false); } return aCond; }((!aParams.upper().IsUnset ()))) { |
10235 | return false; |
10236 | } |
10237 | if (NS_AUUF_OR_WARN_IF(aParams.lowerOpen())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aParams.lowerOpen()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10237); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aParams.lowerOpen()" ")"); do { *((volatile int*)__null) = 10237 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((aParams.lowerOpen()))) { |
10238 | return false; |
10239 | } |
10240 | if (NS_AUUF_OR_WARN_IF(aParams.upperOpen())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aParams.upperOpen()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10240); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aParams.upperOpen()" ")"); do { *((volatile int*)__null) = 10240 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((aParams.upperOpen()))) { |
10241 | return false; |
10242 | } |
10243 | } else if (NS_AUUF_OR_WARN_IF(aParams.lower().IsUnset() &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aParams.lower().IsUnset() && aParams.upper().IsUnset()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10244); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aParams.lower().IsUnset() && aParams.upper().IsUnset()" ")"); do { *((volatile int*)__null) = 10244; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((aParams.lower().IsUnset() && aParams.upper ().IsUnset())) |
10244 | aParams.upper().IsUnset())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aParams.lower().IsUnset() && aParams.upper().IsUnset()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10244); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aParams.lower().IsUnset() && aParams.upper().IsUnset()" ")"); do { *((volatile int*)__null) = 10244; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((aParams.lower().IsUnset() && aParams.upper ().IsUnset()))) { |
10245 | return false; |
10246 | } |
10247 | |
10248 | return true; |
10249 | } |
10250 | |
10251 | bool TransactionBase::VerifyRequestParams( |
10252 | const ObjectStoreAddPutParams& aParams) const { |
10253 | AssertIsOnBackgroundThread(); |
10254 | |
10255 | if (NS_AUUF_OR_WARN_IF(mMode != IDBTransaction::Mode::ReadWrite &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10257); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10257; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange)) |
10256 | mMode != IDBTransaction::Mode::ReadWriteFlush &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10257); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10257; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange)) |
10257 | mMode != IDBTransaction::Mode::VersionChange)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10257); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange" ")"); do { *((volatile int*)__null) = 10257; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mMode != IDBTransaction::Mode::ReadWrite && mMode != IDBTransaction::Mode::ReadWriteFlush && mMode != IDBTransaction::Mode::VersionChange))) { |
10258 | return false; |
10259 | } |
10260 | |
10261 | SafeRefPtr<FullObjectStoreMetadata> objMetadata = |
10262 | GetMetadataForObjectStoreId(aParams.objectStoreId()); |
10263 | if (NS_AUUF_OR_WARN_IF(!objMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10263); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objMetadata" ")"); do { *((volatile int*)__null) = 10263; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objMetadata))) { |
10264 | return false; |
10265 | } |
10266 | |
10267 | if (NS_AUUF_OR_WARN_IF(!aParams.cloneInfo().data().data.Size())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aParams.cloneInfo().data().data.Size()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10267); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aParams.cloneInfo().data().data.Size()" ")"); do { *((volatile int*)__null) = 10267; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!aParams.cloneInfo ().data().data.Size()))) { |
10268 | return false; |
10269 | } |
10270 | |
10271 | if (objMetadata->mCommonMetadata.autoIncrement() && |
10272 | objMetadata->mCommonMetadata.keyPath().IsValid() && |
10273 | aParams.key().IsUnset()) { |
10274 | const SerializedStructuredCloneWriteInfo& cloneInfo = aParams.cloneInfo(); |
10275 | |
10276 | if (NS_AUUF_OR_WARN_IF(!cloneInfo.offsetToKeyProp())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!cloneInfo.offsetToKeyProp()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10276); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!cloneInfo.offsetToKeyProp()" ")"); do { *((volatile int*)__null ) = 10276; __attribute__((nomerge)) ::abort(); } while (false ); } } while (false); } return aCond; }((!cloneInfo.offsetToKeyProp ()))) { |
10277 | return false; |
10278 | } |
10279 | |
10280 | if (NS_AUUF_OR_WARN_IF(cloneInfo.data().data.Size() < sizeof(uint64_t))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "cloneInfo.data().data.Size() < sizeof(uint64_t)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10280); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "cloneInfo.data().data.Size() < sizeof(uint64_t)" ")"); do { *((volatile int*)__null) = 10280; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond ; }((cloneInfo.data().data.Size() < sizeof(uint64_t)))) { |
10281 | return false; |
10282 | } |
10283 | |
10284 | if (NS_AUUF_OR_WARN_IF(cloneInfo.offsetToKeyProp() >[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "cloneInfo.offsetToKeyProp() > (cloneInfo.data().data.Size() - sizeof(uint64_t))" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10285); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "cloneInfo.offsetToKeyProp() > (cloneInfo.data().data.Size() - sizeof(uint64_t))" ")"); do { *((volatile int*)__null) = 10285; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((cloneInfo.offsetToKeyProp() > (cloneInfo.data() .data.Size() - sizeof(uint64_t)))) |
10285 | (cloneInfo.data().data.Size() - sizeof(uint64_t)))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "cloneInfo.offsetToKeyProp() > (cloneInfo.data().data.Size() - sizeof(uint64_t))" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10285); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "cloneInfo.offsetToKeyProp() > (cloneInfo.data().data.Size() - sizeof(uint64_t))" ")"); do { *((volatile int*)__null) = 10285; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((cloneInfo.offsetToKeyProp() > (cloneInfo.data() .data.Size() - sizeof(uint64_t))))) { |
10286 | return false; |
10287 | } |
10288 | } else if (NS_AUUF_OR_WARN_IF(aParams.cloneInfo().offsetToKeyProp())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "aParams.cloneInfo().offsetToKeyProp()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10288); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "aParams.cloneInfo().offsetToKeyProp()" ")"); do { *((volatile int*)__null) = 10288; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((aParams.cloneInfo ().offsetToKeyProp()))) { |
10289 | return false; |
10290 | } |
10291 | |
10292 | for (const auto& updateInfo : aParams.indexUpdateInfos()) { |
10293 | SafeRefPtr<FullIndexMetadata> indexMetadata = |
10294 | GetMetadataForIndexId(*objMetadata, updateInfo.indexId()); |
10295 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10295); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10295 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10296 | return false; |
10297 | } |
10298 | |
10299 | if (NS_AUUF_OR_WARN_IF(updateInfo.value().IsUnset())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "updateInfo.value().IsUnset()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10299); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "updateInfo.value().IsUnset()" ")"); do { *((volatile int*)__null ) = 10299; __attribute__((nomerge)) ::abort(); } while (false ); } } while (false); } return aCond; }((updateInfo.value().IsUnset ()))) { |
10300 | return false; |
10301 | } |
10302 | |
10303 | MOZ_ASSERT(!updateInfo.value().GetBuffer().IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!updateInfo.value().GetBuffer().IsEmpty())>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!updateInfo.value().GetBuffer().IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!updateInfo.value().GetBuffer().IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10303); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!updateInfo.value().GetBuffer().IsEmpty()" ")"); do { *((volatile int*)__null) = 10303; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10304 | } |
10305 | |
10306 | for (const FileAddInfo& fileAddInfo : aParams.fileAddInfos()) { |
10307 | const PBackgroundIDBDatabaseFileParent* file = |
10308 | fileAddInfo.file().AsParent(); |
10309 | |
10310 | switch (fileAddInfo.type()) { |
10311 | case StructuredCloneFileBase::eBlob: |
10312 | if (NS_AUUF_OR_WARN_IF(!file)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!file" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10312); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!file" ")"); do { *((volatile int*)__null) = 10312; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!file))) { |
10313 | return false; |
10314 | } |
10315 | break; |
10316 | |
10317 | case StructuredCloneFileBase::eMutableFile: { |
10318 | return false; |
10319 | } |
10320 | |
10321 | case StructuredCloneFileBase::eStructuredClone: |
10322 | case StructuredCloneFileBase::eWasmBytecode: |
10323 | case StructuredCloneFileBase::eWasmCompiled: |
10324 | case StructuredCloneFileBase::eEndGuard: |
10325 | MOZ_ASSERT_UNLESS_FUZZING(false, "Unsupported.")do { static_assert( mozilla::detail::AssertionConditionType< decltype(false)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(false))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("false" " (" "Unsupported." ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10325); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "Unsupported." ")"); do { *((volatile int*)__null) = 10325; __attribute__ ((nomerge)) ::abort(); } while (false); } } while (false); |
10326 | return false; |
10327 | |
10328 | default: |
10329 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10329); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 10329; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
10330 | } |
10331 | } |
10332 | |
10333 | return true; |
10334 | } |
10335 | |
10336 | bool TransactionBase::VerifyRequestParams( |
10337 | const Maybe<SerializedKeyRange>& aParams) const { |
10338 | AssertIsOnBackgroundThread(); |
10339 | |
10340 | if (aParams.isSome()) { |
10341 | if (NS_AUUF_OR_WARN_IF(!VerifyRequestParams(aParams.ref()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams(aParams.ref())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10341); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams(aParams.ref())" ")"); do { *((volatile int*)__null) = 10341; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!VerifyRequestParams (aParams.ref())))) { |
10342 | return false; |
10343 | } |
10344 | } |
10345 | |
10346 | return true; |
10347 | } |
10348 | |
10349 | void TransactionBase::NoteActiveRequest() { |
10350 | AssertIsOnBackgroundThread(); |
10351 | MOZ_ASSERT(mActiveRequestCount < UINT64_MAX)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mActiveRequestCount < (18446744073709551615UL))> ::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mActiveRequestCount < (18446744073709551615UL)))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("mActiveRequestCount < (18446744073709551615UL)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10351); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mActiveRequestCount < (18446744073709551615UL)" ")"); do { *((volatile int*)__null) = 10351; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10352 | |
10353 | mActiveRequestCount++; |
10354 | } |
10355 | |
10356 | void TransactionBase::NoteFinishedRequest(const int64_t aRequestId, |
10357 | const nsresult aResultCode) { |
10358 | AssertIsOnBackgroundThread(); |
10359 | MOZ_ASSERT(mActiveRequestCount)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mActiveRequestCount)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mActiveRequestCount))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mActiveRequestCount" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10359); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mActiveRequestCount" ")"); do { *((volatile int*)__null) = 10359; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10360 | |
10361 | mActiveRequestCount--; |
10362 | |
10363 | if (NS_FAILED(aResultCode)((bool)(__builtin_expect(!!(NS_FAILED_impl(aResultCode)), 0)) )) { |
10364 | mLastFailedRequest = Some(aRequestId); |
10365 | } |
10366 | |
10367 | MaybeCommitOrAbort(); |
10368 | } |
10369 | |
10370 | void TransactionBase::Invalidate() { |
10371 | AssertIsOnBackgroundThread(); |
10372 | MOZ_ASSERT(mInvalidated == mInvalidatedOnAnyThread)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mInvalidated == mInvalidatedOnAnyThread)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(mInvalidated == mInvalidatedOnAnyThread))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mInvalidated == mInvalidatedOnAnyThread" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10372); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mInvalidated == mInvalidatedOnAnyThread" ")"); do { *((volatile int*)__null) = 10372; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10373 | |
10374 | if (!mInvalidated) { |
10375 | mInvalidated.Flip(); |
10376 | mInvalidatedOnAnyThread = true; |
10377 | |
10378 | Abort(NS_ERROR_DOM_INDEXEDDB_ABORT_ERR, /* aForce */ false); |
10379 | } |
10380 | } |
10381 | |
10382 | PBackgroundIDBRequestParent* TransactionBase::AllocRequest( |
10383 | const int64_t aRequestId, RequestParams&& aParams, bool aTrustParams) { |
10384 | AssertIsOnBackgroundThread(); |
10385 | MOZ_ASSERT(aParams.type() != RequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != RequestParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != RequestParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != RequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10385); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != RequestParams::T__None" ")"); do { *((volatile int*)__null) = 10385; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10386 | |
10387 | #ifdef DEBUG1 |
10388 | // Always verify parameters in DEBUG builds! |
10389 | aTrustParams = false; |
10390 | #endif |
10391 | |
10392 | if (NS_AUUF_OR_WARN_IF(!aTrustParams && !VerifyRequestParams(aParams))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aTrustParams && !VerifyRequestParams(aParams)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10392); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aTrustParams && !VerifyRequestParams(aParams)" ")" ); do { *((volatile int*)__null) = 10392; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((!aTrustParams && !VerifyRequestParams(aParams)))) { |
10393 | return nullptr; |
10394 | } |
10395 | |
10396 | if (NS_AUUF_OR_WARN_IF(mCommitOrAbortReceived)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mCommitOrAbortReceived" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10396); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mCommitOrAbortReceived" ")"); do { *((volatile int*)__null) = 10396; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((mCommitOrAbortReceived ))) { |
10397 | return nullptr; |
10398 | } |
10399 | |
10400 | RefPtr<NormalTransactionOp> actor; |
10401 | |
10402 | switch (aParams.type()) { |
10403 | case RequestParams::TObjectStoreAddParams: |
10404 | case RequestParams::TObjectStorePutParams: |
10405 | actor = new ObjectStoreAddOrPutRequestOp(SafeRefPtrFromThis(), aRequestId, |
10406 | std::move(aParams)); |
10407 | break; |
10408 | |
10409 | case RequestParams::TObjectStoreGetParams: |
10410 | actor = |
10411 | new ObjectStoreGetRequestOp(SafeRefPtrFromThis(), aRequestId, aParams, |
10412 | /* aGetAll */ false); |
10413 | break; |
10414 | |
10415 | case RequestParams::TObjectStoreGetAllParams: |
10416 | actor = |
10417 | new ObjectStoreGetRequestOp(SafeRefPtrFromThis(), aRequestId, aParams, |
10418 | /* aGetAll */ true); |
10419 | break; |
10420 | |
10421 | case RequestParams::TObjectStoreGetKeyParams: |
10422 | actor = new ObjectStoreGetKeyRequestOp(SafeRefPtrFromThis(), aRequestId, |
10423 | aParams, |
10424 | /* aGetAll */ false); |
10425 | break; |
10426 | |
10427 | case RequestParams::TObjectStoreGetAllKeysParams: |
10428 | actor = new ObjectStoreGetKeyRequestOp(SafeRefPtrFromThis(), aRequestId, |
10429 | aParams, |
10430 | /* aGetAll */ true); |
10431 | break; |
10432 | |
10433 | case RequestParams::TObjectStoreDeleteParams: |
10434 | actor = |
10435 | new ObjectStoreDeleteRequestOp(SafeRefPtrFromThis(), aRequestId, |
10436 | aParams.get_ObjectStoreDeleteParams()); |
10437 | break; |
10438 | |
10439 | case RequestParams::TObjectStoreClearParams: |
10440 | actor = |
10441 | new ObjectStoreClearRequestOp(SafeRefPtrFromThis(), aRequestId, |
10442 | aParams.get_ObjectStoreClearParams()); |
10443 | break; |
10444 | |
10445 | case RequestParams::TObjectStoreCountParams: |
10446 | actor = |
10447 | new ObjectStoreCountRequestOp(SafeRefPtrFromThis(), aRequestId, |
10448 | aParams.get_ObjectStoreCountParams()); |
10449 | break; |
10450 | |
10451 | case RequestParams::TIndexGetParams: |
10452 | actor = new IndexGetRequestOp(SafeRefPtrFromThis(), aRequestId, aParams, |
10453 | /* aGetAll */ false); |
10454 | break; |
10455 | |
10456 | case RequestParams::TIndexGetKeyParams: |
10457 | actor = |
10458 | new IndexGetKeyRequestOp(SafeRefPtrFromThis(), aRequestId, aParams, |
10459 | /* aGetAll */ false); |
10460 | break; |
10461 | |
10462 | case RequestParams::TIndexGetAllParams: |
10463 | actor = new IndexGetRequestOp(SafeRefPtrFromThis(), aRequestId, aParams, |
10464 | /* aGetAll */ true); |
10465 | break; |
10466 | |
10467 | case RequestParams::TIndexGetAllKeysParams: |
10468 | actor = |
10469 | new IndexGetKeyRequestOp(SafeRefPtrFromThis(), aRequestId, aParams, |
10470 | /* aGetAll */ true); |
10471 | break; |
10472 | |
10473 | case RequestParams::TIndexCountParams: |
10474 | actor = |
10475 | new IndexCountRequestOp(SafeRefPtrFromThis(), aRequestId, aParams); |
10476 | break; |
10477 | |
10478 | default: |
10479 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10479); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 10479; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
10480 | } |
10481 | |
10482 | MOZ_ASSERT(actor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(actor)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(actor))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("actor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10482); AnnotateMozCrashReason("MOZ_ASSERT" "(" "actor" ")" ); do { *((volatile int*)__null) = 10482; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10483 | |
10484 | // Transfer ownership to IPDL. |
10485 | return actor.forget().take(); |
10486 | } |
10487 | |
10488 | bool TransactionBase::StartRequest(PBackgroundIDBRequestParent* aActor) { |
10489 | AssertIsOnBackgroundThread(); |
10490 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10490); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 10490; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10491 | |
10492 | auto* op = static_cast<NormalTransactionOp*>(aActor); |
10493 | |
10494 | if (NS_WARN_IF(!op->Init(*this))NS_warn_if_impl(!op->Init(*this), "!op->Init(*this)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10494)) { |
10495 | op->Cleanup(); |
10496 | return false; |
10497 | } |
10498 | |
10499 | op->DispatchToConnectionPool(); |
10500 | return true; |
10501 | } |
10502 | |
10503 | bool TransactionBase::DeallocRequest( |
10504 | PBackgroundIDBRequestParent* const aActor) { |
10505 | AssertIsOnBackgroundThread(); |
10506 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10506); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 10506; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10507 | |
10508 | // Transfer ownership back from IPDL. |
10509 | const RefPtr<NormalTransactionOp> actor = |
10510 | dont_AddRef(static_cast<NormalTransactionOp*>(aActor)); |
10511 | return true; |
10512 | } |
10513 | |
10514 | already_AddRefed<PBackgroundIDBCursorParent> TransactionBase::AllocCursor( |
10515 | const OpenCursorParams& aParams, bool aTrustParams) { |
10516 | AssertIsOnBackgroundThread(); |
10517 | MOZ_ASSERT(aParams.type() != OpenCursorParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != OpenCursorParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != OpenCursorParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != OpenCursorParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10517); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != OpenCursorParams::T__None" ")"); do { *((volatile int*)__null) = 10517; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10518 | |
10519 | #ifdef DEBUG1 |
10520 | // Always verify parameters in DEBUG builds! |
10521 | aTrustParams = false; |
10522 | #endif |
10523 | |
10524 | const OpenCursorParams::Type type = aParams.type(); |
10525 | SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata; |
10526 | SafeRefPtr<FullIndexMetadata> indexMetadata; |
10527 | CursorBase::Direction direction; |
10528 | |
10529 | // First extract the parameters common to all open cursor variants. |
10530 | const auto& commonParams = GetCommonOpenCursorParams(aParams); |
10531 | objectStoreMetadata = |
10532 | GetMetadataForObjectStoreId(commonParams.objectStoreId()); |
10533 | if (NS_AUUF_OR_WARN_IF(!objectStoreMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!objectStoreMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10533); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!objectStoreMetadata" ")"); do { *((volatile int*)__null) = 10533; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!objectStoreMetadata))) { |
10534 | return nullptr; |
10535 | } |
10536 | if (aTrustParams && NS_AUUF_OR_WARN_IF(!VerifyRequestParams([](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams( commonParams.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10537); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams( commonParams.optionalKeyRange())" ")" ); do { *((volatile int*)__null) = 10537; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((!VerifyRequestParams( commonParams.optionalKeyRange()))) |
10537 | commonParams.optionalKeyRange()))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!VerifyRequestParams( commonParams.optionalKeyRange())" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10537); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!VerifyRequestParams( commonParams.optionalKeyRange())" ")" ); do { *((volatile int*)__null) = 10537; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); } return aCond ; }((!VerifyRequestParams( commonParams.optionalKeyRange())))) { |
10538 | return nullptr; |
10539 | } |
10540 | direction = commonParams.direction(); |
10541 | |
10542 | // Now, for the index open cursor variants, extract the additional parameter. |
10543 | if (type == OpenCursorParams::TIndexOpenCursorParams || |
10544 | type == OpenCursorParams::TIndexOpenKeyCursorParams) { |
10545 | const auto& commonIndexParams = GetCommonIndexOpenCursorParams(aParams); |
10546 | indexMetadata = GetMetadataForIndexId(*objectStoreMetadata, |
10547 | commonIndexParams.indexId()); |
10548 | if (NS_AUUF_OR_WARN_IF(!indexMetadata)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!indexMetadata" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10548); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10548 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!indexMetadata))) { |
10549 | return nullptr; |
10550 | } |
10551 | } |
10552 | |
10553 | if (NS_AUUF_OR_WARN_IF(mCommitOrAbortReceived)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mCommitOrAbortReceived" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10553); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mCommitOrAbortReceived" ")"); do { *((volatile int*)__null) = 10553; __attribute__((nomerge)) ::abort(); } while (false) ; } } while (false); } return aCond; }((mCommitOrAbortReceived ))) { |
10554 | return nullptr; |
10555 | } |
10556 | |
10557 | // Create Cursor and transfer ownership to IPDL. |
10558 | switch (type) { |
10559 | case OpenCursorParams::TObjectStoreOpenCursorParams: |
10560 | MOZ_ASSERT(!indexMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!indexMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!indexMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!indexMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10560); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10560; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10561 | return MakeAndAddRef<Cursor<IDBCursorType::ObjectStore>>( |
10562 | SafeRefPtrFromThis(), std::move(objectStoreMetadata), direction, |
10563 | CursorBase::ConstructFromTransactionBase{}); |
10564 | case OpenCursorParams::TObjectStoreOpenKeyCursorParams: |
10565 | MOZ_ASSERT(!indexMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!indexMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!indexMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!indexMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10565); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!indexMetadata" ")"); do { *((volatile int*)__null) = 10565; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10566 | return MakeAndAddRef<Cursor<IDBCursorType::ObjectStoreKey>>( |
10567 | SafeRefPtrFromThis(), std::move(objectStoreMetadata), direction, |
10568 | CursorBase::ConstructFromTransactionBase{}); |
10569 | case OpenCursorParams::TIndexOpenCursorParams: |
10570 | return MakeAndAddRef<Cursor<IDBCursorType::Index>>( |
10571 | SafeRefPtrFromThis(), std::move(objectStoreMetadata), |
10572 | std::move(indexMetadata), direction, |
10573 | CursorBase::ConstructFromTransactionBase{}); |
10574 | case OpenCursorParams::TIndexOpenKeyCursorParams: |
10575 | return MakeAndAddRef<Cursor<IDBCursorType::IndexKey>>( |
10576 | SafeRefPtrFromThis(), std::move(objectStoreMetadata), |
10577 | std::move(indexMetadata), direction, |
10578 | CursorBase::ConstructFromTransactionBase{}); |
10579 | default: |
10580 | MOZ_CRASH("Cannot get here.")do { do { } while (false); MOZ_ReportCrash("" "Cannot get here." , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10580); AnnotateMozCrashReason("MOZ_CRASH(" "Cannot get here." ")"); do { *((volatile int*)__null) = 10580; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
10581 | } |
10582 | } |
10583 | |
10584 | bool TransactionBase::StartCursor(PBackgroundIDBCursorParent* const aActor, |
10585 | const int64_t aRequestId, |
10586 | const OpenCursorParams& aParams) { |
10587 | AssertIsOnBackgroundThread(); |
10588 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10588); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 10588; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10589 | MOZ_ASSERT(aParams.type() != OpenCursorParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != OpenCursorParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != OpenCursorParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != OpenCursorParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10589); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != OpenCursorParams::T__None" ")"); do { *((volatile int*)__null) = 10589; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10590 | |
10591 | auto* const op = static_cast<CursorBase*>(aActor); |
10592 | |
10593 | if (NS_WARN_IF(!op->Start(aRequestId, aParams))NS_warn_if_impl(!op->Start(aRequestId, aParams), "!op->Start(aRequestId, aParams)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10593)) { |
10594 | return false; |
10595 | } |
10596 | |
10597 | return true; |
10598 | } |
10599 | |
10600 | /******************************************************************************* |
10601 | * NormalTransaction |
10602 | ******************************************************************************/ |
10603 | |
10604 | NormalTransaction::NormalTransaction( |
10605 | SafeRefPtr<Database> aDatabase, TransactionBase::Mode aMode, |
10606 | TransactionBase::Durability aDurability, |
10607 | nsTArray<SafeRefPtr<FullObjectStoreMetadata>>&& aObjectStores) |
10608 | : TransactionBase(std::move(aDatabase), aMode, aDurability), |
10609 | mObjectStores{std::move(aObjectStores)} { |
10610 | AssertIsOnBackgroundThread(); |
10611 | MOZ_ASSERT(!mObjectStores.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mObjectStores.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mObjectStores.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mObjectStores.IsEmpty()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10611); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mObjectStores.IsEmpty()" ")"); do { *((volatile int*)__null) = 10611; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10612 | } |
10613 | |
10614 | bool NormalTransaction::IsSameProcessActor() { |
10615 | AssertIsOnBackgroundThread(); |
10616 | |
10617 | PBackgroundParent* const actor = Manager()->Manager()->Manager(); |
10618 | MOZ_ASSERT(actor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(actor)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(actor))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("actor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10618); AnnotateMozCrashReason("MOZ_ASSERT" "(" "actor" ")" ); do { *((volatile int*)__null) = 10618; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10619 | |
10620 | return !BackgroundParent::IsOtherProcessActor(actor); |
10621 | } |
10622 | |
10623 | void NormalTransaction::SendCompleteNotification(nsresult aResult) { |
10624 | AssertIsOnBackgroundThread(); |
10625 | |
10626 | if (!IsActorDestroyed()) { |
10627 | Unused << SendComplete(aResult); |
10628 | } |
10629 | } |
10630 | |
10631 | void NormalTransaction::ActorDestroy(ActorDestroyReason aWhy) { |
10632 | AssertIsOnBackgroundThread(); |
10633 | |
10634 | NoteActorDestroyed(); |
10635 | |
10636 | if (!mCommittedOrAborted) { |
10637 | if (NS_SUCCEEDED(mResultCode)((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1) ))) { |
10638 | IDB_REPORT_INTERNAL_ERR()mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10638, "UnknownErr"); |
10639 | mResultCode = NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; |
10640 | } |
10641 | |
10642 | mForceAborted.EnsureFlipped(); |
10643 | |
10644 | MaybeCommitOrAbort(); |
10645 | } |
10646 | } |
10647 | |
10648 | mozilla::ipc::IPCResult NormalTransaction::RecvDeleteMe() { |
10649 | AssertIsOnBackgroundThread(); |
10650 | MOZ_ASSERT(!IsActorDestroyed())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsActorDestroyed())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsActorDestroyed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!IsActorDestroyed()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10650); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsActorDestroyed()" ")"); do { *((volatile int*)__null) = 10650; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10651 | |
10652 | QM_WARNONLY_TRY(OkIf(PBackgroundIDBTransactionParent::Send__delete__(this))){auto tryResult978 = (OkIf(PBackgroundIDBTransactionParent::Send__delete__ (this))); static_assert(std::is_empty_v<typename decltype( tryResult978)::ok_type>); if ((__builtin_expect(!!(tryResult978 .isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(PBackgroundIDBTransactionParent::Send__delete__(this))" , tryResult978.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10652, mozilla::dom::quota::Severity::Warning); }}; |
10653 | |
10654 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
10655 | } |
10656 | |
10657 | mozilla::ipc::IPCResult NormalTransaction::RecvCommit( |
10658 | const Maybe<int64_t>& aLastRequest) { |
10659 | AssertIsOnBackgroundThread(); |
10660 | |
10661 | return TransactionBase::RecvCommit(this, aLastRequest); |
10662 | } |
10663 | |
10664 | mozilla::ipc::IPCResult NormalTransaction::RecvAbort( |
10665 | const nsresult& aResultCode) { |
10666 | AssertIsOnBackgroundThread(); |
10667 | |
10668 | return TransactionBase::RecvAbort(this, aResultCode); |
10669 | } |
10670 | |
10671 | PBackgroundIDBRequestParent* |
10672 | NormalTransaction::AllocPBackgroundIDBRequestParent( |
10673 | const int64_t& aRequestId, const RequestParams& aParams) { |
10674 | AssertIsOnBackgroundThread(); |
10675 | MOZ_ASSERT(aParams.type() != RequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != RequestParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != RequestParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != RequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10675); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != RequestParams::T__None" ")"); do { *((volatile int*)__null) = 10675; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10676 | |
10677 | return AllocRequest(aRequestId, |
10678 | std::move(const_cast<RequestParams&>(aParams)), |
10679 | IsSameProcessActor()); |
10680 | } |
10681 | |
10682 | mozilla::ipc::IPCResult NormalTransaction::RecvPBackgroundIDBRequestConstructor( |
10683 | PBackgroundIDBRequestParent* const aActor, const int64_t& aRequestId, |
10684 | const RequestParams& aParams) { |
10685 | AssertIsOnBackgroundThread(); |
10686 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10686); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 10686; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10687 | MOZ_ASSERT(aParams.type() != RequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != RequestParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != RequestParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != RequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10687); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != RequestParams::T__None" ")"); do { *((volatile int*)__null) = 10687; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10688 | |
10689 | if (!StartRequest(aActor)) { |
10690 | return IPC_FAIL(this, "StartRequest failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("StartRequest failed!" )); |
10691 | } |
10692 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
10693 | } |
10694 | |
10695 | bool NormalTransaction::DeallocPBackgroundIDBRequestParent( |
10696 | PBackgroundIDBRequestParent* const aActor) { |
10697 | AssertIsOnBackgroundThread(); |
10698 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10698); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 10698; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10699 | |
10700 | return DeallocRequest(aActor); |
10701 | } |
10702 | |
10703 | already_AddRefed<PBackgroundIDBCursorParent> |
10704 | NormalTransaction::AllocPBackgroundIDBCursorParent( |
10705 | const int64_t& aRequestId, const OpenCursorParams& aParams) { |
10706 | AssertIsOnBackgroundThread(); |
10707 | |
10708 | return AllocCursor(aParams, IsSameProcessActor()); |
10709 | } |
10710 | |
10711 | mozilla::ipc::IPCResult NormalTransaction::RecvPBackgroundIDBCursorConstructor( |
10712 | PBackgroundIDBCursorParent* const aActor, const int64_t& aRequestId, |
10713 | const OpenCursorParams& aParams) { |
10714 | AssertIsOnBackgroundThread(); |
10715 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10715); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 10715; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10716 | MOZ_ASSERT(aParams.type() != OpenCursorParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != OpenCursorParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != OpenCursorParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != OpenCursorParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10716); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != OpenCursorParams::T__None" ")"); do { *((volatile int*)__null) = 10716; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10717 | |
10718 | if (!StartCursor(aActor, aRequestId, aParams)) { |
10719 | return IPC_FAIL(this, "StartCursor failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("StartCursor failed!" )); |
10720 | } |
10721 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
10722 | } |
10723 | |
10724 | /******************************************************************************* |
10725 | * VersionChangeTransaction |
10726 | ******************************************************************************/ |
10727 | |
10728 | VersionChangeTransaction::VersionChangeTransaction( |
10729 | OpenDatabaseOp* aOpenDatabaseOp) |
10730 | : TransactionBase(aOpenDatabaseOp->mDatabase.clonePtr(), |
10731 | IDBTransaction::Mode::VersionChange, |
10732 | // VersionChange must not change durability. |
10733 | IDBTransaction::Durability::Default), // Not used. |
10734 | mOpenDatabaseOp(aOpenDatabaseOp) { |
10735 | AssertIsOnBackgroundThread(); |
10736 | MOZ_ASSERT(aOpenDatabaseOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aOpenDatabaseOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aOpenDatabaseOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aOpenDatabaseOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10736); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aOpenDatabaseOp" ")"); do { *((volatile int*)__null) = 10736; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10737 | } |
10738 | |
10739 | VersionChangeTransaction::~VersionChangeTransaction() { |
10740 | #ifdef DEBUG1 |
10741 | // Silence the base class' destructor assertion if we never made this actor |
10742 | // live. |
10743 | FakeActorDestroyed(); |
10744 | #endif |
10745 | } |
10746 | |
10747 | bool VersionChangeTransaction::IsSameProcessActor() { |
10748 | AssertIsOnBackgroundThread(); |
10749 | |
10750 | PBackgroundParent* actor = Manager()->Manager()->Manager(); |
10751 | MOZ_ASSERT(actor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(actor)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(actor))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("actor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10751); AnnotateMozCrashReason("MOZ_ASSERT" "(" "actor" ")" ); do { *((volatile int*)__null) = 10751; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10752 | |
10753 | return !BackgroundParent::IsOtherProcessActor(actor); |
10754 | } |
10755 | |
10756 | void VersionChangeTransaction::SetActorAlive() { |
10757 | AssertIsOnBackgroundThread(); |
10758 | MOZ_ASSERT(!IsActorDestroyed())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsActorDestroyed())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsActorDestroyed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!IsActorDestroyed()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10758); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsActorDestroyed()" ")"); do { *((volatile int*)__null) = 10758; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10759 | |
10760 | mActorWasAlive.Flip(); |
10761 | } |
10762 | |
10763 | bool VersionChangeTransaction::CopyDatabaseMetadata() { |
10764 | AssertIsOnBackgroundThread(); |
10765 | MOZ_ASSERT(!mOldMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mOldMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mOldMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mOldMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10765); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mOldMetadata" ")"); do { *((volatile int*)__null) = 10765; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10766 | |
10767 | const auto& origMetadata = GetDatabase().Metadata(); |
10768 | |
10769 | SafeRefPtr<FullDatabaseMetadata> newMetadata = origMetadata.Duplicate(); |
10770 | if (NS_WARN_IF(!newMetadata)NS_warn_if_impl(!newMetadata, "!newMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10770)) { |
10771 | return false; |
10772 | } |
10773 | |
10774 | // Replace the live metadata with the new mutable copy. |
10775 | DatabaseActorInfo* info; |
10776 | MOZ_ALWAYS_TRUE(gLiveDatabaseHashtable->Get(origMetadata.mDatabaseId, &info))do { if ((__builtin_expect(!!(gLiveDatabaseHashtable->Get( origMetadata.mDatabaseId, &info)), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "gLiveDatabaseHashtable->Get(origMetadata.mDatabaseId, &info)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10776); AnnotateMozCrashReason("MOZ_CRASH(" "gLiveDatabaseHashtable->Get(origMetadata.mDatabaseId, &info)" ")"); do { *((volatile int*)__null) = 10776; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
10777 | MOZ_ASSERT(!info->mLiveDatabases.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!info->mLiveDatabases.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!info->mLiveDatabases.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!info->mLiveDatabases.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10777); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!info->mLiveDatabases.IsEmpty()" ")"); do { *((volatile int*)__null) = 10777; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10778 | MOZ_ASSERT(info->mMetadata == &origMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(info->mMetadata == &origMetadata)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(info->mMetadata == &origMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("info->mMetadata == &origMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10778); AnnotateMozCrashReason("MOZ_ASSERT" "(" "info->mMetadata == &origMetadata" ")"); do { *((volatile int*)__null) = 10778; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10779 | |
10780 | mOldMetadata = std::move(info->mMetadata); |
10781 | info->mMetadata = std::move(newMetadata); |
10782 | |
10783 | // Replace metadata pointers for all live databases. |
10784 | for (const auto& liveDatabase : info->mLiveDatabases) { |
10785 | liveDatabase->mMetadata = info->mMetadata.clonePtr(); |
10786 | } |
10787 | |
10788 | return true; |
10789 | } |
10790 | |
10791 | void VersionChangeTransaction::UpdateMetadata(nsresult aResult) { |
10792 | AssertIsOnBackgroundThread(); |
10793 | MOZ_ASSERT(mOpenDatabaseOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOpenDatabaseOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOpenDatabaseOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOpenDatabaseOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10793); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOpenDatabaseOp" ")"); do { *((volatile int*)__null) = 10793; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10794 | MOZ_ASSERT(!!mActorWasAlive == !!mOpenDatabaseOp->mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!!mActorWasAlive == !!mOpenDatabaseOp->mDatabase) >::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(!!mActorWasAlive == !!mOpenDatabaseOp->mDatabase) )), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!!mActorWasAlive == !!mOpenDatabaseOp->mDatabase" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10794); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!!mActorWasAlive == !!mOpenDatabaseOp->mDatabase" ")"); do { *((volatile int*)__null) = 10794; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10795 | MOZ_ASSERT_IF(mActorWasAlive, !mOpenDatabaseOp->mDatabaseId.ref().IsEmpty())do { if (mActorWasAlive) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(!mOpenDatabaseOp->mDatabaseId .ref().IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mOpenDatabaseOp->mDatabaseId .ref().IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!mOpenDatabaseOp->mDatabaseId.ref().IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10795); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mOpenDatabaseOp->mDatabaseId.ref().IsEmpty()" ")"); do { *((volatile int*)__null) = 10795; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
10796 | |
10797 | if (IsActorDestroyed() || !mActorWasAlive) { |
10798 | return; |
10799 | } |
10800 | |
10801 | SafeRefPtr<FullDatabaseMetadata> oldMetadata = std::move(mOldMetadata); |
10802 | |
10803 | DatabaseActorInfo* info; |
10804 | if (!gLiveDatabaseHashtable->Get(oldMetadata->mDatabaseId, &info)) { |
10805 | return; |
10806 | } |
10807 | |
10808 | MOZ_ASSERT(!info->mLiveDatabases.IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!info->mLiveDatabases.IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!info->mLiveDatabases.IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!info->mLiveDatabases.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10808); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!info->mLiveDatabases.IsEmpty()" ")"); do { *((volatile int*)__null) = 10808; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10809 | |
10810 | if (NS_SUCCEEDED(aResult)((bool)(__builtin_expect(!!(!NS_FAILED_impl(aResult)), 1)))) { |
10811 | // Remove all deleted objectStores and indexes, then mark immutable. |
10812 | info->mMetadata->mObjectStores.RemoveIf([](const auto& objectStoreIter) { |
10813 | MOZ_ASSERT(objectStoreIter.Key())do { static_assert( mozilla::detail::AssertionConditionType< decltype(objectStoreIter.Key())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(objectStoreIter.Key()))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("objectStoreIter.Key()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10813); AnnotateMozCrashReason("MOZ_ASSERT" "(" "objectStoreIter.Key()" ")"); do { *((volatile int*)__null) = 10813; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10814 | const SafeRefPtr<FullObjectStoreMetadata>& metadata = |
10815 | objectStoreIter.Data(); |
10816 | MOZ_ASSERT(metadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(metadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(metadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("metadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10816); AnnotateMozCrashReason("MOZ_ASSERT" "(" "metadata" ")" ); do { *((volatile int*)__null) = 10816; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10817 | |
10818 | if (metadata->mDeleted) { |
10819 | return true; |
10820 | } |
10821 | |
10822 | metadata->mIndexes.RemoveIf([](const auto& indexIter) -> bool { |
10823 | MOZ_ASSERT(indexIter.Key())do { static_assert( mozilla::detail::AssertionConditionType< decltype(indexIter.Key())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(indexIter.Key()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("indexIter.Key()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10823); AnnotateMozCrashReason("MOZ_ASSERT" "(" "indexIter.Key()" ")"); do { *((volatile int*)__null) = 10823; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10824 | const SafeRefPtr<FullIndexMetadata>& index = indexIter.Data(); |
10825 | MOZ_ASSERT(index)do { static_assert( mozilla::detail::AssertionConditionType< decltype(index)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(index))), 0))) { do { } while ( false); MOZ_ReportAssertionFailure("index", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10825); AnnotateMozCrashReason("MOZ_ASSERT" "(" "index" ")" ); do { *((volatile int*)__null) = 10825; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
10826 | |
10827 | return index->mDeleted; |
10828 | }); |
10829 | metadata->mIndexes.MarkImmutable(); |
10830 | |
10831 | return false; |
10832 | }); |
10833 | |
10834 | info->mMetadata->mObjectStores.MarkImmutable(); |
10835 | } else { |
10836 | // Replace metadata pointers for all live databases. |
10837 | info->mMetadata = std::move(oldMetadata); |
10838 | |
10839 | for (auto& liveDatabase : info->mLiveDatabases) { |
10840 | liveDatabase->mMetadata = info->mMetadata.clonePtr(); |
10841 | } |
10842 | } |
10843 | } |
10844 | |
10845 | void VersionChangeTransaction::SendCompleteNotification(nsresult aResult) { |
10846 | AssertIsOnBackgroundThread(); |
10847 | MOZ_ASSERT(mOpenDatabaseOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mOpenDatabaseOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOpenDatabaseOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOpenDatabaseOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10847); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOpenDatabaseOp" ")"); do { *((volatile int*)__null) = 10847; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10848 | MOZ_ASSERT(!mOpenDatabaseOp->mCompleteCallback)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mOpenDatabaseOp->mCompleteCallback)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(!mOpenDatabaseOp->mCompleteCallback))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!mOpenDatabaseOp->mCompleteCallback" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10848); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mOpenDatabaseOp->mCompleteCallback" ")"); do { *((volatile int*)__null) = 10848; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10849 | MOZ_ASSERT_IF(!mActorWasAlive, mOpenDatabaseOp->HasFailed())do { if (!mActorWasAlive) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(mOpenDatabaseOp->HasFailed ())>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(mOpenDatabaseOp->HasFailed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOpenDatabaseOp->HasFailed()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10849); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOpenDatabaseOp->HasFailed()" ")"); do { *((volatile int*)__null) = 10849; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
10850 | MOZ_ASSERT_IF(!mActorWasAlive, mOpenDatabaseOp->mState >do { if (!mActorWasAlive) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10851); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults" ")"); do { *((volatile int*)__null) = 10851; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
10851 | OpenDatabaseOp::State::SendingResults)do { if (!mActorWasAlive) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10851); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mOpenDatabaseOp->mState > OpenDatabaseOp::State::SendingResults" ")"); do { *((volatile int*)__null) = 10851; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
10852 | |
10853 | const RefPtr<OpenDatabaseOp> openDatabaseOp = std::move(mOpenDatabaseOp); |
10854 | |
10855 | if (!mActorWasAlive) { |
10856 | return; |
10857 | } |
10858 | |
10859 | openDatabaseOp->mCompleteCallback = |
10860 | [self = SafeRefPtr{this, AcquireStrongRefFromRawPtr{}}, aResult]() { |
10861 | if (!self->IsActorDestroyed()) { |
10862 | Unused << self->SendComplete(aResult); |
10863 | } |
10864 | }; |
10865 | |
10866 | auto handleError = [openDatabaseOp](const nsresult rv) { |
10867 | openDatabaseOp->SetFailureCodeIfUnset(NS_ERROR_DOM_INDEXEDDB_ABORT_ERR); |
10868 | |
10869 | openDatabaseOp->mState = OpenDatabaseOp::State::SendingResults; |
10870 | |
10871 | MOZ_ALWAYS_SUCCEEDS(openDatabaseOp->Run())do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (openDatabaseOp->Run())), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(openDatabaseOp->Run())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10871); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(openDatabaseOp->Run())" ")"); do { *((volatile int*)__null) = 10871; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
10872 | }; |
10873 | |
10874 | if (NS_FAILED(aResult)((bool)(__builtin_expect(!!(NS_FAILED_impl(aResult)), 0)))) { |
10875 | // 3.3.1 Opening a database: |
10876 | // "If the upgrade transaction was aborted, run the steps for closing a |
10877 | // database connection with connection, create and return a new AbortError |
10878 | // exception and abort these steps." |
10879 | handleError(NS_ERROR_DOM_INDEXEDDB_ABORT_ERR); |
10880 | return; |
10881 | } |
10882 | |
10883 | openDatabaseOp->mState = OpenDatabaseOp::State::DatabaseWorkVersionUpdate; |
10884 | |
10885 | QuotaManager* const quotaManager = QuotaManager::Get(); |
10886 | MOZ_ASSERT(quotaManager)do { static_assert( mozilla::detail::AssertionConditionType< decltype(quotaManager)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(quotaManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("quotaManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10886); AnnotateMozCrashReason("MOZ_ASSERT" "(" "quotaManager" ")"); do { *((volatile int*)__null) = 10886; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10887 | |
10888 | QM_TRY(MOZ_TO_RESULT(quotaManager->IOThread()->Dispatch(openDatabaseOp,{auto tryResult979 = (ToResult(quotaManager->IOThread()-> Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr ( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })); static_assert(std::is_empty_v<typename decltype(tryResult979 )::ok_type>); if ((__builtin_expect(!!(tryResult979.isErr( )), 0))) { auto tryTempError = tryResult979.unwrapErr(); mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10892, mozilla::dom::quota::Severity::Error); handleError(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; }} |
10889 | NS_DISPATCH_NORMAL)){auto tryResult979 = (ToResult(quotaManager->IOThread()-> Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr ( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })); static_assert(std::is_empty_v<typename decltype(tryResult979 )::ok_type>); if ((__builtin_expect(!!(tryResult979.isErr( )), 0))) { auto tryTempError = tryResult979.unwrapErr(); mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10892, mozilla::dom::quota::Severity::Error); handleError(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; }} |
10890 | .mapErr({auto tryResult979 = (ToResult(quotaManager->IOThread()-> Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr ( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })); static_assert(std::is_empty_v<typename decltype(tryResult979 )::ok_type>); if ((__builtin_expect(!!(tryResult979.isErr( )), 0))) { auto tryTempError = tryResult979.unwrapErr(); mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10892, mozilla::dom::quota::Severity::Error); handleError(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; }} |
10891 | [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; }),{auto tryResult979 = (ToResult(quotaManager->IOThread()-> Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr ( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })); static_assert(std::is_empty_v<typename decltype(tryResult979 )::ok_type>); if ((__builtin_expect(!!(tryResult979.isErr( )), 0))) { auto tryTempError = tryResult979.unwrapErr(); mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10892, mozilla::dom::quota::Severity::Error); handleError(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; }} |
10892 | QM_VOID, handleError){auto tryResult979 = (ToResult(quotaManager->IOThread()-> Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr ( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })); static_assert(std::is_empty_v<typename decltype(tryResult979 )::ok_type>); if ((__builtin_expect(!!(tryResult979.isErr( )), 0))) { auto tryTempError = tryResult979.unwrapErr(); mozilla ::dom::quota::HandleError("ToResult(quotaManager->IOThread()->Dispatch(openDatabaseOp, nsIEventTarget::DISPATCH_NORMAL)) .mapErr( [](const auto) { return NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; })" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10892, mozilla::dom::quota::Severity::Error); handleError(tryTempError ); constexpr const auto& func __attribute__((__unused__)) = __func__; return ; }}; |
10893 | } |
10894 | |
10895 | void VersionChangeTransaction::ActorDestroy(ActorDestroyReason aWhy) { |
10896 | AssertIsOnBackgroundThread(); |
10897 | |
10898 | NoteActorDestroyed(); |
10899 | |
10900 | if (!mCommittedOrAborted) { |
10901 | if (NS_SUCCEEDED(mResultCode)((bool)(__builtin_expect(!!(!NS_FAILED_impl(mResultCode)), 1) ))) { |
10902 | IDB_REPORT_INTERNAL_ERR()mozilla::dom::indexedDB::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10902, "UnknownErr"); |
10903 | mResultCode = NS_ERROR_DOM_INDEXEDDB_UNKNOWN_ERR; |
10904 | } |
10905 | |
10906 | mForceAborted.EnsureFlipped(); |
10907 | |
10908 | MaybeCommitOrAbort(); |
10909 | } |
10910 | } |
10911 | |
10912 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvDeleteMe() { |
10913 | AssertIsOnBackgroundThread(); |
10914 | MOZ_ASSERT(!IsActorDestroyed())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsActorDestroyed())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsActorDestroyed()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!IsActorDestroyed()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10914); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsActorDestroyed()" ")"); do { *((volatile int*)__null) = 10914; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10915 | |
10916 | QM_WARNONLY_TRY({auto tryResult980 = (OkIf(PBackgroundIDBVersionChangeTransactionParent ::Send__delete__(this))); static_assert(std::is_empty_v<typename decltype(tryResult980)::ok_type>); if ((__builtin_expect( !!(tryResult980.isErr()), 0))) { mozilla::dom::quota::HandleError ("OkIf(PBackgroundIDBVersionChangeTransactionParent::Send__delete__(this))" , tryResult980.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10917, mozilla::dom::quota::Severity::Warning); }} |
10917 | OkIf(PBackgroundIDBVersionChangeTransactionParent::Send__delete__(this))){auto tryResult980 = (OkIf(PBackgroundIDBVersionChangeTransactionParent ::Send__delete__(this))); static_assert(std::is_empty_v<typename decltype(tryResult980)::ok_type>); if ((__builtin_expect( !!(tryResult980.isErr()), 0))) { mozilla::dom::quota::HandleError ("OkIf(PBackgroundIDBVersionChangeTransactionParent::Send__delete__(this))" , tryResult980.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10917, mozilla::dom::quota::Severity::Warning); }}; |
10918 | |
10919 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
10920 | } |
10921 | |
10922 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvCommit( |
10923 | const Maybe<int64_t>& aLastRequest) { |
10924 | AssertIsOnBackgroundThread(); |
10925 | |
10926 | return TransactionBase::RecvCommit(this, aLastRequest); |
10927 | } |
10928 | |
10929 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvAbort( |
10930 | const nsresult& aResultCode) { |
10931 | AssertIsOnBackgroundThread(); |
10932 | |
10933 | return TransactionBase::RecvAbort(this, aResultCode); |
10934 | } |
10935 | |
10936 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvCreateObjectStore( |
10937 | const ObjectStoreMetadata& aMetadata) { |
10938 | AssertIsOnBackgroundThread(); |
10939 | |
10940 | if (NS_WARN_IF(!aMetadata.id())NS_warn_if_impl(!aMetadata.id(), "!aMetadata.id()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10940)) { |
10941 | return IPC_FAIL(this, "No metadata ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No metadata ID!" )); |
10942 | } |
10943 | |
10944 | const SafeRefPtr<FullDatabaseMetadata> dbMetadata = |
10945 | GetDatabase().MetadataPtr(); |
10946 | |
10947 | if (NS_WARN_IF(aMetadata.id() != dbMetadata->mNextObjectStoreId)NS_warn_if_impl(aMetadata.id() != dbMetadata->mNextObjectStoreId , "aMetadata.id() != dbMetadata->mNextObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10947)) { |
10948 | return IPC_FAIL(this, "Requested metadata ID does not match next ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Requested metadata ID does not match next ID!" )); |
10949 | } |
10950 | |
10951 | if (NS_WARN_IF(NS_warn_if_impl(MatchMetadataNameOrId(dbMetadata->mObjectStores , aMetadata.id(), SomeRef<const nsAString&>(aMetadata .name())) .isSome(), "MatchMetadataNameOrId(dbMetadata->mObjectStores, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10954) |
10952 | MatchMetadataNameOrId(dbMetadata->mObjectStores, aMetadata.id(),NS_warn_if_impl(MatchMetadataNameOrId(dbMetadata->mObjectStores , aMetadata.id(), SomeRef<const nsAString&>(aMetadata .name())) .isSome(), "MatchMetadataNameOrId(dbMetadata->mObjectStores, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10954) |
10953 | SomeRef<const nsAString&>(aMetadata.name()))NS_warn_if_impl(MatchMetadataNameOrId(dbMetadata->mObjectStores , aMetadata.id(), SomeRef<const nsAString&>(aMetadata .name())) .isSome(), "MatchMetadataNameOrId(dbMetadata->mObjectStores, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10954) |
10954 | .isSome())NS_warn_if_impl(MatchMetadataNameOrId(dbMetadata->mObjectStores , aMetadata.id(), SomeRef<const nsAString&>(aMetadata .name())) .isSome(), "MatchMetadataNameOrId(dbMetadata->mObjectStores, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10954)) { |
10955 | return IPC_FAIL(this, "MatchMetadataNameOrId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("MatchMetadataNameOrId failed!" )); |
10956 | } |
10957 | |
10958 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10958)) { |
10959 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
10960 | } |
10961 | |
10962 | const int64_t initialAutoIncrementId = aMetadata.autoIncrement() ? 1 : 0; |
10963 | auto newMetadata = MakeSafeRefPtr<FullObjectStoreMetadata>( |
10964 | aMetadata, FullObjectStoreMetadata::AutoIncrementIds{ |
10965 | initialAutoIncrementId, initialAutoIncrementId}); |
10966 | |
10967 | if (NS_WARN_IF(!dbMetadata->mObjectStores.InsertOrUpdate(NS_warn_if_impl(!dbMetadata->mObjectStores.InsertOrUpdate( aMetadata.id(), std::move(newMetadata), fallible), "!dbMetadata->mObjectStores.InsertOrUpdate( aMetadata.id(), std::move(newMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10968) |
10968 | aMetadata.id(), std::move(newMetadata), fallible))NS_warn_if_impl(!dbMetadata->mObjectStores.InsertOrUpdate( aMetadata.id(), std::move(newMetadata), fallible), "!dbMetadata->mObjectStores.InsertOrUpdate( aMetadata.id(), std::move(newMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10968)) { |
10969 | return IPC_FAIL(this, "mObjectStores.InsertOrUpdate failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("mObjectStores.InsertOrUpdate failed!" )); |
10970 | } |
10971 | |
10972 | dbMetadata->mNextObjectStoreId++; |
10973 | |
10974 | RefPtr<CreateObjectStoreOp> op = new CreateObjectStoreOp( |
10975 | SafeRefPtrFromThis().downcast<VersionChangeTransaction>(), aMetadata); |
10976 | |
10977 | if (NS_WARN_IF(!op->Init(*this))NS_warn_if_impl(!op->Init(*this), "!op->Init(*this)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10977)) { |
10978 | op->Cleanup(); |
10979 | return IPC_FAIL(this, "ObjectStoreOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ObjectStoreOp initialization failed!" )); |
10980 | } |
10981 | |
10982 | op->DispatchToConnectionPool(); |
10983 | |
10984 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
10985 | } |
10986 | |
10987 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvDeleteObjectStore( |
10988 | const IndexOrObjectStoreId& aObjectStoreId) { |
10989 | AssertIsOnBackgroundThread(); |
10990 | |
10991 | if (NS_WARN_IF(!aObjectStoreId)NS_warn_if_impl(!aObjectStoreId, "!aObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10991)) { |
10992 | return IPC_FAIL(this, "No ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No ObjectStoreId!" )); |
10993 | } |
10994 | |
10995 | const auto& dbMetadata = GetDatabase().Metadata(); |
10996 | MOZ_ASSERT(dbMetadata.mNextObjectStoreId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata.mNextObjectStoreId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbMetadata.mNextObjectStoreId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbMetadata.mNextObjectStoreId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10996); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata.mNextObjectStoreId > 0" ")"); do { *((volatile int*)__null) = 10996; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
10997 | |
10998 | if (NS_WARN_IF(aObjectStoreId >= dbMetadata.mNextObjectStoreId)NS_warn_if_impl(aObjectStoreId >= dbMetadata.mNextObjectStoreId , "aObjectStoreId >= dbMetadata.mNextObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 10998)) { |
10999 | return IPC_FAIL(this, "Invalid ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Invalid ObjectStoreId!" )); |
11000 | } |
11001 | |
11002 | SafeRefPtr<FullObjectStoreMetadata> foundMetadata = |
11003 | GetMetadataForObjectStoreId(aObjectStoreId); |
11004 | |
11005 | if (NS_WARN_IF(!foundMetadata)NS_warn_if_impl(!foundMetadata, "!foundMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11005)) { |
11006 | return IPC_FAIL(this, "No metadata found for ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No metadata found for ObjectStoreId!" )); |
11007 | } |
11008 | |
11009 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11009)) { |
11010 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
11011 | } |
11012 | |
11013 | foundMetadata->mDeleted.Flip(); |
11014 | |
11015 | DebugOnly<bool> foundTargetId = false; |
11016 | const bool isLastObjectStore = std::all_of( |
11017 | dbMetadata.mObjectStores.begin(), dbMetadata.mObjectStores.end(), |
11018 | [&foundTargetId, aObjectStoreId](const auto& objectStoreEntry) -> bool { |
11019 | if (uint64_t(aObjectStoreId) == objectStoreEntry.GetKey()) { |
11020 | foundTargetId = true; |
11021 | return true; |
11022 | } |
11023 | |
11024 | return objectStoreEntry.GetData()->mDeleted; |
11025 | }); |
11026 | MOZ_ASSERT_IF(isLastObjectStore, foundTargetId)do { if (isLastObjectStore) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(foundTargetId)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(foundTargetId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("foundTargetId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11026); AnnotateMozCrashReason("MOZ_ASSERT" "(" "foundTargetId" ")"); do { *((volatile int*)__null) = 11026; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
11027 | |
11028 | RefPtr<DeleteObjectStoreOp> op = new DeleteObjectStoreOp( |
11029 | SafeRefPtrFromThis().downcast<VersionChangeTransaction>(), |
11030 | std::move(foundMetadata), isLastObjectStore); |
11031 | |
11032 | if (NS_WARN_IF(!op->Init(*this))NS_warn_if_impl(!op->Init(*this), "!op->Init(*this)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11032)) { |
11033 | op->Cleanup(); |
11034 | return IPC_FAIL(this, "ObjectStoreOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ObjectStoreOp initialization failed!" )); |
11035 | } |
11036 | |
11037 | op->DispatchToConnectionPool(); |
11038 | |
11039 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11040 | } |
11041 | |
11042 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvRenameObjectStore( |
11043 | const IndexOrObjectStoreId& aObjectStoreId, const nsAString& aName) { |
11044 | AssertIsOnBackgroundThread(); |
11045 | |
11046 | if (NS_WARN_IF(!aObjectStoreId)NS_warn_if_impl(!aObjectStoreId, "!aObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11046)) { |
11047 | return IPC_FAIL(this, "No ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No ObjectStoreId!" )); |
11048 | } |
11049 | |
11050 | { |
11051 | const auto& dbMetadata = GetDatabase().Metadata(); |
11052 | MOZ_ASSERT(dbMetadata.mNextObjectStoreId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata.mNextObjectStoreId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbMetadata.mNextObjectStoreId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbMetadata.mNextObjectStoreId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11052); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata.mNextObjectStoreId > 0" ")"); do { *((volatile int*)__null) = 11052; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11053 | |
11054 | if (NS_WARN_IF(aObjectStoreId >= dbMetadata.mNextObjectStoreId)NS_warn_if_impl(aObjectStoreId >= dbMetadata.mNextObjectStoreId , "aObjectStoreId >= dbMetadata.mNextObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11054)) { |
11055 | return IPC_FAIL(this, "Invalid ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Invalid ObjectStoreId!" )); |
11056 | } |
11057 | } |
11058 | |
11059 | SafeRefPtr<FullObjectStoreMetadata> foundMetadata = |
11060 | GetMetadataForObjectStoreId(aObjectStoreId); |
11061 | |
11062 | if (NS_WARN_IF(!foundMetadata)NS_warn_if_impl(!foundMetadata, "!foundMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11062)) { |
11063 | return IPC_FAIL(this, "No metadata found for ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No metadata found for ObjectStoreId!" )); |
11064 | } |
11065 | |
11066 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11066)) { |
11067 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
11068 | } |
11069 | |
11070 | foundMetadata->mCommonMetadata.name() = aName; |
11071 | |
11072 | RefPtr<RenameObjectStoreOp> renameOp = new RenameObjectStoreOp( |
11073 | SafeRefPtrFromThis().downcast<VersionChangeTransaction>(), |
11074 | *foundMetadata); |
11075 | |
11076 | if (NS_WARN_IF(!renameOp->Init(*this))NS_warn_if_impl(!renameOp->Init(*this), "!renameOp->Init(*this)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11076)) { |
11077 | renameOp->Cleanup(); |
11078 | return IPC_FAIL(this, "ObjectStoreOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ObjectStoreOp initialization failed!" )); |
11079 | } |
11080 | |
11081 | renameOp->DispatchToConnectionPool(); |
11082 | |
11083 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11084 | } |
11085 | |
11086 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvCreateIndex( |
11087 | const IndexOrObjectStoreId& aObjectStoreId, |
11088 | const IndexMetadata& aMetadata) { |
11089 | AssertIsOnBackgroundThread(); |
11090 | |
11091 | if (NS_WARN_IF(!aObjectStoreId)NS_warn_if_impl(!aObjectStoreId, "!aObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11091)) { |
11092 | return IPC_FAIL(this, "No ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No ObjectStoreId!" )); |
11093 | } |
11094 | |
11095 | if (NS_WARN_IF(!aMetadata.id())NS_warn_if_impl(!aMetadata.id(), "!aMetadata.id()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11095)) { |
11096 | return IPC_FAIL(this, "No Metadata id!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No Metadata id!" )); |
11097 | } |
11098 | |
11099 | const auto dbMetadata = GetDatabase().MetadataPtr(); |
11100 | |
11101 | if (NS_WARN_IF(aMetadata.id() != dbMetadata->mNextIndexId)NS_warn_if_impl(aMetadata.id() != dbMetadata->mNextIndexId , "aMetadata.id() != dbMetadata->mNextIndexId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11101)) { |
11102 | return IPC_FAIL(this, "Requested metadata ID does not match next ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Requested metadata ID does not match next ID!" )); |
11103 | } |
11104 | |
11105 | SafeRefPtr<FullObjectStoreMetadata> foundObjectStoreMetadata = |
11106 | GetMetadataForObjectStoreId(aObjectStoreId); |
11107 | |
11108 | if (NS_WARN_IF(!foundObjectStoreMetadata)NS_warn_if_impl(!foundObjectStoreMetadata, "!foundObjectStoreMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11108)) { |
11109 | return IPC_FAIL(this, "GetMetadataForObjectStoreId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("GetMetadataForObjectStoreId failed!" )); |
11110 | } |
11111 | |
11112 | if (NS_WARN_IF(MatchMetadataNameOrId(NS_warn_if_impl(MatchMetadataNameOrId( foundObjectStoreMetadata ->mIndexes, aMetadata.id(), SomeRef<const nsAString& >(aMetadata.name())) .isSome(), "MatchMetadataNameOrId( foundObjectStoreMetadata->mIndexes, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11115) |
11113 | foundObjectStoreMetadata->mIndexes, aMetadata.id(),NS_warn_if_impl(MatchMetadataNameOrId( foundObjectStoreMetadata ->mIndexes, aMetadata.id(), SomeRef<const nsAString& >(aMetadata.name())) .isSome(), "MatchMetadataNameOrId( foundObjectStoreMetadata->mIndexes, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11115) |
11114 | SomeRef<const nsAString&>(aMetadata.name()))NS_warn_if_impl(MatchMetadataNameOrId( foundObjectStoreMetadata ->mIndexes, aMetadata.id(), SomeRef<const nsAString& >(aMetadata.name())) .isSome(), "MatchMetadataNameOrId( foundObjectStoreMetadata->mIndexes, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11115) |
11115 | .isSome())NS_warn_if_impl(MatchMetadataNameOrId( foundObjectStoreMetadata ->mIndexes, aMetadata.id(), SomeRef<const nsAString& >(aMetadata.name())) .isSome(), "MatchMetadataNameOrId( foundObjectStoreMetadata->mIndexes, aMetadata.id(), SomeRef<const nsAString&>(aMetadata.name())) .isSome()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11115)) { |
11116 | return IPC_FAIL(this, "MatchMetadataNameOrId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("MatchMetadataNameOrId failed!" )); |
11117 | } |
11118 | |
11119 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11119)) { |
11120 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
11121 | } |
11122 | |
11123 | auto newMetadata = MakeSafeRefPtr<FullIndexMetadata>(); |
11124 | newMetadata->mCommonMetadata = aMetadata; |
11125 | |
11126 | if (NS_WARN_IF(!foundObjectStoreMetadata->mIndexes.InsertOrUpdate(NS_warn_if_impl(!foundObjectStoreMetadata->mIndexes.InsertOrUpdate ( aMetadata.id(), std::move(newMetadata), fallible), "!foundObjectStoreMetadata->mIndexes.InsertOrUpdate( aMetadata.id(), std::move(newMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11127) |
11127 | aMetadata.id(), std::move(newMetadata), fallible))NS_warn_if_impl(!foundObjectStoreMetadata->mIndexes.InsertOrUpdate ( aMetadata.id(), std::move(newMetadata), fallible), "!foundObjectStoreMetadata->mIndexes.InsertOrUpdate( aMetadata.id(), std::move(newMetadata), fallible)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11127)) { |
11128 | return IPC_FAIL(this, "mIndexes.InsertOrUpdate failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("mIndexes.InsertOrUpdate failed!" )); |
11129 | } |
11130 | |
11131 | dbMetadata->mNextIndexId++; |
11132 | |
11133 | RefPtr<CreateIndexOp> op = new CreateIndexOp( |
11134 | SafeRefPtrFromThis().downcast<VersionChangeTransaction>(), aObjectStoreId, |
11135 | aMetadata); |
11136 | |
11137 | if (NS_WARN_IF(!op->Init(*this))NS_warn_if_impl(!op->Init(*this), "!op->Init(*this)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11137)) { |
11138 | op->Cleanup(); |
11139 | return IPC_FAIL(this, "ObjectStoreOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ObjectStoreOp initialization failed!" )); |
11140 | } |
11141 | |
11142 | op->DispatchToConnectionPool(); |
11143 | |
11144 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11145 | } |
11146 | |
11147 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvDeleteIndex( |
11148 | const IndexOrObjectStoreId& aObjectStoreId, |
11149 | const IndexOrObjectStoreId& aIndexId) { |
11150 | AssertIsOnBackgroundThread(); |
11151 | |
11152 | if (NS_WARN_IF(!aObjectStoreId)NS_warn_if_impl(!aObjectStoreId, "!aObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11152)) { |
11153 | return IPC_FAIL(this, "No ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No ObjectStoreId!" )); |
11154 | } |
11155 | |
11156 | if (NS_WARN_IF(!aIndexId)NS_warn_if_impl(!aIndexId, "!aIndexId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11156)) { |
11157 | return IPC_FAIL(this, "No Index id!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No Index id!" )); |
11158 | } |
11159 | { |
11160 | const auto& dbMetadata = GetDatabase().Metadata(); |
11161 | MOZ_ASSERT(dbMetadata.mNextObjectStoreId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata.mNextObjectStoreId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbMetadata.mNextObjectStoreId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbMetadata.mNextObjectStoreId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11161); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata.mNextObjectStoreId > 0" ")"); do { *((volatile int*)__null) = 11161; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11162 | MOZ_ASSERT(dbMetadata.mNextIndexId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata.mNextIndexId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbMetadata.mNextIndexId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbMetadata.mNextIndexId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11162); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata.mNextIndexId > 0" ")"); do { *((volatile int*)__null) = 11162; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11163 | |
11164 | if (NS_WARN_IF(aObjectStoreId >= dbMetadata.mNextObjectStoreId)NS_warn_if_impl(aObjectStoreId >= dbMetadata.mNextObjectStoreId , "aObjectStoreId >= dbMetadata.mNextObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11164)) { |
11165 | return IPC_FAIL(this, "Requested ObjectStoreId does not match next ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Requested ObjectStoreId does not match next ID!" )); |
11166 | } |
11167 | |
11168 | if (NS_WARN_IF(aIndexId >= dbMetadata.mNextIndexId)NS_warn_if_impl(aIndexId >= dbMetadata.mNextIndexId, "aIndexId >= dbMetadata.mNextIndexId" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11168)) { |
11169 | return IPC_FAIL(this, "Requested IndexId does not match next ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Requested IndexId does not match next ID!" )); |
11170 | } |
11171 | } |
11172 | |
11173 | SafeRefPtr<FullObjectStoreMetadata> foundObjectStoreMetadata = |
11174 | GetMetadataForObjectStoreId(aObjectStoreId); |
11175 | |
11176 | if (NS_WARN_IF(!foundObjectStoreMetadata)NS_warn_if_impl(!foundObjectStoreMetadata, "!foundObjectStoreMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11176)) { |
11177 | return IPC_FAIL(this, "GetMetadataForObjectStoreId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("GetMetadataForObjectStoreId failed!" )); |
11178 | } |
11179 | |
11180 | SafeRefPtr<FullIndexMetadata> foundIndexMetadata = |
11181 | GetMetadataForIndexId(*foundObjectStoreMetadata, aIndexId); |
11182 | |
11183 | if (NS_WARN_IF(!foundIndexMetadata)NS_warn_if_impl(!foundIndexMetadata, "!foundIndexMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11183)) { |
11184 | return IPC_FAIL(this, "GetMetadataForIndexId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("GetMetadataForIndexId failed!" )); |
11185 | } |
11186 | |
11187 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11187)) { |
11188 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
11189 | } |
11190 | |
11191 | foundIndexMetadata->mDeleted.Flip(); |
11192 | |
11193 | DebugOnly<bool> foundTargetId = false; |
11194 | const bool isLastIndex = |
11195 | std::all_of(foundObjectStoreMetadata->mIndexes.cbegin(), |
11196 | foundObjectStoreMetadata->mIndexes.cend(), |
11197 | [&foundTargetId, aIndexId](const auto& indexEntry) -> bool { |
11198 | if (uint64_t(aIndexId) == indexEntry.GetKey()) { |
11199 | foundTargetId = true; |
11200 | return true; |
11201 | } |
11202 | |
11203 | return indexEntry.GetData()->mDeleted; |
11204 | }); |
11205 | MOZ_ASSERT_IF(isLastIndex, foundTargetId)do { if (isLastIndex) { do { static_assert( mozilla::detail:: AssertionConditionType<decltype(foundTargetId)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(foundTargetId))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("foundTargetId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "foundTargetId" ")"); do { *((volatile int*)__null) = 11205; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
11206 | |
11207 | RefPtr<DeleteIndexOp> op = new DeleteIndexOp( |
11208 | SafeRefPtrFromThis().downcast<VersionChangeTransaction>(), aObjectStoreId, |
11209 | aIndexId, foundIndexMetadata->mCommonMetadata.unique(), isLastIndex); |
11210 | |
11211 | if (NS_WARN_IF(!op->Init(*this))NS_warn_if_impl(!op->Init(*this), "!op->Init(*this)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11211)) { |
11212 | op->Cleanup(); |
11213 | return IPC_FAIL(this, "ObjectStoreOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ObjectStoreOp initialization failed!" )); |
11214 | } |
11215 | |
11216 | op->DispatchToConnectionPool(); |
11217 | |
11218 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11219 | } |
11220 | |
11221 | mozilla::ipc::IPCResult VersionChangeTransaction::RecvRenameIndex( |
11222 | const IndexOrObjectStoreId& aObjectStoreId, |
11223 | const IndexOrObjectStoreId& aIndexId, const nsAString& aName) { |
11224 | AssertIsOnBackgroundThread(); |
11225 | |
11226 | if (NS_WARN_IF(!aObjectStoreId)NS_warn_if_impl(!aObjectStoreId, "!aObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11226)) { |
11227 | return IPC_FAIL(this, "No ObjectStoreId!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No ObjectStoreId!" )); |
11228 | } |
11229 | |
11230 | if (NS_WARN_IF(!aIndexId)NS_warn_if_impl(!aIndexId, "!aIndexId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11230)) { |
11231 | return IPC_FAIL(this, "No Index id!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("No Index id!" )); |
11232 | } |
11233 | |
11234 | const SafeRefPtr<FullDatabaseMetadata> dbMetadata = |
11235 | GetDatabase().MetadataPtr(); |
11236 | MOZ_ASSERT(dbMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11236); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata" ")"); do { *((volatile int*)__null) = 11236; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11237 | MOZ_ASSERT(dbMetadata->mNextObjectStoreId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata->mNextObjectStoreId > 0)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(dbMetadata->mNextObjectStoreId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbMetadata->mNextObjectStoreId > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11237); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata->mNextObjectStoreId > 0" ")"); do { *((volatile int*)__null) = 11237; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11238 | MOZ_ASSERT(dbMetadata->mNextIndexId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(dbMetadata->mNextIndexId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbMetadata->mNextIndexId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("dbMetadata->mNextIndexId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11238); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbMetadata->mNextIndexId > 0" ")"); do { *((volatile int*)__null) = 11238; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11239 | |
11240 | if (NS_WARN_IF(aObjectStoreId >= dbMetadata->mNextObjectStoreId)NS_warn_if_impl(aObjectStoreId >= dbMetadata->mNextObjectStoreId , "aObjectStoreId >= dbMetadata->mNextObjectStoreId", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11240)) { |
11241 | return IPC_FAIL(this, "Requested ObjectStoreId does not match next ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Requested ObjectStoreId does not match next ID!" )); |
11242 | } |
11243 | |
11244 | if (NS_WARN_IF(aIndexId >= dbMetadata->mNextIndexId)NS_warn_if_impl(aIndexId >= dbMetadata->mNextIndexId, "aIndexId >= dbMetadata->mNextIndexId" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11244)) { |
11245 | return IPC_FAIL(this, "Requested IndexId does not match next ID!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Requested IndexId does not match next ID!" )); |
11246 | } |
11247 | |
11248 | SafeRefPtr<FullObjectStoreMetadata> foundObjectStoreMetadata = |
11249 | GetMetadataForObjectStoreId(aObjectStoreId); |
11250 | |
11251 | if (NS_WARN_IF(!foundObjectStoreMetadata)NS_warn_if_impl(!foundObjectStoreMetadata, "!foundObjectStoreMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11251)) { |
11252 | return IPC_FAIL(this, "GetMetadataForObjectStoreId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("GetMetadataForObjectStoreId failed!" )); |
11253 | } |
11254 | |
11255 | SafeRefPtr<FullIndexMetadata> foundIndexMetadata = |
11256 | GetMetadataForIndexId(*foundObjectStoreMetadata, aIndexId); |
11257 | |
11258 | if (NS_WARN_IF(!foundIndexMetadata)NS_warn_if_impl(!foundIndexMetadata, "!foundIndexMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11258)) { |
11259 | return IPC_FAIL(this, "GetMetadataForIndexId failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("GetMetadataForIndexId failed!" )); |
11260 | } |
11261 | |
11262 | if (NS_WARN_IF(mCommitOrAbortReceived)NS_warn_if_impl(mCommitOrAbortReceived, "mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11262)) { |
11263 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
11264 | } |
11265 | |
11266 | foundIndexMetadata->mCommonMetadata.name() = aName; |
11267 | |
11268 | RefPtr<RenameIndexOp> renameOp = new RenameIndexOp( |
11269 | SafeRefPtrFromThis().downcast<VersionChangeTransaction>(), |
11270 | *foundIndexMetadata, aObjectStoreId); |
11271 | |
11272 | if (NS_WARN_IF(!renameOp->Init(*this))NS_warn_if_impl(!renameOp->Init(*this), "!renameOp->Init(*this)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11272)) { |
11273 | renameOp->Cleanup(); |
11274 | return IPC_FAIL(this, "ObjectStoreOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ObjectStoreOp initialization failed!" )); |
11275 | } |
11276 | |
11277 | renameOp->DispatchToConnectionPool(); |
11278 | |
11279 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11280 | } |
11281 | |
11282 | PBackgroundIDBRequestParent* |
11283 | VersionChangeTransaction::AllocPBackgroundIDBRequestParent( |
11284 | const int64_t& aRequestId, const RequestParams& aParams) { |
11285 | AssertIsOnBackgroundThread(); |
11286 | MOZ_ASSERT(aParams.type() != RequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != RequestParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != RequestParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != RequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11286); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != RequestParams::T__None" ")"); do { *((volatile int*)__null) = 11286; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11287 | |
11288 | return AllocRequest(aRequestId, |
11289 | std::move(const_cast<RequestParams&>(aParams)), |
11290 | IsSameProcessActor()); |
11291 | } |
11292 | |
11293 | mozilla::ipc::IPCResult |
11294 | VersionChangeTransaction::RecvPBackgroundIDBRequestConstructor( |
11295 | PBackgroundIDBRequestParent* aActor, const int64_t& aRequestId, |
11296 | const RequestParams& aParams) { |
11297 | AssertIsOnBackgroundThread(); |
11298 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11298); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 11298; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
11299 | MOZ_ASSERT(aParams.type() != RequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != RequestParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != RequestParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != RequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11299); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != RequestParams::T__None" ")"); do { *((volatile int*)__null) = 11299; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11300 | |
11301 | if (!StartRequest(aActor)) { |
11302 | return IPC_FAIL(this, "StartRequest failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("StartRequest failed!" )); |
11303 | } |
11304 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11305 | } |
11306 | |
11307 | bool VersionChangeTransaction::DeallocPBackgroundIDBRequestParent( |
11308 | PBackgroundIDBRequestParent* aActor) { |
11309 | AssertIsOnBackgroundThread(); |
11310 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11310); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 11310; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
11311 | |
11312 | return DeallocRequest(aActor); |
11313 | } |
11314 | |
11315 | already_AddRefed<PBackgroundIDBCursorParent> |
11316 | VersionChangeTransaction::AllocPBackgroundIDBCursorParent( |
11317 | const int64_t& aRequestId, const OpenCursorParams& aParams) { |
11318 | AssertIsOnBackgroundThread(); |
11319 | |
11320 | return AllocCursor(aParams, IsSameProcessActor()); |
11321 | } |
11322 | |
11323 | mozilla::ipc::IPCResult |
11324 | VersionChangeTransaction::RecvPBackgroundIDBCursorConstructor( |
11325 | PBackgroundIDBCursorParent* aActor, const int64_t& aRequestId, |
11326 | const OpenCursorParams& aParams) { |
11327 | AssertIsOnBackgroundThread(); |
11328 | MOZ_ASSERT(aActor)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aActor)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(aActor))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aActor", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11328); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aActor" ")" ); do { *((volatile int*)__null) = 11328; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
11329 | MOZ_ASSERT(aParams.type() != OpenCursorParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != OpenCursorParams::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aParams.type() != OpenCursorParams::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != OpenCursorParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11329); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != OpenCursorParams::T__None" ")"); do { *((volatile int*)__null) = 11329; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11330 | |
11331 | if (!StartCursor(aActor, aRequestId, aParams)) { |
11332 | return IPC_FAIL(this, "StartCursor failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("StartCursor failed!" )); |
11333 | } |
11334 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11335 | } |
11336 | |
11337 | /******************************************************************************* |
11338 | * CursorBase |
11339 | ******************************************************************************/ |
11340 | |
11341 | CursorBase::CursorBase(SafeRefPtr<TransactionBase> aTransaction, |
11342 | SafeRefPtr<FullObjectStoreMetadata> aObjectStoreMetadata, |
11343 | const Direction aDirection, |
11344 | const ConstructFromTransactionBase /*aConstructionTag*/) |
11345 | : mTransaction(std::move(aTransaction)), |
11346 | mObjectStoreMetadata(WrapNotNull(std::move(aObjectStoreMetadata))), |
11347 | mObjectStoreId((*mObjectStoreMetadata)->mCommonMetadata.id()), |
11348 | mDirection(aDirection), |
11349 | mMaxExtraCount(IndexedDatabaseManager::MaxPreloadExtraRecords()), |
11350 | mIsSameProcessActor(!BackgroundParent::IsOtherProcessActor( |
11351 | mTransaction->GetBackgroundParent())) { |
11352 | AssertIsOnBackgroundThread(); |
11353 | MOZ_ASSERT(mTransaction)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mTransaction)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mTransaction))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mTransaction", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11353); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mTransaction" ")"); do { *((volatile int*)__null) = 11353; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11354 | |
11355 | static_assert( |
11356 | OpenCursorParams::T__None == 0 && OpenCursorParams::T__Last == 4, |
11357 | "Lots of code here assumes only four types of cursors!"); |
11358 | } |
11359 | |
11360 | template <IDBCursorType CursorType> |
11361 | bool Cursor<CursorType>::VerifyRequestParams( |
11362 | const CursorRequestParams& aParams, |
11363 | const CursorPosition<CursorType>& aPosition) const { |
11364 | AssertIsOnBackgroundThread(); |
11365 | MOZ_ASSERT(aParams.type() != CursorRequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != CursorRequestParams::T__None)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aParams.type() != CursorRequestParams::T__None))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != CursorRequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11365); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != CursorRequestParams::T__None" ")"); do { *((volatile int*)__null) = 11365; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11366 | MOZ_ASSERT(this->mObjectStoreMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mObjectStoreMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mObjectStoreMetadata ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "this->mObjectStoreMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11366); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mObjectStoreMetadata" ")"); do { *((volatile int*)__null) = 11366; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11367 | if constexpr (IsIndexCursor) { |
11368 | MOZ_ASSERT(this->mIndexMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mIndexMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mIndexMetadata))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("this->mIndexMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11368); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mIndexMetadata" ")"); do { *((volatile int*)__null) = 11368; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11369 | } |
11370 | |
11371 | #ifdef DEBUG1 |
11372 | { |
11373 | const SafeRefPtr<FullObjectStoreMetadata> objectStoreMetadata = |
11374 | mTransaction->GetMetadataForObjectStoreId(mObjectStoreId); |
11375 | if (objectStoreMetadata) { |
11376 | MOZ_ASSERT(objectStoreMetadata == (*this->mObjectStoreMetadata))do { static_assert( mozilla::detail::AssertionConditionType< decltype(objectStoreMetadata == (*this->mObjectStoreMetadata ))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(objectStoreMetadata == (*this->mObjectStoreMetadata )))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("objectStoreMetadata == (*this->mObjectStoreMetadata)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11376); AnnotateMozCrashReason("MOZ_ASSERT" "(" "objectStoreMetadata == (*this->mObjectStoreMetadata)" ")"); do { *((volatile int*)__null) = 11376; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11377 | } else { |
11378 | MOZ_ASSERT((*this->mObjectStoreMetadata)->mDeleted)do { static_assert( mozilla::detail::AssertionConditionType< decltype((*this->mObjectStoreMetadata)->mDeleted)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!((*this->mObjectStoreMetadata)->mDeleted))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("(*this->mObjectStoreMetadata)->mDeleted" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11378); AnnotateMozCrashReason("MOZ_ASSERT" "(" "(*this->mObjectStoreMetadata)->mDeleted" ")"); do { *((volatile int*)__null) = 11378; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11379 | } |
11380 | |
11381 | if constexpr (IsIndexCursor) { |
11382 | if (objectStoreMetadata) { |
11383 | const SafeRefPtr<FullIndexMetadata> indexMetadata = |
11384 | mTransaction->GetMetadataForIndexId(*objectStoreMetadata, |
11385 | this->mIndexId); |
11386 | if (indexMetadata) { |
11387 | MOZ_ASSERT(indexMetadata == *this->mIndexMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(indexMetadata == *this->mIndexMetadata)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(indexMetadata == *this->mIndexMetadata))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("indexMetadata == *this->mIndexMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11387); AnnotateMozCrashReason("MOZ_ASSERT" "(" "indexMetadata == *this->mIndexMetadata" ")"); do { *((volatile int*)__null) = 11387; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11388 | } else { |
11389 | MOZ_ASSERT((*this->mIndexMetadata)->mDeleted)do { static_assert( mozilla::detail::AssertionConditionType< decltype((*this->mIndexMetadata)->mDeleted)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!((*this->mIndexMetadata)->mDeleted))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("(*this->mIndexMetadata)->mDeleted" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11389); AnnotateMozCrashReason("MOZ_ASSERT" "(" "(*this->mIndexMetadata)->mDeleted" ")"); do { *((volatile int*)__null) = 11389; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11390 | } |
11391 | } |
11392 | } |
11393 | } |
11394 | #endif |
11395 | |
11396 | if (NS_AUUF_OR_WARN_IF((*this->mObjectStoreMetadata)->mDeleted)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "(*this->mObjectStoreMetadata)->mDeleted" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11396); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "(*this->mObjectStoreMetadata)->mDeleted" ")"); do { * ((volatile int*)__null) = 11396; __attribute__((nomerge)) ::abort (); } while (false); } } while (false); } return aCond; }(((* this->mObjectStoreMetadata)->mDeleted))) { |
11397 | return false; |
11398 | } |
11399 | |
11400 | if constexpr (IsIndexCursor) { |
11401 | if (NS_AUUF_OR_WARN_IF(this->mIndexMetadata &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "this->mIndexMetadata && (*this->mIndexMetadata)->mDeleted" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11402); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "this->mIndexMetadata && (*this->mIndexMetadata)->mDeleted" ")"); do { *((volatile int*)__null) = 11402; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((this->mIndexMetadata && (*this->mIndexMetadata )->mDeleted)) |
11402 | (*this->mIndexMetadata)->mDeleted)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "this->mIndexMetadata && (*this->mIndexMetadata)->mDeleted" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11402); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "this->mIndexMetadata && (*this->mIndexMetadata)->mDeleted" ")"); do { *((volatile int*)__null) = 11402; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((this->mIndexMetadata && (*this->mIndexMetadata )->mDeleted))) { |
11403 | return false; |
11404 | } |
11405 | } |
11406 | |
11407 | const Key& sortKey = aPosition.GetSortKey(this->IsLocaleAware()); |
11408 | |
11409 | switch (aParams.type()) { |
11410 | case CursorRequestParams::TContinueParams: { |
11411 | const Key& key = aParams.get_ContinueParams().key(); |
11412 | if (!key.IsUnset()) { |
11413 | switch (mDirection) { |
11414 | case IDBCursorDirection::Next: |
11415 | case IDBCursorDirection::Nextunique: |
11416 | if (NS_AUUF_OR_WARN_IF(key <= sortKey)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key <= sortKey" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11416); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key <= sortKey" ")"); do { *((volatile int*)__null) = 11416 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key <= sortKey))) { |
11417 | return false; |
11418 | } |
11419 | break; |
11420 | |
11421 | case IDBCursorDirection::Prev: |
11422 | case IDBCursorDirection::Prevunique: |
11423 | if (NS_AUUF_OR_WARN_IF(key >= sortKey)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key >= sortKey" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11423); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key >= sortKey" ")"); do { *((volatile int*)__null) = 11423 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key >= sortKey))) { |
11424 | return false; |
11425 | } |
11426 | break; |
11427 | |
11428 | default: |
11429 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11429); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 11429; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
11430 | } |
11431 | } |
11432 | break; |
11433 | } |
11434 | |
11435 | case CursorRequestParams::TContinuePrimaryKeyParams: { |
11436 | if constexpr (IsIndexCursor) { |
11437 | const Key& key = aParams.get_ContinuePrimaryKeyParams().key(); |
11438 | const Key& primaryKey = |
11439 | aParams.get_ContinuePrimaryKeyParams().primaryKey(); |
11440 | MOZ_ASSERT(!key.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!key.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!key.IsUnset()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!key.IsUnset()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11440); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!key.IsUnset()" ")"); do { *((volatile int*)__null) = 11440; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11441 | MOZ_ASSERT(!primaryKey.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!primaryKey.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!primaryKey.IsUnset()))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("!primaryKey.IsUnset()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11441); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!primaryKey.IsUnset()" ")"); do { *((volatile int*)__null) = 11441; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11442 | switch (mDirection) { |
11443 | case IDBCursorDirection::Next: |
11444 | if (NS_AUUF_OR_WARN_IF(key < sortKey ||[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11446); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)" ")"); do { *((volatile int*)__null) = 11446; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey))) |
11445 | (key == sortKey &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11446); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)" ")"); do { *((volatile int*)__null) = 11446; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey))) |
11446 | primaryKey <= aPosition.mObjectStoreKey))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11446); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)" ")"); do { *((volatile int*)__null) = 11446; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key < sortKey || (key == sortKey && primaryKey <= aPosition.mObjectStoreKey)))) { |
11447 | return false; |
11448 | } |
11449 | break; |
11450 | |
11451 | case IDBCursorDirection::Prev: |
11452 | if (NS_AUUF_OR_WARN_IF(key > sortKey ||[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11454); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)" ")"); do { *((volatile int*)__null) = 11454; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey))) |
11453 | (key == sortKey &&[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11454); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)" ")"); do { *((volatile int*)__null) = 11454; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey))) |
11454 | primaryKey >= aPosition.mObjectStoreKey))[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11454); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)" ")"); do { *((volatile int*)__null) = 11454; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((key > sortKey || (key == sortKey && primaryKey >= aPosition.mObjectStoreKey)))) { |
11455 | return false; |
11456 | } |
11457 | break; |
11458 | |
11459 | default: |
11460 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11460); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 11460; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
11461 | } |
11462 | } |
11463 | break; |
11464 | } |
11465 | |
11466 | case CursorRequestParams::TAdvanceParams: |
11467 | if (NS_AUUF_OR_WARN_IF(!aParams.get_AdvanceParams().count())[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "!aParams.get_AdvanceParams().count()" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11467); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "!aParams.get_AdvanceParams().count()" ")"); do { *((volatile int*)__null) = 11467; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((!aParams.get_AdvanceParams ().count()))) { |
11468 | return false; |
11469 | } |
11470 | break; |
11471 | |
11472 | default: |
11473 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11473); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 11473; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
11474 | } |
11475 | |
11476 | return true; |
11477 | } |
11478 | |
11479 | template <IDBCursorType CursorType> |
11480 | bool Cursor<CursorType>::Start(const int64_t aRequestId, |
11481 | const OpenCursorParams& aParams) { |
11482 | AssertIsOnBackgroundThread(); |
11483 | MOZ_ASSERT(aParams.type() == ToOpenCursorParamsType(CursorType))do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() == ToOpenCursorParamsType(CursorType) )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aParams.type() == ToOpenCursorParamsType(CursorType) ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aParams.type() == ToOpenCursorParamsType(CursorType)", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11483); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() == ToOpenCursorParamsType(CursorType)" ")"); do { *((volatile int*)__null) = 11483; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11484 | MOZ_ASSERT(this->mObjectStoreMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mObjectStoreMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mObjectStoreMetadata ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "this->mObjectStoreMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11484); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mObjectStoreMetadata" ")"); do { *((volatile int*)__null) = 11484; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11485 | |
11486 | if (NS_AUUF_OR_WARN_IF(mCurrentlyRunningOp)[](bool aCond) { if ((__builtin_expect(!!(aCond), 0))) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (false)>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(false))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("false" " (" "mCurrentlyRunningOp" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11486); AnnotateMozCrashReason("MOZ_ASSERT" "(" "false" ") (" "mCurrentlyRunningOp" ")"); do { *((volatile int*)__null) = 11486 ; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); } return aCond; }((mCurrentlyRunningOp))) { |
11487 | return false; |
11488 | } |
11489 | |
11490 | const Maybe<SerializedKeyRange>& optionalKeyRange = |
11491 | GetCommonOpenCursorParams(aParams).optionalKeyRange(); |
11492 | |
11493 | const RefPtr<OpenOp> openOp = new OpenOp(this, aRequestId, optionalKeyRange); |
11494 | |
11495 | if (NS_WARN_IF(!openOp->Init(*mTransaction))NS_warn_if_impl(!openOp->Init(*mTransaction), "!openOp->Init(*mTransaction)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11495)) { |
11496 | openOp->Cleanup(); |
11497 | return false; |
11498 | } |
11499 | |
11500 | openOp->DispatchToConnectionPool(); |
11501 | mCurrentlyRunningOp = openOp; |
11502 | |
11503 | return true; |
11504 | } |
11505 | |
11506 | void ValueCursorBase::ProcessFiles(CursorResponse& aResponse, |
11507 | const FilesArray& aFiles) { |
11508 | MOZ_ASSERT_IF(do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11509 | aResponse.type() == CursorResponse::Tnsresult ||do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11510 | aResponse.type() == CursorResponse::Tvoid_t ||do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11511 | aResponse.type() ==do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11512 | CursorResponse::TArrayOfObjectStoreKeyCursorResponse ||do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11513 | aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse,do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11514 | aFiles.IsEmpty())do { if (aResponse.type() == CursorResponse::Tnsresult || aResponse .type() == CursorResponse::Tvoid_t || aResponse.type() == CursorResponse ::TArrayOfObjectStoreKeyCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexKeyCursorResponse) { do { static_assert ( mozilla::detail::AssertionConditionType<decltype(aFiles. IsEmpty())>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(aFiles.IsEmpty()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aFiles.IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11514); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aFiles.IsEmpty()" ")"); do { *((volatile int*)__null) = 11514; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
11515 | |
11516 | for (size_t i = 0; i < aFiles.Length(); ++i) { |
11517 | const auto& files = aFiles[i]; |
11518 | if (!files.IsEmpty()) { |
11519 | // TODO: Replace this assertion by one that checks if the response type |
11520 | // matches the cursor type, at a more generic location. |
11521 | MOZ_ASSERT(aResponse.type() ==do { static_assert( mozilla::detail::AssertionConditionType< decltype(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11524); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" ")"); do { *((volatile int*)__null) = 11524; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false) |
11522 | CursorResponse::TArrayOfObjectStoreCursorResponse ||do { static_assert( mozilla::detail::AssertionConditionType< decltype(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11524); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" ")"); do { *((volatile int*)__null) = 11524; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false) |
11523 | aResponse.type() ==do { static_assert( mozilla::detail::AssertionConditionType< decltype(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11524); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" ")"); do { *((volatile int*)__null) = 11524; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false) |
11524 | CursorResponse::TArrayOfIndexCursorResponse)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse )>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11524); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aResponse.type() == CursorResponse::TArrayOfObjectStoreCursorResponse || aResponse.type() == CursorResponse::TArrayOfIndexCursorResponse" ")"); do { *((volatile int*)__null) = 11524; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11525 | |
11526 | SerializedStructuredCloneReadInfo* serializedInfo = nullptr; |
11527 | switch (aResponse.type()) { |
11528 | case CursorResponse::TArrayOfObjectStoreCursorResponse: { |
11529 | auto& responses = aResponse.get_ArrayOfObjectStoreCursorResponse(); |
11530 | MOZ_ASSERT(i < responses.Length())do { static_assert( mozilla::detail::AssertionConditionType< decltype(i < responses.Length())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(i < responses.Length()))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("i < responses.Length()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11530); AnnotateMozCrashReason("MOZ_ASSERT" "(" "i < responses.Length()" ")"); do { *((volatile int*)__null) = 11530; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11531 | serializedInfo = &responses[i].cloneInfo(); |
11532 | break; |
11533 | } |
11534 | |
11535 | case CursorResponse::TArrayOfIndexCursorResponse: { |
11536 | auto& responses = aResponse.get_ArrayOfIndexCursorResponse(); |
11537 | MOZ_ASSERT(i < responses.Length())do { static_assert( mozilla::detail::AssertionConditionType< decltype(i < responses.Length())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(i < responses.Length()))) , 0))) { do { } while (false); MOZ_ReportAssertionFailure("i < responses.Length()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11537); AnnotateMozCrashReason("MOZ_ASSERT" "(" "i < responses.Length()" ")"); do { *((volatile int*)__null) = 11537; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11538 | serializedInfo = &responses[i].cloneInfo(); |
11539 | break; |
11540 | } |
11541 | |
11542 | default: |
11543 | MOZ_CRASH("Should never get here!")do { do { } while (false); MOZ_ReportCrash("" "Should never get here!" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11543); AnnotateMozCrashReason("MOZ_CRASH(" "Should never get here!" ")"); do { *((volatile int*)__null) = 11543; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); |
11544 | } |
11545 | |
11546 | MOZ_ASSERT(serializedInfo)do { static_assert( mozilla::detail::AssertionConditionType< decltype(serializedInfo)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(serializedInfo))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("serializedInfo" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11546); AnnotateMozCrashReason("MOZ_ASSERT" "(" "serializedInfo" ")"); do { *((volatile int*)__null) = 11546; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11547 | MOZ_ASSERT(serializedInfo->files().IsEmpty())do { static_assert( mozilla::detail::AssertionConditionType< decltype(serializedInfo->files().IsEmpty())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(serializedInfo->files().IsEmpty ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("serializedInfo->files().IsEmpty()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11547); AnnotateMozCrashReason("MOZ_ASSERT" "(" "serializedInfo->files().IsEmpty()" ")"); do { *((volatile int*)__null) = 11547; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11548 | MOZ_ASSERT(this->mDatabase)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mDatabase)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mDatabase))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("this->mDatabase" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11548); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mDatabase" ")"); do { *((volatile int*)__null) = 11548; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11549 | |
11550 | QM_TRY_UNWRAP(serializedInfo->files(),auto tryResult981 = (SerializeStructuredCloneFiles(this->mDatabase , files, false)); if ((__builtin_expect(!!(tryResult981.isErr ()), 0))) { auto tryTempError = tryResult981.unwrapErr(); mozilla ::dom::quota::HandleError("SerializeStructuredCloneFiles(this->mDatabase, files, false)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11555, mozilla::dom::quota::Severity::Error); [&aResponse ](const nsresult result) { aResponse = ClampResultCode(result ); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return ; } serializedInfo->files () = tryResult981.unwrap(); |
11551 | SerializeStructuredCloneFiles(this->mDatabase, files,auto tryResult981 = (SerializeStructuredCloneFiles(this->mDatabase , files, false)); if ((__builtin_expect(!!(tryResult981.isErr ()), 0))) { auto tryTempError = tryResult981.unwrapErr(); mozilla ::dom::quota::HandleError("SerializeStructuredCloneFiles(this->mDatabase, files, false)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11555, mozilla::dom::quota::Severity::Error); [&aResponse ](const nsresult result) { aResponse = ClampResultCode(result ); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return ; } serializedInfo->files () = tryResult981.unwrap(); |
11552 | /* aForPreprocess */ false),auto tryResult981 = (SerializeStructuredCloneFiles(this->mDatabase , files, false)); if ((__builtin_expect(!!(tryResult981.isErr ()), 0))) { auto tryTempError = tryResult981.unwrapErr(); mozilla ::dom::quota::HandleError("SerializeStructuredCloneFiles(this->mDatabase, files, false)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11555, mozilla::dom::quota::Severity::Error); [&aResponse ](const nsresult result) { aResponse = ClampResultCode(result ); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return ; } serializedInfo->files () = tryResult981.unwrap(); |
11553 | QM_VOID, [&aResponse](const nsresult result) {auto tryResult981 = (SerializeStructuredCloneFiles(this->mDatabase , files, false)); if ((__builtin_expect(!!(tryResult981.isErr ()), 0))) { auto tryTempError = tryResult981.unwrapErr(); mozilla ::dom::quota::HandleError("SerializeStructuredCloneFiles(this->mDatabase, files, false)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11555, mozilla::dom::quota::Severity::Error); [&aResponse ](const nsresult result) { aResponse = ClampResultCode(result ); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return ; } serializedInfo->files () = tryResult981.unwrap(); |
11554 | aResponse = ClampResultCode(result);auto tryResult981 = (SerializeStructuredCloneFiles(this->mDatabase , files, false)); if ((__builtin_expect(!!(tryResult981.isErr ()), 0))) { auto tryTempError = tryResult981.unwrapErr(); mozilla ::dom::quota::HandleError("SerializeStructuredCloneFiles(this->mDatabase, files, false)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11555, mozilla::dom::quota::Severity::Error); [&aResponse ](const nsresult result) { aResponse = ClampResultCode(result ); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return ; } serializedInfo->files () = tryResult981.unwrap(); |
11555 | })auto tryResult981 = (SerializeStructuredCloneFiles(this->mDatabase , files, false)); if ((__builtin_expect(!!(tryResult981.isErr ()), 0))) { auto tryTempError = tryResult981.unwrapErr(); mozilla ::dom::quota::HandleError("SerializeStructuredCloneFiles(this->mDatabase, files, false)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11555, mozilla::dom::quota::Severity::Error); [&aResponse ](const nsresult result) { aResponse = ClampResultCode(result ); }(tryTempError); constexpr const auto& func __attribute__ ((__unused__)) = __func__; return ; } serializedInfo->files () = tryResult981.unwrap();; |
11556 | } |
11557 | } |
11558 | } |
11559 | |
11560 | template <IDBCursorType CursorType> |
11561 | void Cursor<CursorType>::SendResponseInternal( |
11562 | CursorResponse& aResponse, const FilesArrayT<CursorType>& aFiles) { |
11563 | AssertIsOnBackgroundThread(); |
11564 | MOZ_ASSERT(aResponse.type() != CursorResponse::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aResponse.type() != CursorResponse::T__None)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(aResponse.type() != CursorResponse::T__None))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aResponse.type() != CursorResponse::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11564); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aResponse.type() != CursorResponse::T__None" ")"); do { *((volatile int*)__null) = 11564; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11565 | MOZ_ASSERT_IF(aResponse.type() == CursorResponse::Tnsresult,do { if (aResponse.type() == CursorResponse::Tnsresult) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (((bool)(__builtin_expect(!!(NS_FAILED_impl(aResponse.get_nsresult ())), 0))))>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(NS_FAILED_impl (aResponse.get_nsresult())), 0)))))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(NS_FAILED_impl(aResponse.get_nsresult())), 0)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11566); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(NS_FAILED_impl(aResponse.get_nsresult())), 0)))" ")"); do { *((volatile int*)__null) = 11566; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11566 | NS_FAILED(aResponse.get_nsresult()))do { if (aResponse.type() == CursorResponse::Tnsresult) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (((bool)(__builtin_expect(!!(NS_FAILED_impl(aResponse.get_nsresult ())), 0))))>::isValid, "invalid assertion condition"); if ( (__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(NS_FAILED_impl (aResponse.get_nsresult())), 0)))))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(NS_FAILED_impl(aResponse.get_nsresult())), 0)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11566); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(NS_FAILED_impl(aResponse.get_nsresult())), 0)))" ")"); do { *((volatile int*)__null) = 11566; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
11567 | MOZ_ASSERT_IF(aResponse.type() == CursorResponse::Tnsresult,do { if (aResponse.type() == CursorResponse::Tnsresult) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11569); AnnotateMozCrashReason("MOZ_ASSERT" "(" "NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33" ")"); do { *((volatile int*)__null) = 11569; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11568 | NS_ERROR_GET_MODULE(aResponse.get_nsresult()) ==do { if (aResponse.type() == CursorResponse::Tnsresult) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11569); AnnotateMozCrashReason("MOZ_ASSERT" "(" "NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33" ")"); do { *((volatile int*)__null) = 11569; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false) |
11569 | NS_ERROR_MODULE_DOM_INDEXEDDB)do { if (aResponse.type() == CursorResponse::Tnsresult) { do { static_assert( mozilla::detail::AssertionConditionType<decltype (NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33))), 0) )) { do { } while (false); MOZ_ReportAssertionFailure("NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11569); AnnotateMozCrashReason("MOZ_ASSERT" "(" "NS_ERROR_GET_MODULE(aResponse.get_nsresult()) == 33" ")"); do { *((volatile int*)__null) = 11569; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
11570 | MOZ_ASSERT(this->mObjectStoreMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mObjectStoreMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mObjectStoreMetadata ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "this->mObjectStoreMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11570); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mObjectStoreMetadata" ")"); do { *((volatile int*)__null) = 11570; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11571 | MOZ_ASSERT(mCurrentlyRunningOp)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mCurrentlyRunningOp)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mCurrentlyRunningOp))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mCurrentlyRunningOp" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11571); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mCurrentlyRunningOp" ")"); do { *((volatile int*)__null) = 11571; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11572 | |
11573 | KeyValueBase::ProcessFiles(aResponse, aFiles); |
11574 | |
11575 | // Work around the deleted function by casting to the base class. |
11576 | QM_WARNONLY_TRY(OkIf({auto tryResult982 = (OkIf( static_cast<PBackgroundIDBCursorParent *>(this)->SendResponse(aResponse))); static_assert(std:: is_empty_v<typename decltype(tryResult982)::ok_type>); if ((__builtin_expect(!!(tryResult982.isErr()), 0))) { mozilla:: dom::quota::HandleError("OkIf( static_cast<PBackgroundIDBCursorParent*>(this)->SendResponse(aResponse))" , tryResult982.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11577, mozilla::dom::quota::Severity::Warning); }} |
11577 | static_cast<PBackgroundIDBCursorParent*>(this)->SendResponse(aResponse))){auto tryResult982 = (OkIf( static_cast<PBackgroundIDBCursorParent *>(this)->SendResponse(aResponse))); static_assert(std:: is_empty_v<typename decltype(tryResult982)::ok_type>); if ((__builtin_expect(!!(tryResult982.isErr()), 0))) { mozilla:: dom::quota::HandleError("OkIf( static_cast<PBackgroundIDBCursorParent*>(this)->SendResponse(aResponse))" , tryResult982.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11577, mozilla::dom::quota::Severity::Warning); }}; |
11578 | |
11579 | mCurrentlyRunningOp = nullptr; |
11580 | } |
11581 | |
11582 | template <IDBCursorType CursorType> |
11583 | void Cursor<CursorType>::ActorDestroy(ActorDestroyReason aWhy) { |
11584 | AssertIsOnBackgroundThread(); |
11585 | |
11586 | if (mCurrentlyRunningOp) { |
11587 | mCurrentlyRunningOp->NoteActorDestroyed(); |
11588 | } |
11589 | |
11590 | if constexpr (IsValueCursor) { |
11591 | this->mBackgroundParent.destroy(); |
11592 | } |
11593 | this->mObjectStoreMetadata.destroy(); |
11594 | if constexpr (IsIndexCursor) { |
11595 | this->mIndexMetadata.destroy(); |
11596 | } |
11597 | } |
11598 | |
11599 | template <IDBCursorType CursorType> |
11600 | mozilla::ipc::IPCResult Cursor<CursorType>::RecvDeleteMe() { |
11601 | AssertIsOnBackgroundThread(); |
11602 | MOZ_ASSERT(this->mObjectStoreMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mObjectStoreMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mObjectStoreMetadata ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "this->mObjectStoreMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11602); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mObjectStoreMetadata" ")"); do { *((volatile int*)__null) = 11602; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11603 | |
11604 | if (NS_WARN_IF(mCurrentlyRunningOp)NS_warn_if_impl(mCurrentlyRunningOp, "mCurrentlyRunningOp", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11604)) { |
11605 | return IPC_FAIL(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Attempt to delete a cursor with a non-null mCurrentlyRunningOp!" )) |
11606 | this,mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Attempt to delete a cursor with a non-null mCurrentlyRunningOp!" )) |
11607 | "Attempt to delete a cursor with a non-null mCurrentlyRunningOp!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Attempt to delete a cursor with a non-null mCurrentlyRunningOp!" )); |
11608 | } |
11609 | |
11610 | QM_WARNONLY_TRY(OkIf(PBackgroundIDBCursorParent::Send__delete__(this))){auto tryResult983 = (OkIf(PBackgroundIDBCursorParent::Send__delete__ (this))); static_assert(std::is_empty_v<typename decltype( tryResult983)::ok_type>); if ((__builtin_expect(!!(tryResult983 .isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(PBackgroundIDBCursorParent::Send__delete__(this))" , tryResult983.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11610, mozilla::dom::quota::Severity::Warning); }}; |
11611 | |
11612 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11613 | } |
11614 | |
11615 | template <IDBCursorType CursorType> |
11616 | mozilla::ipc::IPCResult Cursor<CursorType>::RecvContinue( |
11617 | const int64_t& aRequestId, const CursorRequestParams& aParams, |
11618 | const Key& aCurrentKey, const Key& aCurrentObjectStoreKey) { |
11619 | AssertIsOnBackgroundThread(); |
11620 | MOZ_ASSERT(aParams.type() != CursorRequestParams::T__None)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aParams.type() != CursorRequestParams::T__None)>:: isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(aParams.type() != CursorRequestParams::T__None))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("aParams.type() != CursorRequestParams::T__None" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11620); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aParams.type() != CursorRequestParams::T__None" ")"); do { *((volatile int*)__null) = 11620; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11621 | MOZ_ASSERT(this->mObjectStoreMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mObjectStoreMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mObjectStoreMetadata ))), 0))) { do { } while (false); MOZ_ReportAssertionFailure( "this->mObjectStoreMetadata", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11621); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mObjectStoreMetadata" ")"); do { *((volatile int*)__null) = 11621; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11622 | if constexpr (IsIndexCursor) { |
11623 | MOZ_ASSERT(this->mIndexMetadata)do { static_assert( mozilla::detail::AssertionConditionType< decltype(this->mIndexMetadata)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(this->mIndexMetadata))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("this->mIndexMetadata" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11623); AnnotateMozCrashReason("MOZ_ASSERT" "(" "this->mIndexMetadata" ")"); do { *((volatile int*)__null) = 11623; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11624 | } |
11625 | |
11626 | const bool trustParams = |
11627 | #ifdef DEBUG1 |
11628 | // Always verify parameters in DEBUG builds! |
11629 | false |
11630 | #else |
11631 | this->mIsSameProcessActor |
11632 | #endif |
11633 | ; |
11634 | |
11635 | MOZ_ASSERT(!aCurrentKey.IsUnset())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!aCurrentKey.IsUnset())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!aCurrentKey.IsUnset()))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!aCurrentKey.IsUnset()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11635); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!aCurrentKey.IsUnset()" ")"); do { *((volatile int*)__null) = 11635; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11636 | |
11637 | QM_TRY_UNWRAP(auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11638 | auto position,auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11639 | ([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> {auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11640 | if constexpr (IsIndexCursor) {auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11641 | auto localeAwarePosition = Key{};auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11642 | if (this->IsLocaleAware()) {auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11643 | QM_TRY_UNWRAP(auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11644 | localeAwarePosition,auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11645 | aCurrentKey.ToLocaleAwareKey(this->mLocale),auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11646 | Err(IPC_FAIL(this, "aCurrentKey.ToLocaleAwareKey failed!")));auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11647 | }auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11648 | return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition,auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11649 | aCurrentObjectStoreKey};auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11650 | } else {auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11651 | return CursorPosition<CursorType>{aCurrentKey};auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11652 | }auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap(); |
11653 | }()))auto tryResult985 = (([&]() -> Result<CursorPosition <CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this ->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey (this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984 .unwrapErr(); mozilla::dom::quota::HandleError("aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "aCurrentKey.ToLocaleAwareKey(this->mLocale)" , tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull (this), __func__, ("aCurrentKey.ToLocaleAwareKey failed!")))) ; } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition <CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey }; } else { return CursorPosition<CursorType>{aCurrentKey }; } }())); if ((__builtin_expect(!!(tryResult985.isErr()), 0 ))) { mozilla::dom::quota::HandleError("([&]() -> Result<CursorPosition<CursorType>, mozilla::ipc::IPCResult> { if constexpr (IsIndexCursor) { auto localeAwarePosition = Key{}; if (this->IsLocaleAware()) { auto tryResult984 = (aCurrentKey.ToLocaleAwareKey(this->mLocale)); if ((__builtin_expect(!!(tryResult984.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult984.unwrapErr(); mozilla::dom::quota::HandleError(\"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11646, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"aCurrentKey.ToLocaleAwareKey(this->mLocale)\", tryTempError, Err(mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, (\"aCurrentKey.ToLocaleAwareKey failed!\")))); } localeAwarePosition = tryResult984.unwrap();; } return CursorPosition<CursorType>{aCurrentKey, localeAwarePosition, aCurrentObjectStoreKey}; } else { return CursorPosition<CursorType>{aCurrentKey}; } }())" , tryResult985.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11653, mozilla::dom::quota::Severity::Error); return tryResult985 .propagateErr(); } auto position = tryResult985.unwrap();; |
11654 | |
11655 | if (!trustParams && !VerifyRequestParams(aParams, position)) { |
11656 | return IPC_FAIL(this, "VerifyRequestParams failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("VerifyRequestParams failed!" )); |
11657 | } |
11658 | |
11659 | if (NS_WARN_IF(mCurrentlyRunningOp)NS_warn_if_impl(mCurrentlyRunningOp, "mCurrentlyRunningOp", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11659)) { |
11660 | return IPC_FAIL(this, "Cursor is CurrentlyRunningOp!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Cursor is CurrentlyRunningOp!" )); |
11661 | } |
11662 | |
11663 | if (NS_WARN_IF(mTransaction->mCommitOrAbortReceived)NS_warn_if_impl(mTransaction->mCommitOrAbortReceived, "mTransaction->mCommitOrAbortReceived" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11663)) { |
11664 | return IPC_FAIL(this, "Transaction is already committed/aborted!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("Transaction is already committed/aborted!" )); |
11665 | } |
11666 | |
11667 | const RefPtr<ContinueOp> continueOp = |
11668 | new ContinueOp(this, aRequestId, aParams, std::move(position)); |
11669 | if (NS_WARN_IF(!continueOp->Init(*mTransaction))NS_warn_if_impl(!continueOp->Init(*mTransaction), "!continueOp->Init(*mTransaction)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11669)) { |
11670 | continueOp->Cleanup(); |
11671 | return IPC_FAIL(this, "ContinueOp initialization failed!")mozilla::ipc::IPCResult::Fail(WrapNotNull(this), __func__, ("ContinueOp initialization failed!" )); |
11672 | } |
11673 | |
11674 | continueOp->DispatchToConnectionPool(); |
11675 | mCurrentlyRunningOp = continueOp; |
11676 | |
11677 | return IPC_OK()mozilla::ipc::IPCResult::Ok(); |
11678 | } |
11679 | |
11680 | /******************************************************************************* |
11681 | * DatabaseFileManager |
11682 | ******************************************************************************/ |
11683 | |
11684 | DatabaseFileManager::MutexType DatabaseFileManager::sMutex; |
11685 | |
11686 | DatabaseFileManager::DatabaseFileManager( |
11687 | PersistenceType aPersistenceType, |
11688 | const quota::OriginMetadata& aOriginMetadata, |
11689 | const nsAString& aDatabaseName, const nsCString& aDatabaseID, |
11690 | const nsAString& aDatabaseFilePath, bool aEnforcingQuota, |
11691 | bool aIsInPrivateBrowsingMode) |
11692 | : mPersistenceType(aPersistenceType), |
11693 | mOriginMetadata(aOriginMetadata), |
11694 | mDatabaseName(aDatabaseName), |
11695 | mDatabaseID(aDatabaseID), |
11696 | mDatabaseFilePath(aDatabaseFilePath), |
11697 | mCipherKeyManager( |
11698 | aIsInPrivateBrowsingMode |
11699 | ? new IndexedDBCipherKeyManager("IndexedDBCipherKeyManager") |
11700 | : nullptr), |
11701 | mDatabaseVersion(0), |
11702 | mEnforcingQuota(aEnforcingQuota), |
11703 | mIsInPrivateBrowsingMode(aIsInPrivateBrowsingMode) {} |
11704 | |
11705 | uint64_t DatabaseFileManager::DatabaseVersion() const { |
11706 | AssertIsOnIOThread(); |
11707 | |
11708 | return mDatabaseVersion; |
11709 | } |
11710 | |
11711 | void DatabaseFileManager::UpdateDatabaseVersion(uint64_t aDatabaseVersion) { |
11712 | AssertIsOnIOThread(); |
11713 | |
11714 | mDatabaseVersion = aDatabaseVersion; |
11715 | } |
11716 | |
11717 | nsresult DatabaseFileManager::Init(nsIFile* aDirectory, |
11718 | const uint64_t aDatabaseVersion, |
11719 | mozIStorageConnection& aConnection) { |
11720 | AssertIsOnIOThread(); |
11721 | MOZ_ASSERT(aDirectory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11721); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectory" ")"); do { *((volatile int*)__null) = 11721; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11722 | |
11723 | { |
11724 | QM_TRY_INSPECT(const bool& existsAsDirectory,auto tryResult986 = (ExistsAsDirectory(*aDirectory)); if ((__builtin_expect (!!(tryResult986.isErr()), 0))) { mozilla::dom::quota::HandleError ("ExistsAsDirectory(*aDirectory)", tryResult986.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11725, mozilla::dom::quota::Severity::Error); return tryResult986 .propagateErr(); } const bool& existsAsDirectory = tryResult986 .inspect(); |
11725 | ExistsAsDirectory(*aDirectory))auto tryResult986 = (ExistsAsDirectory(*aDirectory)); if ((__builtin_expect (!!(tryResult986.isErr()), 0))) { mozilla::dom::quota::HandleError ("ExistsAsDirectory(*aDirectory)", tryResult986.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11725, mozilla::dom::quota::Severity::Error); return tryResult986 .propagateErr(); } const bool& existsAsDirectory = tryResult986 .inspect();; |
11726 | |
11727 | if (!existsAsDirectory) { |
11728 | QM_TRY(MOZ_TO_RESULT(aDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))){auto tryResult987 = (ToResult(aDirectory->Create(nsIFile:: DIRECTORY_TYPE, 0755))); static_assert(std::is_empty_v<typename decltype(tryResult987)::ok_type>); if ((__builtin_expect( !!(tryResult987.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(aDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryResult987.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11728, mozilla::dom::quota::Severity::Error); return tryResult987 .propagateErr(); }}; |
11729 | } |
11730 | |
11731 | QM_TRY_UNWRAP(auto path, MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult988 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (aDirectory)>::GetPath), (aDirectory))); if ((__builtin_expect (!!(tryResult988.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aDirectory)>::GetPath), (aDirectory))" , tryResult988.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11732, mozilla::dom::quota::Severity::Error); return tryResult988 .propagateErr(); } auto path = tryResult988.unwrap(); |
11732 | nsString, aDirectory, GetPath))auto tryResult988 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (aDirectory)>::GetPath), (aDirectory))); if ((__builtin_expect (!!(tryResult988.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aDirectory)>::GetPath), (aDirectory))" , tryResult988.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11732, mozilla::dom::quota::Severity::Error); return tryResult988 .propagateErr(); } auto path = tryResult988.unwrap();; |
11733 | |
11734 | mDirectoryPath.init(std::move(path)); |
11735 | } |
11736 | |
11737 | QM_TRY_INSPECT(const auto& journalDirectory,auto tryResult989 = (CloneFileAndAppend(*aDirectory, kJournalDirectoryName )); if ((__builtin_expect(!!(tryResult989.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, kJournalDirectoryName)" , tryResult989.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11738, mozilla::dom::quota::Severity::Error); return tryResult989 .propagateErr(); } const auto& journalDirectory = tryResult989 .inspect(); |
11738 | CloneFileAndAppend(*aDirectory, kJournalDirectoryName))auto tryResult989 = (CloneFileAndAppend(*aDirectory, kJournalDirectoryName )); if ((__builtin_expect(!!(tryResult989.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, kJournalDirectoryName)" , tryResult989.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11738, mozilla::dom::quota::Severity::Error); return tryResult989 .propagateErr(); } const auto& journalDirectory = tryResult989 .inspect();; |
11739 | |
11740 | // We don't care if it doesn't exist at all, but if it does exist, make sure |
11741 | // it's a directory. |
11742 | QM_TRY_INSPECT(const bool& existsAsDirectory,auto tryResult990 = (ExistsAsDirectory(*journalDirectory)); if ((__builtin_expect(!!(tryResult990.isErr()), 0))) { mozilla:: dom::quota::HandleError("ExistsAsDirectory(*journalDirectory)" , tryResult990.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11743, mozilla::dom::quota::Severity::Error); return tryResult990 .propagateErr(); } const bool& existsAsDirectory = tryResult990 .inspect(); |
11743 | ExistsAsDirectory(*journalDirectory))auto tryResult990 = (ExistsAsDirectory(*journalDirectory)); if ((__builtin_expect(!!(tryResult990.isErr()), 0))) { mozilla:: dom::quota::HandleError("ExistsAsDirectory(*journalDirectory)" , tryResult990.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11743, mozilla::dom::quota::Severity::Error); return tryResult990 .propagateErr(); } const bool& existsAsDirectory = tryResult990 .inspect();; |
11744 | Unused << existsAsDirectory; |
11745 | |
11746 | { |
11747 | QM_TRY_UNWRAP(auto path, MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult991 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (journalDirectory)>::GetPath), (journalDirectory))); if (( __builtin_expect(!!(tryResult991.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(journalDirectory)>::GetPath), (journalDirectory))" , tryResult991.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11748, mozilla::dom::quota::Severity::Error); return tryResult991 .propagateErr(); } auto path = tryResult991.unwrap(); |
11748 | nsString, journalDirectory, GetPath))auto tryResult991 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (journalDirectory)>::GetPath), (journalDirectory))); if (( __builtin_expect(!!(tryResult991.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(journalDirectory)>::GetPath), (journalDirectory))" , tryResult991.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11748, mozilla::dom::quota::Severity::Error); return tryResult991 .propagateErr(); } auto path = tryResult991.unwrap();; |
11749 | |
11750 | mJournalDirectoryPath.init(std::move(path)); |
11751 | } |
11752 | |
11753 | mDatabaseVersion = aDatabaseVersion; |
11754 | |
11755 | QM_TRY_INSPECT(const auto& stmt,auto tryResult992 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(aConnection)>::CreateStatement ), (aConnection), "SELECT id, refcount FROM file"_ns)); if (( __builtin_expect(!!(tryResult992.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aConnection)>::CreateStatement), (aConnection), \"SELECT id, refcount FROM file\"_ns)" , tryResult992.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11758, mozilla::dom::quota::Severity::Error); return tryResult992 .propagateErr(); } const auto& stmt = tryResult992.inspect (); |
11756 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult992 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(aConnection)>::CreateStatement ), (aConnection), "SELECT id, refcount FROM file"_ns)); if (( __builtin_expect(!!(tryResult992.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aConnection)>::CreateStatement), (aConnection), \"SELECT id, refcount FROM file\"_ns)" , tryResult992.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11758, mozilla::dom::quota::Severity::Error); return tryResult992 .propagateErr(); } const auto& stmt = tryResult992.inspect (); |
11757 | nsCOMPtr<mozIStorageStatement>, aConnection,auto tryResult992 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(aConnection)>::CreateStatement ), (aConnection), "SELECT id, refcount FROM file"_ns)); if (( __builtin_expect(!!(tryResult992.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aConnection)>::CreateStatement), (aConnection), \"SELECT id, refcount FROM file\"_ns)" , tryResult992.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11758, mozilla::dom::quota::Severity::Error); return tryResult992 .propagateErr(); } const auto& stmt = tryResult992.inspect (); |
11758 | CreateStatement, "SELECT id, refcount FROM file"_ns))auto tryResult992 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(aConnection)>::CreateStatement ), (aConnection), "SELECT id, refcount FROM file"_ns)); if (( __builtin_expect(!!(tryResult992.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(aConnection)>::CreateStatement), (aConnection), \"SELECT id, refcount FROM file\"_ns)" , tryResult992.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11758, mozilla::dom::quota::Severity::Error); return tryResult992 .propagateErr(); } const auto& stmt = tryResult992.inspect ();; |
11759 | |
11760 | QM_TRY({auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11761 | CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> {{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11762 | QM_TRY_INSPECT(const int64_t& id,{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11763 | MOZ_TO_RESULT_INVOKE_MEMBER(stmt, GetInt64, 0));{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11764 | QM_TRY_INSPECT(const int32_t& dbRefCnt,{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11765 | MOZ_TO_RESULT_INVOKE_MEMBER(stmt, GetInt32, 1));{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11766 | |
11767 | // We put a raw pointer into the hash table, so the memory refcount will{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11768 | // be 0, but the dbRefCnt is non-zero, which will keep the{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11769 | // DatabaseFileInfo object alive.{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11770 | MOZ_ASSERT(dbRefCnt > 0);{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11771 | DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt));{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11772 | MOZ_ASSERT(ok);{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11773 | |
11774 | return Ok{};{auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }} |
11775 | })){auto tryResult995 = (CollectWhileHasResult(*stmt, [this](auto & stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla:: detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ( (__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)" , tryResult993.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11763, mozilla::dom::quota::Severity::Error); return tryResult993 .propagateErr(); } const int64_t& id = tryResult993.inspect ();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt ), &::mozilla::detail::DerefedType<decltype(stmt)>:: GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()) , 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)" , tryResult994.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11765, mozilla::dom::quota::Severity::Error); return tryResult994 .propagateErr(); } const int32_t& dbRefCnt = tryResult994 .inspect();; do { static_assert( mozilla::detail::AssertionConditionType <decltype(dbRefCnt > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("dbRefCnt > 0" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11770); AnnotateMozCrashReason("MOZ_ASSERT" "(" "dbRefCnt > 0" ")"); do { *((volatile int*)__null) = 11770; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt )); do { static_assert( mozilla::detail::AssertionConditionType <decltype(ok)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false ); MOZ_ReportAssertionFailure("ok", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11772); AnnotateMozCrashReason("MOZ_ASSERT" "(" "ok" ")"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; } )); static_assert(std::is_empty_v<typename decltype(tryResult995 )::ok_type>); if ((__builtin_expect(!!(tryResult995.isErr( )), 0))) { mozilla::dom::quota::HandleError("CollectWhileHasResult(*stmt, [this](auto& stmt) -> Result<Ok, nsresult> { auto tryResult993 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)); if ((__builtin_expect(!!(tryResult993.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt64, 0)\", tryResult993.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11763, mozilla::dom::quota::Severity::Error); return tryResult993.propagateErr(); } const int64_t& id = tryResult993.inspect();; auto tryResult994 = (::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)); if ((__builtin_expect(!!(tryResult994.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (stmt), &::mozilla::detail::DerefedType<decltype(stmt)>::GetInt32, 1)\", tryResult994.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11765, mozilla::dom::quota::Severity::Error); return tryResult994.propagateErr(); } const int32_t& dbRefCnt = tryResult994.inspect();; do { static_assert( mozilla::detail::AssertionConditionType<decltype(dbRefCnt > 0)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(dbRefCnt > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"dbRefCnt > 0\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11770); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"dbRefCnt > 0\" \")\"); do { *((volatile int*)__null) = 11770; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); DebugOnly ok = static_cast<bool>(CreateFileInfo(Some(id), dbRefCnt)); do { static_assert( mozilla::detail::AssertionConditionType<decltype(ok)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(ok))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"ok\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11772); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"ok\" \")\"); do { *((volatile int*)__null) = 11772; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); return Ok{}; })" , tryResult995.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11775, mozilla::dom::quota::Severity::Error); return tryResult995 .propagateErr(); }}; |
11776 | |
11777 | mInitialized.Flip(); |
11778 | |
11779 | return NS_OK; |
11780 | } |
11781 | |
11782 | nsCOMPtr<nsIFile> DatabaseFileManager::GetDirectory() { |
11783 | if (!this->AssertValid()) { |
11784 | return nullptr; |
11785 | } |
11786 | |
11787 | return GetFileForPath(*mDirectoryPath); |
11788 | } |
11789 | |
11790 | nsCOMPtr<nsIFile> DatabaseFileManager::GetCheckedDirectory() { |
11791 | auto directory = GetDirectory(); |
11792 | if (NS_WARN_IF(!directory)NS_warn_if_impl(!directory, "!directory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11792)) { |
11793 | return nullptr; |
11794 | } |
11795 | |
11796 | DebugOnly<bool> exists; |
11797 | MOZ_ASSERT(NS_SUCCEEDED(directory->Exists(&exists)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(directory ->Exists(&exists))), 1))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( !NS_FAILED_impl(directory->Exists(&exists))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(directory->Exists(&exists))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11797); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(directory->Exists(&exists))), 1)))" ")"); do { *((volatile int*)__null) = 11797; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11798 | MOZ_ASSERT(exists)do { static_assert( mozilla::detail::AssertionConditionType< decltype(exists)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(exists))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("exists", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11798); AnnotateMozCrashReason("MOZ_ASSERT" "(" "exists" ")" ); do { *((volatile int*)__null) = 11798; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
11799 | |
11800 | DebugOnly<bool> isDirectory; |
11801 | MOZ_ASSERT(NS_SUCCEEDED(directory->IsDirectory(&isDirectory)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(directory ->IsDirectory(&isDirectory))), 1))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( !NS_FAILED_impl(directory->IsDirectory(&isDirectory))) , 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("((bool)(__builtin_expect(!!(!NS_FAILED_impl(directory->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11801); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(directory->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 11801; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11802 | MOZ_ASSERT(isDirectory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(isDirectory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11802); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 11802; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11803 | |
11804 | return directory; |
11805 | } |
11806 | |
11807 | nsCOMPtr<nsIFile> DatabaseFileManager::GetJournalDirectory() { |
11808 | if (!this->AssertValid()) { |
11809 | return nullptr; |
11810 | } |
11811 | |
11812 | return GetFileForPath(*mJournalDirectoryPath); |
11813 | } |
11814 | |
11815 | nsCOMPtr<nsIFile> DatabaseFileManager::EnsureJournalDirectory() { |
11816 | // This can happen on the IO or on a transaction thread. |
11817 | MOZ_ASSERT(!NS_IsMainThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!NS_IsMainThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!NS_IsMainThread()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!NS_IsMainThread()" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11817); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!NS_IsMainThread()" ")"); do { *((volatile int*)__null) = 11817; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11818 | |
11819 | auto journalDirectory = GetFileForPath(*mJournalDirectoryPath); |
11820 | QM_TRY(OkIf(journalDirectory), nullptr){auto tryResult996 = (OkIf(journalDirectory)); static_assert( std::is_empty_v<typename decltype(tryResult996)::ok_type> ); if ((__builtin_expect(!!(tryResult996.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult996.unwrapErr (); mozilla::dom::quota::HandleError("OkIf(journalDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11820, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(journalDirectory)" , tryTempError, nullptr); }}; |
11821 | |
11822 | QM_TRY_INSPECT(const bool& exists,auto tryResult997 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult997.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult997 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11824, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryTempError, nullptr); } const bool& exists = tryResult997 .inspect(); |
11823 | MOZ_TO_RESULT_INVOKE_MEMBER(journalDirectory, Exists),auto tryResult997 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult997.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult997 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11824, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryTempError, nullptr); } const bool& exists = tryResult997 .inspect(); |
11824 | nullptr)auto tryResult997 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult997.isErr( )), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult997 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11824, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryTempError, nullptr); } const bool& exists = tryResult997 .inspect();; |
11825 | |
11826 | if (exists) { |
11827 | QM_TRY_INSPECT(const bool& isDirectory,auto tryResult998 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult998.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult998 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11829, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryTempError, nullptr); } const bool& isDirectory = tryResult998 .inspect(); |
11828 | MOZ_TO_RESULT_INVOKE_MEMBER(journalDirectory, IsDirectory),auto tryResult998 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult998.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult998 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11829, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryTempError, nullptr); } const bool& isDirectory = tryResult998 .inspect(); |
11829 | nullptr)auto tryResult998 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult998.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult998 .unwrapErr(); mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11829, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryTempError, nullptr); } const bool& isDirectory = tryResult998 .inspect();; |
11830 | |
11831 | QM_TRY(OkIf(isDirectory), nullptr){auto tryResult999 = (OkIf(isDirectory)); static_assert(std:: is_empty_v<typename decltype(tryResult999)::ok_type>); if ((__builtin_expect(!!(tryResult999.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult999.unwrapErr(); mozilla ::dom::quota::HandleError("OkIf(isDirectory)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11831, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(isDirectory)" , tryTempError, nullptr); }}; |
11832 | } else { |
11833 | QM_TRY({auto tryResult1000 = (ToResult(journalDirectory->Create(nsIFile ::DIRECTORY_TYPE, 0755))); static_assert(std::is_empty_v<typename decltype(tryResult1000)::ok_type>); if ((__builtin_expect (!!(tryResult1000.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1000.unwrapErr(); mozilla::dom::quota ::HandleError("ToResult(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11835, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryTempError, nullptr); }} |
11834 | MOZ_TO_RESULT(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755)),{auto tryResult1000 = (ToResult(journalDirectory->Create(nsIFile ::DIRECTORY_TYPE, 0755))); static_assert(std::is_empty_v<typename decltype(tryResult1000)::ok_type>); if ((__builtin_expect (!!(tryResult1000.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1000.unwrapErr(); mozilla::dom::quota ::HandleError("ToResult(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11835, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryTempError, nullptr); }} |
11835 | nullptr){auto tryResult1000 = (ToResult(journalDirectory->Create(nsIFile ::DIRECTORY_TYPE, 0755))); static_assert(std::is_empty_v<typename decltype(tryResult1000)::ok_type>); if ((__builtin_expect (!!(tryResult1000.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1000.unwrapErr(); mozilla::dom::quota ::HandleError("ToResult(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11835, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "ToResult(journalDirectory->Create(nsIFile::DIRECTORY_TYPE, 0755))" , tryTempError, nullptr); }}; |
11836 | } |
11837 | |
11838 | return journalDirectory; |
11839 | } |
11840 | |
11841 | // static |
11842 | nsCOMPtr<nsIFile> DatabaseFileManager::GetFileForId(nsIFile* aDirectory, |
11843 | int64_t aId) { |
11844 | MOZ_ASSERT(aDirectory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11844); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectory" ")"); do { *((volatile int*)__null) = 11844; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11845 | MOZ_ASSERT(aId > 0)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aId > 0)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aId > 0))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aId > 0", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11845); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aId > 0" ")"); do { *((volatile int*)__null) = 11845; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11846 | |
11847 | QM_TRY_RETURN(CloneFileAndAppend(*aDirectory, IntToString(aId)), nullptr){auto tryResult1001 = (CloneFileAndAppend(*aDirectory, IntToString (aId))); if ((__builtin_expect(!!(tryResult1001.isErr()), 0)) ) { auto tryTempError __attribute__((__unused__)) = tryResult1001 .unwrapErr(); mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, IntToString(aId))" , tryResult1001.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11847, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "CloneFileAndAppend(*aDirectory, IntToString(aId))" , tryTempError, nullptr); } return tryResult1001.unwrap();}; |
11848 | } |
11849 | |
11850 | // static |
11851 | nsCOMPtr<nsIFile> DatabaseFileManager::GetCheckedFileForId(nsIFile* aDirectory, |
11852 | int64_t aId) { |
11853 | auto file = GetFileForId(aDirectory, aId); |
11854 | if (NS_WARN_IF(!file)NS_warn_if_impl(!file, "!file", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11854)) { |
11855 | return nullptr; |
11856 | } |
11857 | |
11858 | DebugOnly<bool> exists; |
11859 | MOZ_ASSERT(NS_SUCCEEDED(file->Exists(&exists)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(file-> Exists(&exists))), 1))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( !NS_FAILED_impl(file->Exists(&exists))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(file->Exists(&exists))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11859); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(file->Exists(&exists))), 1)))" ")"); do { *((volatile int*)__null) = 11859; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11860 | MOZ_ASSERT(exists)do { static_assert( mozilla::detail::AssertionConditionType< decltype(exists)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(exists))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("exists", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11860); AnnotateMozCrashReason("MOZ_ASSERT" "(" "exists" ")" ); do { *((volatile int*)__null) = 11860; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
11861 | |
11862 | DebugOnly<bool> isFile; |
11863 | MOZ_ASSERT(NS_SUCCEEDED(file->IsFile(&isFile)))do { static_assert( mozilla::detail::AssertionConditionType< decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(file-> IsFile(&isFile))), 1))))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!( !NS_FAILED_impl(file->IsFile(&isFile))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(file->IsFile(&isFile))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11863); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(file->IsFile(&isFile))), 1)))" ")"); do { *((volatile int*)__null) = 11863; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11864 | MOZ_ASSERT(isFile)do { static_assert( mozilla::detail::AssertionConditionType< decltype(isFile)>::isValid, "invalid assertion condition") ; if ((__builtin_expect(!!(!(!!(isFile))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isFile", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11864); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isFile" ")" ); do { *((volatile int*)__null) = 11864; __attribute__((nomerge )) ::abort(); } while (false); } } while (false); |
11865 | |
11866 | return file; |
11867 | } |
11868 | |
11869 | // static |
11870 | nsresult DatabaseFileManager::InitDirectory(nsIFile& aDirectory, |
11871 | nsIFile& aDatabaseFile, |
11872 | const nsACString& aOrigin, |
11873 | uint32_t aTelemetryId) { |
11874 | AssertIsOnIOThread(); |
11875 | |
11876 | { |
11877 | QM_TRY_INSPECT(const bool& exists,auto tryResult1002 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult1002.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::Exists)" , tryResult1002.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11878, mozilla::dom::quota::Severity::Error); return tryResult1002 .propagateErr(); } const bool& exists = tryResult1002.inspect (); |
11878 | MOZ_TO_RESULT_INVOKE_MEMBER(aDirectory, Exists))auto tryResult1002 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult1002.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::Exists)" , tryResult1002.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11878, mozilla::dom::quota::Severity::Error); return tryResult1002 .propagateErr(); } const bool& exists = tryResult1002.inspect ();; |
11879 | |
11880 | if (!exists) { |
11881 | return NS_OK; |
11882 | } |
11883 | |
11884 | QM_TRY_INSPECT(const bool& isDirectory,auto tryResult1003 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult1003. isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::IsDirectory)" , tryResult1003.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11885, mozilla::dom::quota::Severity::Error); return tryResult1003 .propagateErr(); } const bool& isDirectory = tryResult1003 .inspect(); |
11885 | MOZ_TO_RESULT_INVOKE_MEMBER(aDirectory, IsDirectory))auto tryResult1003 = (::mozilla::ToResultInvokeMember( (aDirectory ), &::mozilla::detail::DerefedType<decltype(aDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult1003. isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (aDirectory), &::mozilla::detail::DerefedType<decltype(aDirectory)>::IsDirectory)" , tryResult1003.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11885, mozilla::dom::quota::Severity::Error); return tryResult1003 .propagateErr(); } const bool& isDirectory = tryResult1003 .inspect();; |
11886 | QM_TRY(OkIf(isDirectory), NS_ERROR_FAILURE){auto tryResult1004 = (OkIf(isDirectory)); static_assert(std:: is_empty_v<typename decltype(tryResult1004)::ok_type>); if ((__builtin_expect(!!(tryResult1004.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1004.unwrapErr (); mozilla::dom::quota::HandleError("OkIf(isDirectory)", tryTempError , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11886, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(isDirectory)" , tryTempError, NS_ERROR_FAILURE); }}; |
11887 | } |
11888 | |
11889 | QM_TRY_INSPECT(const auto& journalDirectory,auto tryResult1005 = (CloneFileAndAppend(aDirectory, kJournalDirectoryName )); if ((__builtin_expect(!!(tryResult1005.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(aDirectory, kJournalDirectoryName)" , tryResult1005.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11890, mozilla::dom::quota::Severity::Error); return tryResult1005 .propagateErr(); } const auto& journalDirectory = tryResult1005 .inspect(); |
11890 | CloneFileAndAppend(aDirectory, kJournalDirectoryName))auto tryResult1005 = (CloneFileAndAppend(aDirectory, kJournalDirectoryName )); if ((__builtin_expect(!!(tryResult1005.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(aDirectory, kJournalDirectoryName)" , tryResult1005.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11890, mozilla::dom::quota::Severity::Error); return tryResult1005 .propagateErr(); } const auto& journalDirectory = tryResult1005 .inspect();; |
11891 | |
11892 | QM_TRY_INSPECT(const bool& exists,auto tryResult1006 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult1006.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryResult1006.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11893, mozilla::dom::quota::Severity::Error); return tryResult1006 .propagateErr(); } const bool& exists = tryResult1006.inspect (); |
11893 | MOZ_TO_RESULT_INVOKE_MEMBER(journalDirectory, Exists))auto tryResult1006 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::Exists)); if ((__builtin_expect(!!(tryResult1006.isErr ()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::Exists)" , tryResult1006.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11893, mozilla::dom::quota::Severity::Error); return tryResult1006 .propagateErr(); } const bool& exists = tryResult1006.inspect ();; |
11894 | |
11895 | if (exists) { |
11896 | QM_TRY_INSPECT(const bool& isDirectory,auto tryResult1007 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult1007. isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryResult1007.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11897, mozilla::dom::quota::Severity::Error); return tryResult1007 .propagateErr(); } const bool& isDirectory = tryResult1007 .inspect(); |
11897 | MOZ_TO_RESULT_INVOKE_MEMBER(journalDirectory, IsDirectory))auto tryResult1007 = (::mozilla::ToResultInvokeMember( (journalDirectory ), &::mozilla::detail::DerefedType<decltype(journalDirectory )>::IsDirectory)); if ((__builtin_expect(!!(tryResult1007. isErr()), 0))) { mozilla::dom::quota::HandleError("::mozilla::ToResultInvokeMember( (journalDirectory), &::mozilla::detail::DerefedType<decltype(journalDirectory)>::IsDirectory)" , tryResult1007.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11897, mozilla::dom::quota::Severity::Error); return tryResult1007 .propagateErr(); } const bool& isDirectory = tryResult1007 .inspect();; |
11898 | QM_TRY(OkIf(isDirectory), NS_ERROR_FAILURE){auto tryResult1008 = (OkIf(isDirectory)); static_assert(std:: is_empty_v<typename decltype(tryResult1008)::ok_type>); if ((__builtin_expect(!!(tryResult1008.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1008.unwrapErr (); mozilla::dom::quota::HandleError("OkIf(isDirectory)", tryTempError , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11898, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(isDirectory)" , tryTempError, NS_ERROR_FAILURE); }}; |
11899 | |
11900 | bool hasJournals = false; |
11901 | |
11902 | QM_TRY(CollectEachFile({auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11903 | *journalDirectory,{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11904 | [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> {{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11905 | QM_TRY_INSPECT({auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11906 | const auto& leafName,{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11907 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(nsString, file, GetLeafName));{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11908 | |
11909 | nsresult rv;{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11910 | leafName.ToInteger64(&rv);{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11911 | if (NS_SUCCEEDED(rv)) {{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11912 | hasJournals = true;{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11913 | } else {{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11914 | UNKNOWN_FILE_WARNING(leafName);{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11915 | }{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11916 | |
11917 | return Ok{};{auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }} |
11918 | })){auto tryResult1010 = (CollectEachFile( *journalDirectory, [& hasJournals](const nsCOMPtr<nsIFile>& file) -> Result <Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke < nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType <decltype(file)>::GetLeafName), (file))); if ((__builtin_expect (!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))" , tryResult1009.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11907, mozilla::dom::quota::Severity::Error); return tryResult1009 .propagateErr(); } const auto& leafName = tryResult1009.inspect ();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)( __builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString ( "Something (%s) in the directory that doesn't belong!", NS_ConvertUTF16toUTF8 (leafName).get()) .get(), nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11914); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1010)::ok_type>); if ((__builtin_expect (!!(tryResult1010.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachFile( *journalDirectory, [&hasJournals](const nsCOMPtr<nsIFile>& file) -> Result<Ok, nsresult> { auto tryResult1009 = (::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))); if ((__builtin_expect(!!(tryResult1009.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(file)>::GetLeafName), (file))\", tryResult1009.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11907, mozilla::dom::quota::Severity::Error); return tryResult1009.propagateErr(); } const auto& leafName = tryResult1009.inspect();; nsresult rv; leafName.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(!NS_FAILED_impl(rv)), 1)))) { hasJournals = true; } else { NS_DebugBreak(NS_DEBUG_WARNING, nsPrintfCString( \"Something (%s) in the directory that doesn't belong!\", NS_ConvertUTF16toUTF8(leafName).get()) .get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11914); } return Ok{}; })" , tryResult1010.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11918, mozilla::dom::quota::Severity::Error); return tryResult1010 .propagateErr(); }}; |
11919 | |
11920 | if (hasJournals) { |
11921 | QM_TRY_UNWRAP(const NotNull<nsCOMPtr<mozIStorageConnection>> connection,auto tryResult1011 = (CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing {})); if ((__builtin_expect(!!(tryResult1011.isErr()), 0))) { mozilla::dom::quota::HandleError("CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing{})" , tryResult1011.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11924, mozilla::dom::quota::Severity::Error); return tryResult1011 .propagateErr(); } const NotNull<nsCOMPtr<mozIStorageConnection >> connection = tryResult1011.unwrap(); |
11922 | CreateStorageConnection(auto tryResult1011 = (CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing {})); if ((__builtin_expect(!!(tryResult1011.isErr()), 0))) { mozilla::dom::quota::HandleError("CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing{})" , tryResult1011.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11924, mozilla::dom::quota::Severity::Error); return tryResult1011 .propagateErr(); } const NotNull<nsCOMPtr<mozIStorageConnection >> connection = tryResult1011.unwrap(); |
11923 | aDatabaseFile, aDirectory, VoidString(), aOrigin,auto tryResult1011 = (CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing {})); if ((__builtin_expect(!!(tryResult1011.isErr()), 0))) { mozilla::dom::quota::HandleError("CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing{})" , tryResult1011.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11924, mozilla::dom::quota::Severity::Error); return tryResult1011 .propagateErr(); } const NotNull<nsCOMPtr<mozIStorageConnection >> connection = tryResult1011.unwrap(); |
11924 | /* aDirectoryLockId */ -1, aTelemetryId, Nothing{}))auto tryResult1011 = (CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing {})); if ((__builtin_expect(!!(tryResult1011.isErr()), 0))) { mozilla::dom::quota::HandleError("CreateStorageConnection( aDatabaseFile, aDirectory, VoidString(), aOrigin, -1, aTelemetryId, Nothing{})" , tryResult1011.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11924, mozilla::dom::quota::Severity::Error); return tryResult1011 .propagateErr(); } const NotNull<nsCOMPtr<mozIStorageConnection >> connection = tryResult1011.unwrap();; |
11925 | |
11926 | mozStorageTransaction transaction(connection.get(), false); |
11927 | |
11928 | QM_TRY(MOZ_TO_RESULT(transaction.Start())){auto tryResult1012 = (ToResult(transaction.Start())); static_assert (std::is_empty_v<typename decltype(tryResult1012)::ok_type >); if ((__builtin_expect(!!(tryResult1012.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(transaction.Start())" , tryResult1012.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11928, mozilla::dom::quota::Severity::Error); return tryResult1012 .propagateErr(); }} |
11929 | |
11930 | QM_TRY(MOZ_TO_RESULT(connection->ExecuteSimpleSQL({auto tryResult1013 = (ToResult(connection->ExecuteSimpleSQL ( "CREATE VIRTUAL TABLE fs USING filesystem;"_ns))); static_assert (std::is_empty_v<typename decltype(tryResult1013)::ok_type >); if ((__builtin_expect(!!(tryResult1013.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL( \"CREATE VIRTUAL TABLE fs USING filesystem;\"_ns))" , tryResult1013.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11931, mozilla::dom::quota::Severity::Error); return tryResult1013 .propagateErr(); }} |
11931 | "CREATE VIRTUAL TABLE fs USING filesystem;"_ns))){auto tryResult1013 = (ToResult(connection->ExecuteSimpleSQL ( "CREATE VIRTUAL TABLE fs USING filesystem;"_ns))); static_assert (std::is_empty_v<typename decltype(tryResult1013)::ok_type >); if ((__builtin_expect(!!(tryResult1013.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(connection->ExecuteSimpleSQL( \"CREATE VIRTUAL TABLE fs USING filesystem;\"_ns))" , tryResult1013.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11931, mozilla::dom::quota::Severity::Error); return tryResult1013 .propagateErr(); }}; |
11932 | |
11933 | // The parameter names are not used, parameters are bound by index only |
11934 | // locally in the same function. |
11935 | QM_TRY_INSPECT(auto tryResult1014 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(*connection)>::CreateStatement ), (*connection), "SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path"_ns )); if ((__builtin_expect(!!(tryResult1014.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*connection)>::CreateStatement), (*connection), \"SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path\"_ns)" , tryResult1014.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11939, mozilla::dom::quota::Severity::Error); return tryResult1014 .propagateErr(); } const auto& stmt = tryResult1014.inspect (); |
11936 | const auto& stmt,auto tryResult1014 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(*connection)>::CreateStatement ), (*connection), "SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path"_ns )); if ((__builtin_expect(!!(tryResult1014.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*connection)>::CreateStatement), (*connection), \"SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path\"_ns)" , tryResult1014.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11939, mozilla::dom::quota::Severity::Error); return tryResult1014 .propagateErr(); } const auto& stmt = tryResult1014.inspect (); |
11937 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult1014 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(*connection)>::CreateStatement ), (*connection), "SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path"_ns )); if ((__builtin_expect(!!(tryResult1014.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*connection)>::CreateStatement), (*connection), \"SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path\"_ns)" , tryResult1014.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11939, mozilla::dom::quota::Severity::Error); return tryResult1014 .propagateErr(); } const auto& stmt = tryResult1014.inspect (); |
11938 | nsCOMPtr<mozIStorageStatement>, *connection, CreateStatement,auto tryResult1014 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(*connection)>::CreateStatement ), (*connection), "SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path"_ns )); if ((__builtin_expect(!!(tryResult1014.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*connection)>::CreateStatement), (*connection), \"SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path\"_ns)" , tryResult1014.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11939, mozilla::dom::quota::Severity::Error); return tryResult1014 .propagateErr(); } const auto& stmt = tryResult1014.inspect (); |
11939 | "SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path"_ns))auto tryResult1014 = (::mozilla::ToResultInvoke< nsCOMPtr< mozIStorageStatement> >( ::std::mem_fn( &::mozilla:: detail::DerefedType<decltype(*connection)>::CreateStatement ), (*connection), "SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path"_ns )); if ((__builtin_expect(!!(tryResult1014.isErr()), 0))) { mozilla ::dom::quota::HandleError("::mozilla::ToResultInvoke< nsCOMPtr<mozIStorageStatement>>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(*connection)>::CreateStatement), (*connection), \"SELECT name, (name IN (SELECT id FROM file)) FROM fs WHERE path = :path\"_ns)" , tryResult1014.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11939, mozilla::dom::quota::Severity::Error); return tryResult1014 .propagateErr(); } const auto& stmt = tryResult1014.inspect ();; |
11940 | |
11941 | QM_TRY_INSPECT(const auto& path,auto tryResult1015 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (journalDirectory)>::GetPath), (journalDirectory))); if (( __builtin_expect(!!(tryResult1015.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(journalDirectory)>::GetPath), (journalDirectory))" , tryResult1015.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11943, mozilla::dom::quota::Severity::Error); return tryResult1015 .propagateErr(); } const auto& path = tryResult1015.inspect (); |
11942 | MOZ_TO_RESULT_INVOKE_MEMBER_TYPED(auto tryResult1015 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (journalDirectory)>::GetPath), (journalDirectory))); if (( __builtin_expect(!!(tryResult1015.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(journalDirectory)>::GetPath), (journalDirectory))" , tryResult1015.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11943, mozilla::dom::quota::Severity::Error); return tryResult1015 .propagateErr(); } const auto& path = tryResult1015.inspect (); |
11943 | nsString, journalDirectory, GetPath))auto tryResult1015 = (::mozilla::ToResultInvoke< nsString> ( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype (journalDirectory)>::GetPath), (journalDirectory))); if (( __builtin_expect(!!(tryResult1015.isErr()), 0))) { mozilla::dom ::quota::HandleError("::mozilla::ToResultInvoke< nsString>( ::std::mem_fn( &::mozilla::detail::DerefedType<decltype(journalDirectory)>::GetPath), (journalDirectory))" , tryResult1015.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11943, mozilla::dom::quota::Severity::Error); return tryResult1015 .propagateErr(); } const auto& path = tryResult1015.inspect ();; |
11944 | |
11945 | QM_TRY(MOZ_TO_RESULT(stmt->BindStringByIndex(0, path))){auto tryResult1016 = (ToResult(stmt->BindStringByIndex(0, path))); static_assert(std::is_empty_v<typename decltype( tryResult1016)::ok_type>); if ((__builtin_expect(!!(tryResult1016 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt->BindStringByIndex(0, path))" , tryResult1016.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11945, mozilla::dom::quota::Severity::Error); return tryResult1016 .propagateErr(); }}; |
11946 | |
11947 | QM_TRY(CollectWhileHasResult({auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11948 | *stmt,{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11949 | [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> {{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11950 | nsString name;{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11951 | QM_TRY(MOZ_TO_RESULT(stmt.GetString(0, name)));{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11952 | |
11953 | nsresult rv;{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11954 | name.ToInteger64(&rv);{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11955 | if (NS_FAILED(rv)) {{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11956 | return Ok{};{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11957 | }{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11958 | |
11959 | int32_t flag = stmt.AsInt32(1);{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11960 | |
11961 | if (!flag) {{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11962 | QM_TRY_INSPECT(const auto& file,{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11963 | CloneFileAndAppend(aDirectory, name));{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11964 | |
11965 | if (NS_FAILED(file->Remove(false))) {{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11966 | NS_WARNING("Failed to remove orphaned file!");{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11967 | }{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11968 | }{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11969 | |
11970 | QM_TRY_INSPECT(const auto& journalFile,{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11971 | CloneFileAndAppend(*journalDirectory, name));{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11972 | |
11973 | if (NS_FAILED(journalFile->Remove(false))) {{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11974 | NS_WARNING("Failed to remove journal file!");{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11975 | }{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11976 | |
11977 | return Ok{};{auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }} |
11978 | })){auto tryResult1020 = (CollectWhileHasResult( *stmt, [&aDirectory , &journalDirectory](auto& stmt) -> Result<Ok, nsresult > { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString (0, name))); static_assert(std::is_empty_v<typename decltype (tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017 .isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(stmt.GetString(0, name))" , tryResult1017.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11951, mozilla::dom::quota::Severity::Error); return tryResult1017 .propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect (!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError ("CloneFileAndAppend(aDirectory, name)", tryResult1018.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11963, mozilla::dom::quota::Severity::Error); return tryResult1018 .propagateErr(); } const auto& file = tryResult1018.inspect ();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file-> Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove orphaned file!" , nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory , name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0) )) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*journalDirectory, name)" , tryResult1019.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11971, mozilla::dom::quota::Severity::Error); return tryResult1019 .propagateErr(); } const auto& journalFile = tryResult1019 .inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile ->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, "Failed to remove journal file!", nullptr, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11974); } return Ok{}; })); static_assert(std::is_empty_v< typename decltype(tryResult1020)::ok_type>); if ((__builtin_expect (!!(tryResult1020.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectWhileHasResult( *stmt, [&aDirectory, &journalDirectory](auto& stmt) -> Result<Ok, nsresult> { nsString name; {auto tryResult1017 = (ToResult(stmt.GetString(0, name))); static_assert(std::is_empty_v<typename decltype(tryResult1017)::ok_type>); if ((__builtin_expect(!!(tryResult1017.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(stmt.GetString(0, name))\", tryResult1017.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11951, mozilla::dom::quota::Severity::Error); return tryResult1017.propagateErr(); }}; nsresult rv; name.ToInteger64(&rv); if (((bool)(__builtin_expect(!!(NS_FAILED_impl(rv)), 0)))) { return Ok{}; } int32_t flag = stmt.AsInt32(1); if (!flag) { auto tryResult1018 = (CloneFileAndAppend(aDirectory, name)); if ((__builtin_expect(!!(tryResult1018.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(aDirectory, name)\", tryResult1018.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11963, mozilla::dom::quota::Severity::Error); return tryResult1018.propagateErr(); } const auto& file = tryResult1018.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(file->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove orphaned file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11966); } } auto tryResult1019 = (CloneFileAndAppend(*journalDirectory, name)); if ((__builtin_expect(!!(tryResult1019.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*journalDirectory, name)\", tryResult1019.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11971, mozilla::dom::quota::Severity::Error); return tryResult1019.propagateErr(); } const auto& journalFile = tryResult1019.inspect();; if (((bool)(__builtin_expect(!!(NS_FAILED_impl(journalFile->Remove(false))), 0)))) { NS_DebugBreak(NS_DEBUG_WARNING, \"Failed to remove journal file!\", nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 11974); } return Ok{}; })" , tryResult1020.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11978, mozilla::dom::quota::Severity::Error); return tryResult1020 .propagateErr(); }}; |
11979 | |
11980 | QM_TRY(MOZ_TO_RESULT(connection->ExecuteSimpleSQL("DROP TABLE fs;"_ns))){auto tryResult1021 = (ToResult(connection->ExecuteSimpleSQL ("DROP TABLE fs;"_ns))); static_assert(std::is_empty_v<typename decltype(tryResult1021)::ok_type>); if ((__builtin_expect (!!(tryResult1021.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(connection->ExecuteSimpleSQL(\"DROP TABLE fs;\"_ns))" , tryResult1021.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11980, mozilla::dom::quota::Severity::Error); return tryResult1021 .propagateErr(); }}; |
11981 | QM_TRY(MOZ_TO_RESULT(transaction.Commit())){auto tryResult1022 = (ToResult(transaction.Commit())); static_assert (std::is_empty_v<typename decltype(tryResult1022)::ok_type >); if ((__builtin_expect(!!(tryResult1022.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(transaction.Commit())" , tryResult1022.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11981, mozilla::dom::quota::Severity::Error); return tryResult1022 .propagateErr(); }}; |
11982 | } |
11983 | } |
11984 | |
11985 | return NS_OK; |
11986 | } |
11987 | |
11988 | // static |
11989 | Result<FileUsageType, nsresult> DatabaseFileManager::GetUsage( |
11990 | nsIFile* aDirectory) { |
11991 | AssertIsOnIOThread(); |
11992 | MOZ_ASSERT(aDirectory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 11992); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectory" ")"); do { *((volatile int*)__null) = 11992; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
11993 | |
11994 | FileUsageType usage; |
11995 | |
11996 | QM_TRY(TraverseFiles({auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
11997 | *aDirectory,{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
11998 | // KnownDirEntryOp{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
11999 | [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> {{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12000 | if (isDirectory) {{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12001 | return Ok{};{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12002 | }{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12003 | |
12004 | // Usually we only use QM_OR_ELSE_LOG_VERBOSE(_IF) with Remove and{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12005 | // NS_ERROR_FILE_NOT_FOUND check, but the file was found by a directory{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12006 | // traversal and ToInteger on the name succeeded, so it should be our{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12007 | // file and if the file disappears, the use of QM_OR_ELSE_WARN_IF is ok{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12008 | // here.{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12009 | QM_TRY_INSPECT(const auto& thisUsage,{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12010 | QM_OR_ELSE_WARN_IF({auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12011 | // Expression.{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12012 | MOZ_TO_RESULT_INVOKE_MEMBER(file, GetFileSize){auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12013 | .map([](const int64_t fileSize) {{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12014 | return FileUsageType(Some(uint64_t(fileSize)));{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12015 | }),{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12016 | // Predicate.{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12017 | ([](const nsresult rv) {{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12018 | return rv == NS_ERROR_FILE_NOT_FOUND;{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12019 | }),{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12020 | // Fallback. If the file does no longer exist, treat{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12021 | // it as 0-sized.{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12022 | ErrToDefaultOk<FileUsageType>));{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12023 | |
12024 | usage += thisUsage;{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12025 | |
12026 | return Ok{};{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12027 | },{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12028 | // UnknownDirEntryOp{auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }} |
12029 | [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })){auto tryResult1024 = (TraverseFiles( *aDirectory, [&usage ](nsIFile& file, const bool isDirectory) -> Result< Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember ( (file), &::mozilla::detail::DerefedType<decltype(file )>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType (Some(uint64_t(fileSize))); })), [&](const auto& firstRes ) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND ; })(firstRes); mozilla::dom::quota::HandleError("\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\"" , firstRes, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla ::dom::quota::Severity::Error); return res; }, ErrToDefaultOk <FileUsageType>)); if ((__builtin_expect(!!(tryResult1023 .isErr()), 0))) { mozilla::dom::quota::HandleError("mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)" , tryResult1023.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12022, mozilla::dom::quota::Severity::Error); return tryResult1023 .propagateErr(); } const auto& thisUsage = tryResult1023. inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile& , const bool) -> Result<Ok, nsresult> { return Ok{}; })); static_assert(std::is_empty_v<typename decltype(tryResult1024 )::ok_type>); if ((__builtin_expect(!!(tryResult1024.isErr ()), 0))) { mozilla::dom::quota::HandleError("TraverseFiles( *aDirectory, [&usage](nsIFile& file, const bool isDirectory) -> Result<Ok, nsresult> { if (isDirectory) { return Ok{}; } auto tryResult1023 = (mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\"\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\"\", firstRes, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)); if ((__builtin_expect(!!(tryResult1023.isErr()), 0))) { mozilla::dom::quota::HandleError(\"mozilla::dom::quota::OrElseIf( (::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })), [&](const auto& firstRes) { bool res = ([](const nsresult rv) { return rv == NS_ERROR_FILE_NOT_FOUND; })(firstRes); mozilla::dom::quota::HandleError(\\\"\\\\\\\"::mozilla::ToResultInvokeMember( (file), &::mozilla::detail::DerefedType<decltype(file)>::GetFileSize) .map([](const int64_t fileSize) { return FileUsageType(Some(uint64_t(fileSize))); })\\\\\\\"\\\", firstRes, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12022, res ? mozilla::dom::quota::Severity::Warning : mozilla::dom::quota::Severity::Error); return res; }, ErrToDefaultOk<FileUsageType>)\", tryResult1023.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12022, mozilla::dom::quota::Severity::Error); return tryResult1023.propagateErr(); } const auto& thisUsage = tryResult1023.inspect();; usage += thisUsage; return Ok{}; }, [](nsIFile&, const bool) -> Result<Ok, nsresult> { return Ok{}; })" , tryResult1024.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12029, mozilla::dom::quota::Severity::Error); return tryResult1024 .propagateErr(); }}; |
12030 | |
12031 | return usage; |
12032 | } |
12033 | |
12034 | nsresult DatabaseFileManager::SyncDeleteFile(const int64_t aId) { |
12035 | MOZ_ASSERT(!ContainsFileInfo(aId))do { static_assert( mozilla::detail::AssertionConditionType< decltype(!ContainsFileInfo(aId))>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!ContainsFileInfo(aId)))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!ContainsFileInfo(aId)" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12035); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!ContainsFileInfo(aId)" ")"); do { *((volatile int*)__null) = 12035; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12036 | |
12037 | if (!this->AssertValid()) { |
12038 | return NS_ERROR_UNEXPECTED; |
12039 | } |
12040 | |
12041 | const auto directory = GetDirectory(); |
12042 | QM_TRY(OkIf(directory), NS_ERROR_FAILURE){auto tryResult1025 = (OkIf(directory)); static_assert(std::is_empty_v <typename decltype(tryResult1025)::ok_type>); if ((__builtin_expect (!!(tryResult1025.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1025.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(directory)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12042, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(directory)" , tryTempError, NS_ERROR_FAILURE); }}; |
12043 | |
12044 | const auto journalDirectory = GetJournalDirectory(); |
12045 | QM_TRY(OkIf(journalDirectory), NS_ERROR_FAILURE){auto tryResult1026 = (OkIf(journalDirectory)); static_assert (std::is_empty_v<typename decltype(tryResult1026)::ok_type >); if ((__builtin_expect(!!(tryResult1026.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1026 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(journalDirectory)" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12045, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(journalDirectory)" , tryTempError, NS_ERROR_FAILURE); }}; |
12046 | |
12047 | const nsCOMPtr<nsIFile> file = GetFileForId(directory, aId); |
12048 | QM_TRY(OkIf(file), NS_ERROR_FAILURE){auto tryResult1027 = (OkIf(file)); static_assert(std::is_empty_v <typename decltype(tryResult1027)::ok_type>); if ((__builtin_expect (!!(tryResult1027.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1027.unwrapErr(); mozilla::dom::quota ::HandleError("OkIf(file)", tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12048, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(file)", tryTempError , NS_ERROR_FAILURE); }}; |
12049 | |
12050 | const nsCOMPtr<nsIFile> journalFile = GetFileForId(journalDirectory, aId); |
12051 | QM_TRY(OkIf(journalFile), NS_ERROR_FAILURE){auto tryResult1028 = (OkIf(journalFile)); static_assert(std:: is_empty_v<typename decltype(tryResult1028)::ok_type>); if ((__builtin_expect(!!(tryResult1028.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1028.unwrapErr (); mozilla::dom::quota::HandleError("OkIf(journalFile)", tryTempError , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12051, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(journalFile)" , tryTempError, NS_ERROR_FAILURE); }}; |
12052 | |
12053 | return SyncDeleteFile(*file, *journalFile); |
12054 | } |
12055 | |
12056 | nsresult DatabaseFileManager::SyncDeleteFile(nsIFile& aFile, |
12057 | nsIFile& aJournalFile) const { |
12058 | QuotaManager* const quotaManager = |
12059 | EnforcingQuota() ? QuotaManager::Get() : nullptr; |
12060 | MOZ_ASSERT_IF(EnforcingQuota(), quotaManager)do { if (EnforcingQuota()) { do { static_assert( mozilla::detail ::AssertionConditionType<decltype(quotaManager)>::isValid , "invalid assertion condition"); if ((__builtin_expect(!!(!( !!(quotaManager))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("quotaManager", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12060); AnnotateMozCrashReason("MOZ_ASSERT" "(" "quotaManager" ")"); do { *((volatile int*)__null) = 12060; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); } } while (false); |
12061 | |
12062 | QM_TRY(MOZ_TO_RESULT(DeleteFile(aFile, quotaManager, Type(), OriginMetadata(),{auto tryResult1029 = (ToResult(DeleteFile(aFile, quotaManager , Type(), OriginMetadata(), Idempotency::No))); static_assert (std::is_empty_v<typename decltype(tryResult1029)::ok_type >); if ((__builtin_expect(!!(tryResult1029.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFile(aFile, quotaManager, Type(), OriginMetadata(), Idempotency::No))" , tryResult1029.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12063, mozilla::dom::quota::Severity::Error); return tryResult1029 .propagateErr(); }} |
12063 | Idempotency::No))){auto tryResult1029 = (ToResult(DeleteFile(aFile, quotaManager , Type(), OriginMetadata(), Idempotency::No))); static_assert (std::is_empty_v<typename decltype(tryResult1029)::ok_type >); if ((__builtin_expect(!!(tryResult1029.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(DeleteFile(aFile, quotaManager, Type(), OriginMetadata(), Idempotency::No))" , tryResult1029.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12063, mozilla::dom::quota::Severity::Error); return tryResult1029 .propagateErr(); }}; |
12064 | |
12065 | QM_TRY(MOZ_TO_RESULT(aJournalFile.Remove(false))){auto tryResult1030 = (ToResult(aJournalFile.Remove(false))); static_assert(std::is_empty_v<typename decltype(tryResult1030 )::ok_type>); if ((__builtin_expect(!!(tryResult1030.isErr ()), 0))) { mozilla::dom::quota::HandleError("ToResult(aJournalFile.Remove(false))" , tryResult1030.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12065, mozilla::dom::quota::Severity::Error); return tryResult1030 .propagateErr(); }}; |
12066 | |
12067 | return NS_OK; |
12068 | } |
12069 | |
12070 | nsresult DatabaseFileManager::Invalidate() { |
12071 | if (mCipherKeyManager) { |
12072 | mCipherKeyManager->Invalidate(); |
12073 | } |
12074 | |
12075 | QM_TRY(MOZ_TO_RESULT(FileInfoManager::Invalidate())){auto tryResult1031 = (ToResult(FileInfoManager::Invalidate() )); static_assert(std::is_empty_v<typename decltype(tryResult1031 )::ok_type>); if ((__builtin_expect(!!(tryResult1031.isErr ()), 0))) { mozilla::dom::quota::HandleError("ToResult(FileInfoManager::Invalidate())" , tryResult1031.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12075, mozilla::dom::quota::Severity::Error); return tryResult1031 .propagateErr(); }}; |
12076 | |
12077 | return NS_OK; |
12078 | } |
12079 | |
12080 | /******************************************************************************* |
12081 | * QuotaClient |
12082 | ******************************************************************************/ |
12083 | |
12084 | QuotaClient* QuotaClient::sInstance = nullptr; |
12085 | |
12086 | QuotaClient::QuotaClient() : mDeleteTimer(NS_NewTimer()) { |
12087 | AssertIsOnBackgroundThread(); |
12088 | MOZ_ASSERT(!sInstance, "We expect this to be a singleton!")do { static_assert( mozilla::detail::AssertionConditionType< decltype(!sInstance)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!sInstance))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!sInstance" " (" "We expect this to be a singleton!" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12088); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!sInstance" ") (" "We expect this to be a singleton!" ")"); do { *((volatile int*)__null) = 12088; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); |
12089 | MOZ_ASSERT(!gTelemetryIdMutex)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!gTelemetryIdMutex)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!gTelemetryIdMutex))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("!gTelemetryIdMutex" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12089); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!gTelemetryIdMutex" ")"); do { *((volatile int*)__null) = 12089; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12090 | |
12091 | // Always create this so that later access to gTelemetryIdHashtable can be |
12092 | // properly synchronized. |
12093 | gTelemetryIdMutex = new Mutex("IndexedDB gTelemetryIdMutex"); |
12094 | |
12095 | gStorageDatabaseNameMutex = new Mutex("IndexedDB gStorageDatabaseNameMutex"); |
12096 | |
12097 | sInstance = this; |
12098 | } |
12099 | |
12100 | QuotaClient::~QuotaClient() { |
12101 | AssertIsOnBackgroundThread(); |
12102 | MOZ_ASSERT(sInstance == this, "We expect this to be a singleton!")do { static_assert( mozilla::detail::AssertionConditionType< decltype(sInstance == this)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(sInstance == this))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("sInstance == this" " (" "We expect this to be a singleton!" ")", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12102); AnnotateMozCrashReason("MOZ_ASSERT" "(" "sInstance == this" ") (" "We expect this to be a singleton!" ")"); do { *((volatile int*)__null) = 12102; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); |
12103 | MOZ_ASSERT(gTelemetryIdMutex)do { static_assert( mozilla::detail::AssertionConditionType< decltype(gTelemetryIdMutex)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(gTelemetryIdMutex))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("gTelemetryIdMutex" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12103); AnnotateMozCrashReason("MOZ_ASSERT" "(" "gTelemetryIdMutex" ")"); do { *((volatile int*)__null) = 12103; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12104 | MOZ_ASSERT(!mMaintenanceThreadPool)do { static_assert( mozilla::detail::AssertionConditionType< decltype(!mMaintenanceThreadPool)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!mMaintenanceThreadPool))), 0 ))) { do { } while (false); MOZ_ReportAssertionFailure("!mMaintenanceThreadPool" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12104); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!mMaintenanceThreadPool" ")"); do { *((volatile int*)__null) = 12104; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12105 | |
12106 | // No one else should be able to touch gTelemetryIdHashtable now that the |
12107 | // QuotaClient has gone away. |
12108 | gTelemetryIdHashtable = nullptr; |
12109 | gTelemetryIdMutex = nullptr; |
12110 | |
12111 | gStorageDatabaseNameHashtable = nullptr; |
12112 | gStorageDatabaseNameMutex = nullptr; |
12113 | |
12114 | sInstance = nullptr; |
12115 | } |
12116 | |
12117 | nsresult QuotaClient::AsyncDeleteFile(DatabaseFileManager* aFileManager, |
12118 | int64_t aFileId) { |
12119 | AssertIsOnBackgroundThread(); |
12120 | |
12121 | if (IsShuttingDownOnBackgroundThread()) { |
12122 | // Whoops! We want to delete an IndexedDB disk-backed File but it's too late |
12123 | // to actually delete the file! This means we're going to "leak" the file |
12124 | // and leave it around when we shouldn't! (The file will stay around until |
12125 | // next storage initialization is triggered when the app is started again). |
12126 | // Fixing this is tracked by bug 1539377. |
12127 | |
12128 | return NS_OK; |
12129 | } |
12130 | |
12131 | MOZ_ASSERT(mDeleteTimer)do { static_assert( mozilla::detail::AssertionConditionType< decltype(mDeleteTimer)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(mDeleteTimer))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("mDeleteTimer", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12131); AnnotateMozCrashReason("MOZ_ASSERT" "(" "mDeleteTimer" ")"); do { *((volatile int*)__null) = 12131; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12132 | MOZ_ALWAYS_SUCCEEDS(mDeleteTimer->Cancel())do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (mDeleteTimer->Cancel())), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(mDeleteTimer->Cancel())" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12132); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(mDeleteTimer->Cancel())" ")"); do { *((volatile int*)__null) = 12132; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
12133 | |
12134 | QM_TRY(MOZ_TO_RESULT(mDeleteTimer->InitWithNamedFuncCallback({auto tryResult1032 = (ToResult(mDeleteTimer->InitWithNamedFuncCallback ( DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT , "dom::indexeddb::QuotaClient::AsyncDeleteFile"))); static_assert (std::is_empty_v<typename decltype(tryResult1032)::ok_type >); if ((__builtin_expect(!!(tryResult1032.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(mDeleteTimer->InitWithNamedFuncCallback( DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT, \"dom::indexeddb::QuotaClient::AsyncDeleteFile\"))" , tryResult1032.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12136, mozilla::dom::quota::Severity::Error); return tryResult1032 .propagateErr(); }} |
12135 | DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT,{auto tryResult1032 = (ToResult(mDeleteTimer->InitWithNamedFuncCallback ( DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT , "dom::indexeddb::QuotaClient::AsyncDeleteFile"))); static_assert (std::is_empty_v<typename decltype(tryResult1032)::ok_type >); if ((__builtin_expect(!!(tryResult1032.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(mDeleteTimer->InitWithNamedFuncCallback( DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT, \"dom::indexeddb::QuotaClient::AsyncDeleteFile\"))" , tryResult1032.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12136, mozilla::dom::quota::Severity::Error); return tryResult1032 .propagateErr(); }} |
12136 | "dom::indexeddb::QuotaClient::AsyncDeleteFile"))){auto tryResult1032 = (ToResult(mDeleteTimer->InitWithNamedFuncCallback ( DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT , "dom::indexeddb::QuotaClient::AsyncDeleteFile"))); static_assert (std::is_empty_v<typename decltype(tryResult1032)::ok_type >); if ((__builtin_expect(!!(tryResult1032.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(mDeleteTimer->InitWithNamedFuncCallback( DeleteTimerCallback, this, kDeleteTimeoutMs, nsITimer::TYPE_ONE_SHOT, \"dom::indexeddb::QuotaClient::AsyncDeleteFile\"))" , tryResult1032.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12136, mozilla::dom::quota::Severity::Error); return tryResult1032 .propagateErr(); }}; |
12137 | |
12138 | mPendingDeleteInfos.GetOrInsertNew(aFileManager)->AppendElement(aFileId); |
12139 | |
12140 | return NS_OK; |
12141 | } |
12142 | |
12143 | nsresult QuotaClient::FlushPendingFileDeletions() { |
12144 | AssertIsOnBackgroundThread(); |
12145 | |
12146 | QM_TRY(MOZ_TO_RESULT(mDeleteTimer->Cancel())){auto tryResult1033 = (ToResult(mDeleteTimer->Cancel())); static_assert (std::is_empty_v<typename decltype(tryResult1033)::ok_type >); if ((__builtin_expect(!!(tryResult1033.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(mDeleteTimer->Cancel())" , tryResult1033.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12146, mozilla::dom::quota::Severity::Error); return tryResult1033 .propagateErr(); }}; |
12147 | |
12148 | DeleteTimerCallback(mDeleteTimer, this); |
12149 | |
12150 | return NS_OK; |
12151 | } |
12152 | |
12153 | RefPtr<BoolPromise> QuotaClient::DoMaintenance() { |
12154 | AssertIsOnBackgroundThread(); |
12155 | MOZ_ASSERT(!IsShuttingDownOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsShuttingDownOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsShuttingDownOnBackgroundThread ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!IsShuttingDownOnBackgroundThread()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12155); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsShuttingDownOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 12155; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12156 | |
12157 | if (!mBackgroundThread) { |
12158 | mBackgroundThread = GetCurrentSerialEventTarget(); |
12159 | } |
12160 | |
12161 | auto maintenance = MakeRefPtr<Maintenance>(this); |
12162 | |
12163 | mMaintenanceQueue.AppendElement(maintenance); |
12164 | ProcessMaintenanceQueue(); |
12165 | |
12166 | return maintenance->OnResults(); |
12167 | } |
12168 | |
12169 | nsThreadPool* QuotaClient::GetOrCreateThreadPool() { |
12170 | AssertIsOnBackgroundThread(); |
12171 | MOZ_ASSERT(!IsShuttingDownOnBackgroundThread())do { static_assert( mozilla::detail::AssertionConditionType< decltype(!IsShuttingDownOnBackgroundThread())>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(!IsShuttingDownOnBackgroundThread ()))), 0))) { do { } while (false); MOZ_ReportAssertionFailure ("!IsShuttingDownOnBackgroundThread()", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12171); AnnotateMozCrashReason("MOZ_ASSERT" "(" "!IsShuttingDownOnBackgroundThread()" ")"); do { *((volatile int*)__null) = 12171; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12172 | |
12173 | if (!mMaintenanceThreadPool) { |
12174 | RefPtr<nsThreadPool> threadPool = new nsThreadPool(); |
12175 | |
12176 | // PR_GetNumberOfProcessors() can return -1 on error, so make sure we |
12177 | // don't set some huge number here. We add 2 in case some threads block on |
12178 | // the disk I/O. |
12179 | const uint32_t threadCount = |
12180 | std::max(int32_t(PR_GetNumberOfProcessors()), int32_t(1)) + 2; |
12181 | |
12182 | MOZ_ALWAYS_SUCCEEDS(threadPool->SetThreadLimit(threadCount))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetThreadLimit(threadCount))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(threadPool->SetThreadLimit(threadCount))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12182); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetThreadLimit(threadCount))" ")"); do { *((volatile int*)__null) = 12182; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
12183 | |
12184 | // Don't keep more than one idle thread. |
12185 | MOZ_ALWAYS_SUCCEEDS(threadPool->SetIdleThreadLimit(1))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadLimit(1))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(threadPool->SetIdleThreadLimit(1))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12185); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadLimit(1))" ")"); do { *((volatile int*)__null) = 12185; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
12186 | |
12187 | // Don't keep idle threads alive very long. |
12188 | MOZ_ALWAYS_SUCCEEDS(do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadMaximumTimeout(5 * 1000L))), 1)) )), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(5 * 1000L))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12189); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(5 * 1000L))" ")"); do { *((volatile int*)__null) = 12189; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false) |
12189 | threadPool->SetIdleThreadMaximumTimeout(5 * PR_MSEC_PER_SEC))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetIdleThreadMaximumTimeout(5 * 1000L))), 1)) )), 1))) { } else { do { do { } while (false); MOZ_ReportCrash ("" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(5 * 1000L))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12189); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetIdleThreadMaximumTimeout(5 * 1000L))" ")"); do { *((volatile int*)__null) = 12189; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
12190 | |
12191 | MOZ_ALWAYS_SUCCEEDS(threadPool->SetName("IndexedDB Mnt"_ns))do { if ((__builtin_expect(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl (threadPool->SetName("IndexedDB Mnt"_ns))), 1)))), 1))) { } else { do { do { } while (false); MOZ_ReportCrash("" "NS_SUCCEEDED(threadPool->SetName(\"IndexedDB Mnt\"_ns))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12191); AnnotateMozCrashReason("MOZ_CRASH(" "NS_SUCCEEDED(threadPool->SetName(\"IndexedDB Mnt\"_ns))" ")"); do { *((volatile int*)__null) = 12191; __attribute__(( nomerge)) ::abort(); } while (false); } while (false); } } while (false); |
12192 | |
12193 | mMaintenanceThreadPool = std::move(threadPool); |
12194 | } |
12195 | |
12196 | return mMaintenanceThreadPool; |
12197 | } |
12198 | |
12199 | mozilla::dom::quota::Client::Type QuotaClient::GetType() { |
12200 | return QuotaClient::IDB; |
12201 | } |
12202 | |
12203 | nsresult QuotaClient::UpgradeStorageFrom1_0To2_0(nsIFile* aDirectory) { |
12204 | AssertIsOnIOThread(); |
12205 | MOZ_ASSERT(aDirectory)do { static_assert( mozilla::detail::AssertionConditionType< decltype(aDirectory)>::isValid, "invalid assertion condition" ); if ((__builtin_expect(!!(!(!!(aDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("aDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12205); AnnotateMozCrashReason("MOZ_ASSERT" "(" "aDirectory" ")"); do { *((volatile int*)__null) = 12205; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); |
12206 | |
12207 | QM_TRY_INSPECT((const auto& [subdirsToProcess, databaseFilenames]),auto tryResult1034 = (GetDatabaseFilenames(*aDirectory, AtomicBool {false})); if ((__builtin_expect(!!(tryResult1034.isErr()), 0 ))) { mozilla::dom::quota::HandleError("GetDatabaseFilenames(*aDirectory, AtomicBool{false})" , tryResult1034.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12209, mozilla::dom::quota::Severity::Error); return tryResult1034 .propagateErr(); } const auto& [subdirsToProcess, databaseFilenames ] = tryResult1034.inspect(); |
12208 | GetDatabaseFilenames(*aDirectory,auto tryResult1034 = (GetDatabaseFilenames(*aDirectory, AtomicBool {false})); if ((__builtin_expect(!!(tryResult1034.isErr()), 0 ))) { mozilla::dom::quota::HandleError("GetDatabaseFilenames(*aDirectory, AtomicBool{false})" , tryResult1034.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12209, mozilla::dom::quota::Severity::Error); return tryResult1034 .propagateErr(); } const auto& [subdirsToProcess, databaseFilenames ] = tryResult1034.inspect(); |
12209 | /* aCanceled */ AtomicBool{false}))auto tryResult1034 = (GetDatabaseFilenames(*aDirectory, AtomicBool {false})); if ((__builtin_expect(!!(tryResult1034.isErr()), 0 ))) { mozilla::dom::quota::HandleError("GetDatabaseFilenames(*aDirectory, AtomicBool{false})" , tryResult1034.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12209, mozilla::dom::quota::Severity::Error); return tryResult1034 .propagateErr(); } const auto& [subdirsToProcess, databaseFilenames ] = tryResult1034.inspect();; |
12210 | |
12211 | QM_TRY(CollectEachInRange({auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12212 | subdirsToProcess,{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12213 | [&databaseFilenames = databaseFilenames,{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12214 | aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> {{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12215 | // If the directory has the correct suffix then it should exist in{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12216 | // databaseFilenames.{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12217 | nsDependentSubstring subdirNameBase;{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12218 | if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix,{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend (*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038 .isErr()), 0))) { mozilla::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirName)" , tryResult1038.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12252, mozilla::dom::quota::Severity::Error); return tryResult1038 .propagateErr(); } const auto& subdir = tryResult1038.inspect ();; DebugOnly<bool> isDirectory; do { static_assert( mozilla ::detail::AssertionConditionType<decltype(((bool)(__builtin_expect (!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory)) ), 1))))>::isValid, "invalid assertion condition"); if ((__builtin_expect (!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir-> IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12255); AnnotateMozCrashReason("MOZ_ASSERT" "(" "((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))" ")"); do { *((volatile int*)__null) = 12255; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype (isDirectory)>::isValid, "invalid assertion condition"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure("isDirectory", "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12256); AnnotateMozCrashReason("MOZ_ASSERT" "(" "isDirectory" ")"); do { *((volatile int*)__null) = 12256; __attribute__(( nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix )); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla ::dom::quota::HandleError("CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)" , tryResult1039.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12260, mozilla::dom::quota::Severity::Error); return tryResult1039 .propagateErr(); } const auto& subdirWithSuffix = tryResult1039 .inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember ( (subdirWithSuffix), &::mozilla::detail::DerefedType< decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect (!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError ("::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)" , tryResult1040.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12263, mozilla::dom::quota::Severity::Error); return tryResult1040 .propagateErr(); } const bool& exists = tryResult1040.inspect ();; if (exists) { do { nsPrintfCString s("Deleting old %s files directory!" , NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB ::ReportInternalError("/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr , "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12267); } while (0); {auto tryResult1041 = (ToResult(subdir ->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect (!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError ("ToResult(subdir->Remove( true))", tryResult1041.inspectErr (), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12269, mozilla::dom::quota::Severity::Error); return tryResult1041 .propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult (subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert (std::is_empty_v<typename decltype(tryResult1042)::ok_type >); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError("ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))" , tryResult1042.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12275, mozilla::dom::quota::Severity::Error); return tryResult1042 .propagateErr(); }}; return Ok{}; })); static_assert(std::is_empty_v <typename decltype(tryResult1043)::ok_type>); if ((__builtin_expect (!!(tryResult1043.isErr()), 0))) { mozilla::dom::quota::HandleError ("CollectEachInRange( subdirsToProcess, [&databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName, kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert(std::is_empty_v<typename decltype(tryResult1035)::ok_type>); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameBase))\", tryResult1035.unwrapErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok{}; } auto tryResult1037 = (([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect(!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota::HandleError(\"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\\\".\\\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, \\\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\\\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \\\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\\\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())\", tryTempError, Ok{}); } const auto& subdirNameWithSuffix = tryResult1037.inspect();; auto tryResult1038 = (CloneFileAndAppend(*aDirectory, subdirName)); if ((__builtin_expect(!!(tryResult1038.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirName)\", tryResult1038.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12252, mozilla::dom::quota::Severity::Error); return tryResult1038.propagateErr(); } const auto& subdir = tryResult1038.inspect();; DebugOnly<bool> isDirectory; do { static_assert( mozilla::detail::AssertionConditionType<decltype(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1))))>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12255); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"((bool)(__builtin_expect(!!(!NS_FAILED_impl(subdir->IsDirectory(&isDirectory))), 1)))\" \")\"); do { *((volatile int*)__null) = 12255; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); do { static_assert( mozilla::detail::AssertionConditionType<decltype(isDirectory)>::isValid, \"invalid assertion condition\"); if ((__builtin_expect(!!(!(!!(isDirectory))), 0))) { do { } while (false); MOZ_ReportAssertionFailure(\"isDirectory\", \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12256); AnnotateMozCrashReason(\"MOZ_ASSERT\" \"(\" \"isDirectory\" \")\"); do { *((volatile int*)__null) = 12256; __attribute__((nomerge)) ::abort(); } while (false); } } while (false); auto tryResult1039 = (CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)); if ((__builtin_expect(!!(tryResult1039.isErr()), 0))) { mozilla::dom::quota::HandleError(\"CloneFileAndAppend(*aDirectory, subdirNameWithSuffix)\", tryResult1039.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12260, mozilla::dom::quota::Severity::Error); return tryResult1039.propagateErr(); } const auto& subdirWithSuffix = tryResult1039.inspect();; auto tryResult1040 = (::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)); if ((__builtin_expect(!!(tryResult1040.isErr()), 0))) { mozilla::dom::quota::HandleError(\"::mozilla::ToResultInvokeMember( (subdirWithSuffix), &::mozilla::detail::DerefedType<decltype(subdirWithSuffix)>::Exists)\", tryResult1040.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12263, mozilla::dom::quota::Severity::Error); return tryResult1040.propagateErr(); } const bool& exists = tryResult1040.inspect();; if (exists) { do { nsPrintfCString s(\"Deleting old %s files directory!\", NS_ConvertUTF16toUTF8(subdirName).get()); mozilla::dom::indexedDB::ReportInternalError(\"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267, s.get()); NS_DebugBreak(NS_DEBUG_WARNING, s.get(), nullptr, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12267); } while (0); {auto tryResult1041 = (ToResult(subdir->Remove( true))); static_assert(std::is_empty_v<typename decltype(tryResult1041)::ok_type>); if ((__builtin_expect(!!(tryResult1041.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->Remove( true))\", tryResult1041.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12269, mozilla::dom::quota::Severity::Error); return tryResult1041.propagateErr(); }}; return Ok{}; } {auto tryResult1042 = (ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))); static_assert(std::is_empty_v<typename decltype(tryResult1042)::ok_type>); if ((__builtin_expect(!!(tryResult1042.isErr()), 0))) { mozilla::dom::quota::HandleError(\"ToResult(subdir->RenameTo(nullptr, subdirNameWithSuffix))\", tryResult1042.inspectErr(), \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12275, mozilla::dom::quota::Severity::Error); return tryResult1042.propagateErr(); }}; return Ok{}; })" , tryResult1043.inspectErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12278, mozilla::dom::quota::Severity::Error); return tryResult1043 .propagateErr(); }} |
12219 | subdirNameBase)) {{auto tryResult1043 = (CollectEachInRange( subdirsToProcess, [ &databaseFilenames = databaseFilenames, aDirectory](const nsAString& subdirName) -> Result<Ok, nsresult> { nsDependentSubstring subdirNameBase; if (GetFilenameBase(subdirName , kFileManagerDirectoryNameSuffix, subdirNameBase)) { {auto tryResult1035 = (OkIf(databaseFilenames.Contains(subdirNameBase))); static_assert (std::is_empty_v<typename decltype(tryResult1035)::ok_type >); if ((__builtin_expect(!!(tryResult1035.isErr()), 0))) { mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameBase))" , tryResult1035.unwrapErr(), "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12220, mozilla::dom::quota::Severity::Warning); }}; return Ok {}; } auto tryResult1037 = (([&databaseFilenames, &subdirName ]() -> Result<nsAutoString, NotOk> { if (databaseFilenames .Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix }; } const nsAutoString subdirNameWithDot = subdirName + u"."_ns ; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot ))); static_assert(std::is_empty_v<typename decltype(tryResult1036 )::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr ()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036 .unwrapErr(); mozilla::dom::quota::HandleError("OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "OkIf(databaseFilenames.Contains(subdirNameWithDot))" , tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())); if ((__builtin_expect (!!(tryResult1037.isErr()), 0))) { auto tryTempError __attribute__ ((__unused__)) = tryResult1037.unwrapErr(); mozilla::dom::quota ::HandleError("([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, \"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, Err(NotOk{})); }}; return nsAutoString{subdirNameWithDot + kFileManagerDirectoryNameSuffix}; }())" , tryTempError, "/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp" , 12247, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __func__; return mozilla::dom::quota::HandleCustomRetVal(func, "([&databaseFilenames, &subdirName]() -> Result<nsAutoString, NotOk> { if (databaseFilenames.Contains(subdirName)) { return nsAutoString{subdirName + kFileManagerDirectoryNameSuffix}; } const nsAutoString subdirNameWithDot = subdirName + u\".\"_ns; {auto tryResult1036 = (OkIf(databaseFilenames.Contains(subdirNameWithDot))); static_assert(std::is_empty_v<typename decltype(tryResult1036)::ok_type>); if ((__builtin_expect(!!(tryResult1036.isErr()), 0))) { auto tryTempError __attribute__((__unused__)) = tryResult1036.unwrapErr(); mozilla::dom::quota::HandleError(\"OkIf(databaseFilenames.Contains(subdirNameWithDot))\", tryTempError, \"/var/lib/jenkins/workspace/firefox-scan-build/dom/indexedDB/ActorsParent.cpp\", 12242, mozilla::dom::quota::Severity::Error); constexpr const auto& func __attribute__((__unused__)) = __f |