Bug in current stable release with FileReader - readAsDataUrl()

133 views
Skip to first unread message

rloewy

unread,
Oct 10, 2012, 9:49:13 PM10/10/12
to chromium-...@chromium.org
This code used to work fine for dragged and dropped images from the file system - but now fails with an error  of "failed to load resource blob:chrome-extension:....."

function getImageData(aFile, targetNode, callback) {

    //console.log('get image data ' + aFile );
  $("#droppedImage").css("display", "block");
  var imageReader = new FileReader();
    imageReader.onload = function(e) {
       document.getElementById('droppedImage').onload = function(e) {
           imageWidth = this.width;
           imageHeight = this.height;
           saveFile(aFile, targetNode, callback);
       };
       $("#droppedImage").attr("src", imageReader.result);
    };
    imageReader.readAsDataURL(aFile);
} // getImageData -

Is this a bug in the latest Chrome release or is there a new set of permissions that we need or anything of that sort?

rloewy

unread,
Oct 10, 2012, 9:59:40 PM10/10/12
to chromium-...@chromium.org
Forget it. This code works fine. It seems to be an issue with data from mapped directories from a VMWare machine. Works just fine with normal directories, so it is either a bug in Chrome getting the data from a mapped drive.

FWIW - I tried reading the file from the mapped drive via a web intent that uses a file input control - and the same problem occurs. 

If I copy the file from the mapped drive to a local directory - the same data works fine with drag and drop and with the web-intent, so, definitely Chrome doing something wrong accessing data from this mapped drive. Other mapped drives, like DropBox or SkyDrive seem to work fine, so it is something specific to the VMWare implementation of mapped-drives and Chrome that do not work well together.

VMWare plays nice with Windows, Chrome plays nice with other types of mapped drives - but for this specific combination - it's a no-go.
Reply all
Reply to author
Forward
0 new messages