mirror of
https://github.com/edubart/otclient.git
synced 2025-12-14 20:59:47 +01:00
Get rid of trailing whitespace.
Commit generated by command:
find -type f ! -path '*.git*' ! -path '*.png' ! -path '*.ico' ! -path \
'*.ogg' | xargs -I '{}' sed -i '{}' -e 's/\t*$//g' -e 's/ *$//g'
This commit is contained in:
@@ -66,7 +66,7 @@ public:
|
||||
typedef T element_type;
|
||||
|
||||
shared_object_ptr(): px(nullptr) { }
|
||||
shared_object_ptr(T* p, bool add_ref = true) : px(p) {
|
||||
shared_object_ptr(T* p, bool add_ref = true) : px(p) {
|
||||
static_assert(std::is_base_of<shared_object, T>::value, "classes using shared_object_ptr must be a derived of stdext::shared_object");
|
||||
if(px != nullptr && add_ref)
|
||||
this->add_ref();
|
||||
|
||||
@@ -50,7 +50,7 @@ public:
|
||||
~shared_base() { }
|
||||
|
||||
void add_ref() { ++refs; }
|
||||
void dec_ref() {
|
||||
void dec_ref() {
|
||||
if(--refs == 0) {
|
||||
delete px;
|
||||
px = nullptr;
|
||||
@@ -116,7 +116,7 @@ public:
|
||||
T& operator*() const { assert(base != nullptr); return *base->get(); }
|
||||
T* operator->() const { assert(base != nullptr); return base->get(); }
|
||||
|
||||
template<class U>
|
||||
template<class U>
|
||||
shared_ptr& operator=(shared_ptr<U> const& rhs) { shared_ptr(rhs).swap(*this); return *this; }
|
||||
shared_ptr& operator=(shared_ptr const& rhs) { shared_ptr(rhs).swap(*this); return *this; }
|
||||
shared_ptr& operator=(T* rhs) { shared_ptr(rhs).swap(*this); return *this; }
|
||||
|
||||
Reference in New Issue
Block a user