# HG changeset patch # User Mark Doliner # Date 1250118827 0 # Node ID de7f6fd04298e8ceea581652f3254b4bd46abcf4 # Parent 359800ae7d17c24e0dad6e30ca3171940fca58c0 Move this check inside the else condition. The other half of the if statement guarrantees that slpmsg will be non-NULL, this is a very tiny optimization, but it's also cleaner diff -r 359800ae7d17 -r de7f6fd04298 libpurple/protocols/msn/slplink.c --- a/libpurple/protocols/msn/slplink.c Wed Aug 12 10:04:54 2009 +0000 +++ b/libpurple/protocols/msn/slplink.c Wed Aug 12 23:13:47 2009 +0000 @@ -502,7 +502,6 @@ g_return_if_reached(); } - slpmsg = NULL; data = msn_message_get_bin_data(msg, &len); /* @@ -566,13 +565,12 @@ else { slpmsg = msn_slplink_message_find(slplink, msg->msnslp_header.session_id, msg->msnslp_header.id); - } - - if (slpmsg == NULL) - { - /* Probably the transfer was canceled */ - purple_debug_error("msn", "Couldn't find slpmsg\n"); - return; + if (slpmsg == NULL) + { + /* Probably the transfer was canceled */ + purple_debug_error("msn", "Couldn't find slpmsg\n"); + return; + } } if (slpmsg->fp)