title: iOS 7 producing random error: JPEG Not a JPEG file: starts with 0x00 0x00
body: <p>I have an application which is a wrapper for a digital magazine that is created in html5 / jpg format.</p>
  
  <p>The book is displayed via UIWebView, the book contents is stored locally on the device.</p>
  
  <p>While this works fine on IOS 6 devices and IOS 7 Simulator, on IOS 7 devices i randomly get following errors:</p>
  
  <pre><code>&lt;Error&gt;: ImageIO: JPEG Not a JPEG file: starts with 0x00 0x00
  &lt;Error&gt;: ImageIO: JPEG Not a JPEG file: starts with 0x00 0x00
  &lt;Error&gt;: ImageIO: JPEG Not a JPEG file: starts with 0x00 0x00
  </code></pre>
  
  <p>and a bit later a crash:</p>
  
  <pre><code> &lt;Error&gt;: *** Terminating app due to uncaught exception 'NSRangeException', reason: '***     
  -[WebCoreSharedBufferData getBytes:range(inlove): range {0, 4000} exceeds data length 0'
  </code></pre>
  
  <p>When moving thru the pages in the book, the same pages (images) are sometimes displayed correctly and sometimes not at all.</p>
  
  <p>I doubt its a performance issue, because this is happening on IPad 2 as well as iPad 4.</p>
  
  <p>NOTE: the html app is not the krpano viewer. </p>