content/canvas/crashtests/553938-1.html

Thu, 15 Jan 2015 21:03:48 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 21:03:48 +0100
branch
TOR_BUG_9701
changeset 11
deefc01c0e14
permissions
-rw-r--r--

Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)

     1 <!doctype html>
     2 <html>
     3   <head>
     4     <meta http-equiv="content-type" content="text/html; charset=UTF-8">
     5     <title>ImageData Crash Test</title>
     6   </head>
     7   <body onload="crash();">
     8     <canvas id="c" width="10" height="10"></canvas>
     9     <script>
    10       function crash() {
    11         var canvas = document.getElementById('c');
    12         var ctx = canvas.getContext('2d');
    13         var imgData = {data: new Array(10*10*4), width: 10, height: 10};
    15         imgData[0] = 0;
    16         ctx.putImageData(imgData, 0, 0);
    17       }
    18     </script>
    19   </body>
    20 </html>

mercurial