LLDB mainline
Public Member Functions | List of all members
lldb_private::process_linux::resource_handle::FileDescriptorDeleter Class Reference

Custom deleter for a file descriptor. More...

#include <Perf.h>

Public Member Functions

void operator() (long *ptr)
 Close and free the memory associated with the file descriptor pointer.
 

Detailed Description

Custom deleter for a file descriptor.

This functor type is provided to unique_ptr to properly release the resources associated with the file descriptor at destruction time.

Definition at line 58 of file Perf.h.

Member Function Documentation

◆ operator()()

void resource_handle::FileDescriptorDeleter::operator() ( long *  ptr)

Close and free the memory associated with the file descriptor pointer.

Effectively a no-op if ptr==nullptr or *ptr==-1.

Parameters
[in]ptrPointer to the file descriptor.

Definition at line 69 of file Perf.cpp.


The documentation for this class was generated from the following files: