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:
Graph.prototype.initLayoutManager=function(){this.layoutManager=new mxLayoutManager(this);this.layoutManager.hasLayout=function(a){return null!=this.graph.getCellStyle(a).childLayout};this.layoutManager.getLayout=function(a,b){var f=this.graph.model.getParent(a);if(!this.graph.isCellCollapsed(a)&&(b!=mxEvent.BEGIN_UPDATE||this.hasLayout(f,b))){a=this.graph.getCellStyle(a);if("stackLayout"==a.childLayout)return b=new mxStackLayout(this.graph,!0),b.resizeParentMax="1"==mxUtils.getValue(a,"resizeParentMax",