Language: JavaScript
Label: safe
CWE: CWE-400 \u2014 Uncontrolled Resource Consumption
The product does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources.

Code:
c);l&&(q.x<w||q.x>w+y?N.y=q.y:N.x=q.x);return mxUtils.getPerimeterPoint(J,N,q)};mxStyleRegistry.putValue("stepPerimeter",mxPerimeter.StepPerimeter);mxPerimeter.HexagonPerimeter2=function(c,h,q,l){var p="0"!=mxUtils.getValue(h.style,"fixedSize","0"),v=p?I.prototype.fixedSize:I.prototype.size;null!=h&&(v=mxUtils.getValue(h.style,"size",v));p&&(v*=h.view.scale);var w=c.x,J=c.y,y=c.width,Y=c.height,N=c.getCenterX();c=c.getCenterY();h=null!=h?mxUtils.getValue(h.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):
mxConstants.DIRECTION_EAST;h==mxConstants.DIRECTION_NORTH||h==mxConstants.DIRECTION_SOUTH?(p=p?Math.max(0,Math.min(Y,v)):Y*Math.max(0,Math.min(1,v)),J=[new mxPoint(N,J),new mxPoint(w+y,J+p),new mxPoint(w+y,J+Y-p),new mxPoint(N,J+Y),new mxPoint(w,J+Y-p),new mxPoint(w,J+p),new mxPoint(N,J)]):(p=p?Math.max(0,Math.min(y,v)):y*Math.max(0,Math.min(1,v)),J=[new mxPoint(w+p,J),new mxPoint(w+y-p,J),new mxPoint(w+y,c),new mxPoint(w+y-p,J+Y),new mxPoint(w+p,J+Y),new mxPoint(w,c),new mxPoint(w+p,J)]);N=new mxPoint(N,
c);l&&(q.x<w||q.x>w+y?N.y=q.y:N.x=q.x);return mxUtils.getPerimeterPoint(J,N,q)};mxStyleRegistry.putValue("hexagonPerimeter2",mxPerimeter.HexagonPerimeter2);mxUtils.extend(va,mxShape);va.prototype.size=10;va.prototype.paintBackground=function(c,h,q,l,p){var v=parseFloat(mxUtils.getValue(this.style,"size",this.size));c.translate(h,q);c.ellipse((l-v)/2,0,v,v);c.fillAndStroke();c.begin();c.moveTo(l/2,v);c.lineTo(l/2,p);c.end();c.stroke()};mxCellRenderer.registerShape("lollipop",va);mxUtils.extend(Ja,