Language: JavaScript
Label: safe
CWE: CWE-78 \u2014 Improper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.

Code:
u.onreadystatechange=function(){f(u)};u.send("format=xml&filename="+encodeURIComponent(k)+"&data="+encodeURIComponent(d));try{EditorUi.logEvent({category:"GLIFFY-IMPORT-FILE",action:"size_"+file.size})}catch(z){}};EditorUi.prototype.isResampleImageSize=function(d,f){f=null!=f?f:this.resampleThreshold;return d>f};EditorUi.prototype.resizeImage=function(d,f,k,u,z,B,F){z=null!=z?z:this.maxImageSize;var K=Math.max(1,d.width),N=Math.max(1,d.height);if(u&&this.isResampleImageSize(null!=F?F:f.length,B))try{var H=
Math.max(K/z,N/z);if(1<H){var ka=Math.round(K/H),ea=Math.round(N/H),ca=document.createElement("canvas");ca.width=ka;ca.height=ea;ca.getContext("2d").drawImage(d,0,0,ka,ea);var ja=ca.toDataURL();if(ja.length<f.length){var ma=document.createElement("canvas");ma.width=ka;ma.height=ea;var Z=ma.toDataURL();ja!==Z&&(f=ja,K=ka,N=ea)}}}catch(S){}k(f,K,N)};EditorUi.prototype.extractGraphModelFromPng=function(d){return Editor.extractGraphModelFromPng(d)};EditorUi.prototype.loadImage=function(d,f,k){try{var u=