OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) | 2 Copyright (C) 1998 Lars Knoll (knoll@mpi-hd.mpg.de) |
3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) | 3 Copyright (C) 2001 Dirk Mueller (mueller@kde.org) |
4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) | 4 Copyright (C) 2002 Waldo Bastian (bastian@kde.org) |
5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 Copyright (C) 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All
rights reserved. | 6 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All
rights reserved. |
7 | 7 |
8 This library is free software; you can redistribute it and/or | 8 This library is free software; you can redistribute it and/or |
9 modify it under the terms of the GNU Library General Public | 9 modify it under the terms of the GNU Library General Public |
10 License as published by the Free Software Foundation; either | 10 License as published by the Free Software Foundation; either |
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
390 | 390 |
391 void Resource::error(const ResourceError& error) | 391 void Resource::error(const ResourceError& error) |
392 { | 392 { |
393 ASSERT(!error.isNull()); | 393 ASSERT(!error.isNull()); |
394 m_error = error; | 394 m_error = error; |
395 m_isRevalidating = false; | 395 m_isRevalidating = false; |
396 | 396 |
397 if (m_error.isCancellation() || !isPreloaded()) | 397 if (m_error.isCancellation() || !isPreloaded()) |
398 memoryCache()->remove(this); | 398 memoryCache()->remove(this); |
399 | 399 |
400 if (!errorOccurred()) | 400 setStatus(LoadError); |
401 setStatus(LoadError); | |
402 ASSERT(errorOccurred()); | 401 ASSERT(errorOccurred()); |
403 m_data.clear(); | 402 m_data.clear(); |
404 m_loader = nullptr; | 403 m_loader = nullptr; |
405 checkNotify(); | 404 checkNotify(); |
406 markClientsAndObserversFinished(); | 405 markClientsAndObserversFinished(); |
407 } | 406 } |
408 | 407 |
409 void Resource::finish(double loadFinishTime) | 408 void Resource::finish(double loadFinishTime) |
410 { | 409 { |
411 DCHECK(!m_isRevalidating); | 410 DCHECK(!m_isRevalidating); |
(...skipping 689 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1101 case Resource::TextTrack: | 1100 case Resource::TextTrack: |
1102 case Resource::Media: | 1101 case Resource::Media: |
1103 case Resource::Manifest: | 1102 case Resource::Manifest: |
1104 return false; | 1103 return false; |
1105 } | 1104 } |
1106 ASSERT_NOT_REACHED(); | 1105 ASSERT_NOT_REACHED(); |
1107 return false; | 1106 return false; |
1108 } | 1107 } |
1109 | 1108 |
1110 } // namespace blink | 1109 } // namespace blink |
OLD | NEW |