diff options
author | George Hazan <george.hazan@gmail.com> | 2014-07-13 16:54:01 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2014-07-13 16:54:01 +0000 |
commit | 01112f344f8e764043a306bc641876cf4c13db38 (patch) | |
tree | 3624df97d6986433a142893809d52f8ae451aad4 /protocols/IcqOscarJ/src/icqosc_svcs.cpp | |
parent | d80bdbbc068a75b592f48921414006d64d0d0268 (diff) |
code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@9788 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/IcqOscarJ/src/icqosc_svcs.cpp')
-rw-r--r-- | protocols/IcqOscarJ/src/icqosc_svcs.cpp | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/protocols/IcqOscarJ/src/icqosc_svcs.cpp b/protocols/IcqOscarJ/src/icqosc_svcs.cpp index c5060ab1e4..df568a5b30 100644 --- a/protocols/IcqOscarJ/src/icqosc_svcs.cpp +++ b/protocols/IcqOscarJ/src/icqosc_svcs.cpp @@ -656,18 +656,15 @@ MCONTACT CIcqProto::AddToListByUID(const char *szUID, DWORD dwFlags) {
int bAdded;
MCONTACT hContact = HContactFromUID(0, szUID, &bAdded);
- if (hContact)
- {
- if (!(dwFlags & PALF_TEMPORARY) && db_get_b(hContact, "CList", "NotOnList", 0))
- {
- setContactHidden(hContact, 0);
- db_unset(hContact, "CList", "NotOnList");
- }
-
- return hContact; // Success
+ if (hContact == 0)
+ return 0; // Failure
+
+ if (!(dwFlags & PALF_TEMPORARY) && db_get_b(hContact, "CList", "NotOnList", 0)) {
+ setContactHidden(hContact, 0);
+ db_unset(hContact, "CList", "NotOnList");
}
- return NULL; // Failure
+ return hContact; // Success
}
|