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:
mxPerimeter.OrthogonalPerimeter);mxPerimeter.BackbonePerimeter=function(c,l,x,p){p=parseFloat(l.style[mxConstants.STYLE_STROKEWIDTH]||1)*l.view.scale/2-1;null!=l.style.backboneSize&&(p+=parseFloat(l.style.backboneSize)*l.view.scale/2-1);if("south"==l.style[mxConstants.STYLE_DIRECTION]||"north"==l.style[mxConstants.STYLE_DIRECTION])return x.x<c.getCenterX()&&(p=-1*(p+1)),new mxPoint(c.getCenterX()+p,Math.min(c.y+c.height,Math.max(c.y,x.y)));x.y<c.getCenterY()&&(p=-1*(p+1));return new mxPoint(Math.min(c.x+
c.width,Math.max(c.x,x.x)),c.getCenterY()+p)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxPerimeter.CalloutPerimeter=function(c,l,x,p){return mxPerimeter.RectanglePerimeter(mxUtils.getDirectedBounds(c,new mxRectangle(0,0,0,Math.max(0,Math.min(c.height,parseFloat(mxUtils.getValue(l.style,"size",ja.prototype.size))*l.view.scale))),l.style),l,x,p)};mxStyleRegistry.putValue("calloutPerimeter",mxPerimeter.CalloutPerimeter);mxPerimeter.ParallelogramPerimeter=function(c,