Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
wrapper: Pin blob source insted of unnecessarily RC'ing it
The refcounter here makes little sense as the string is only ever referenced by DxcIncludeHandlerWrapper. The count is never artificially inremented to represent implicit referencing from a native DxcBlob. Overall lifetime of the string is not altered: as soon as DxcIncludeHandlerWrapper goes out of scope the underlying string disappears as well. Furthermore, use Pin<> to hold the string at the same location in memory. In particular this Pin instance only gives us access to the deref of `String`, which is `&str` and does not allow destructive operations like resizing or reassignment that could potentially reallocate heap memory (hence moving the pointer).
- Loading branch information