summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBenjamin Franzke <benjaminfranzke@googlemail.com>2011-09-24 15:35:56 +0200
committerBenjamin Franzke <benjaminfranzke@googlemail.com>2011-09-25 12:54:55 +0200
commit2a5a764ca0f650bb188a2da43d69cb4db6855337 (patch)
treebeda32c95bdaa896514e7787b7ecd52a15f2c113 /src
parent98bc17525c76803e5784560ed8c2e0e276d83444 (diff)
downloadcmumble-2a5a764ca0f650bb188a2da43d69cb4db6855337.tar.gz
cmumble-2a5a764ca0f650bb188a2da43d69cb4db6855337.tar.bz2
cmumble-2a5a764ca0f650bb188a2da43d69cb4db6855337.zip
Do not assign and check in if
Diffstat (limited to 'src')
-rw-r--r--src/cmumble.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/cmumble.c b/src/cmumble.c
index 82af149..f7b7214 100644
--- a/src/cmumble.c
+++ b/src/cmumble.c
@@ -124,13 +124,13 @@ recv_codec_version(MumbleProto__CodecVersion *codec, struct cmumble_context *ctx
codec->alpha, codec->beta, codec->prefer_alpha);
}
-
static void
recv_user_remove(MumbleProto__UserRemove *remove, struct cmumble_context *ctx)
{
struct cmumble_user *user = NULL;
- if ((user = find_user(ctx, remove->session))) {
+ user = find_user(ctx, remove->session);
+ if (user) {
ctx->users = g_list_remove(ctx->users, user);
g_free(user->name);
/* FIXME: destroy playback pipeline */
@@ -143,7 +143,8 @@ recv_user_state(MumbleProto__UserState *state, struct cmumble_context *ctx)
{
struct cmumble_user *user = NULL;
- if ((user = find_user(ctx, state->session))) {
+ user = find_user(ctx, state->session);
+ if (user) {
/* update */
return;
}