#vulnerable code 
                                public StoredObject setContentType(String contentType) {
        checkForInfo();
        info.setContentType(new ObjectContentType(contentType));
        new ObjectMetadataCommand(
                getAccount(), getClient(), getAccess(), this,
                info.getHeadersIncludingHeader(info.getContentTypeHeader())).call();
        return this;
    } 
                            #location 6 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                                public StoredObject setContentType(String contentType) {
        checkForInfo();
        info.setContentType(new ObjectContentType(contentType));
        commandFactory.createObjectMetadataCommand(
                getAccount(), getClient(), getAccess(), this,
                info.getHeadersIncludingHeader(info.getContentTypeHeader())).call();
        return this;
    }