Tue, 26 Sep 2006 17:38:09 +0000
[gaim-migrate @ 17356]
After the comments on gaim-devel about 'bad' code, I looked into the function referenced. It appears that yahoo_buddy_icon_upload_connected() is only called as a callback. It's registered from yahoo_buddy_icon_upload(). yahoo_buddy_icon_upload() is only called twice. In neither case can a NULL make it down to yahoo_buddy_icon_upload_connected(). As this is an exceptional case rather than a normal one, a g_return_if_fail() is more appropriate. That adds logging, makes the intent clearer, and will help the Coverity software detect violations of this assumption.
| 2086 | 1 | /* |
| 2 | * Copyright 1986, 1987, 1988 by MIT Information Systems and | |
| 3 | * the MIT Student Information Processing Board. | |
| 4 | * | |
| 5 | * For copyright info, see mit-sipb-copyright.h. | |
| 6 | */ | |
| 7 | ||
| 8 | #include <sysdep.h> | |
| 9 | ||
| 10 | extern struct et_list * _et_list; | |
| 11 |