forked from ShuriZma/suyu
metal: do not release not existing buffers
This commit is contained in:
parent
e87893ec42
commit
ef8b77c9a3
|
@ -25,7 +25,9 @@ BoundBuffer::BoundBuffer(MTLBuffer_t buffer_, size_t offset_, size_t size_)
|
|||
: buffer{[buffer_ retain]}, offset{offset_}, size{size_} {}
|
||||
|
||||
BoundBuffer::~BoundBuffer() {
|
||||
if (buffer) {
|
||||
[buffer release];
|
||||
}
|
||||
}
|
||||
|
||||
BufferView::BufferView(MTLBuffer_t buffer_, size_t offset_, size_t size_,
|
||||
|
|
Loading…
Reference in New Issue