Hi,

Thanks for the guacamole project.  I've been using it with good success on
a project at work.  I've been developing a Javascript Client to integrate
with MS Windows Virtual Machines.  I used the Javascript API to develop
some file transfer capabilities.  I was unable to get the BlobWriter JS
file to work as currently available here (
https://github.com/apache/guacamole-client/tree/master/guacamole-common-js/src/main/webapp/modules).
I kept getting the following error whenever I'd try to write files to the
VM:

zone.js:1495 Uncaught (in promise) DOMException: Failed to execute
'readAsArrayBuffer' on 'FileReader': The object is already busy reading
Blobs.
    at _global.<computed>.<computed> [as readAsArrayBuffer] (
https://redacted/polyfills.6e39da16eddfecb84434.js:3830:60)
    at readNextChunk (
https://redacted/main.51a4f7c78afe09ae8d5e.js:168269:20)
    at
push../src/app/components/core/desktop/js/BlobWriter.js.redacted.ArrayBufferWriter.sendMoreChunks
[as onack] (https://redacted/main.51a4f7c78afe09ae8d5e.js:168295:17)
    at
push../node_modules/guacamole-common-js/dist/guacamole-common.js.Guacamole.OutputStream.stream.onack
(https://redacted/main.51a4f7c78afe09ae8d5e.js:168396:25)
    at ack (https://redacted/main.51a4f7c78afe09ae8d5e.js:114024:28)
    at
push../node_modules/guacamole-common-js/dist/guacamole-common.js.Guacamole.HTTPTunnel.tunnel.oninstruction
(https://redacted/main.51a4f7c78afe09ae8d5e.js:114685:13)
    at XMLHttpRequest.parseResponse [as
__zone_symbol__ON_PROPERTYreadystatechange] (
https://redacted/main.51a4f7c78afe09ae8d5e.js:123910:40)
    at XMLHttpRequest.wrapFn (
https://redacted/polyfills.6e39da16eddfecb84434.js:3667:39)
    at
ZoneDelegate.push../node_modules/zone.js/dist/zone.js.ZoneDelegate.invokeTask
(https://redacted/polyfills.6e39da16eddfecb84434.js:2758:31)
    at Object.onInvokeTask (
https://redacted/main.51a4f7c78afe09ae8d5e.js:33312:33)

I came up with an easy workaround to this issue, and thought someone might
be interested.  My amended BlobWriter.js is attached.

Thanks,

James Caple

Reply via email to