hwc: fix compilation issue on backport of Ieb91b70 [DO NOT MERGE]

Fixes compilation issue for backport of the following patch:

	commit 6e69a5311599cc90b654031e93b272017169f1e0
	Author: Arun Kumar K.R <akumarkr@codeaurora.org>
	Date:   Wed Jun 5 17:21:38 2013 -0700

	hwc: Fix to avoid heap corruption

Bug: 24163261

Change-Id: I4d8d02bf75e7914c2c5c4f9c2b4ea047481b302c
Signed-off-by: Patrick Tjin <pattjin@google.com>
diff --git a/msm8960/libhwcomposer/hwc_mdpcomp.cpp b/msm8960/libhwcomposer/hwc_mdpcomp.cpp
index 744fc09..6fcfba9 100644
--- a/msm8960/libhwcomposer/hwc_mdpcomp.cpp
+++ b/msm8960/libhwcomposer/hwc_mdpcomp.cpp
@@ -344,9 +344,8 @@
 }
 
 bool MDPComp::isFrameDoable(hwc_context_t *ctx) {
-    int numAppLayers = ctx->listStats[mDpy].numAppLayers;
-    bool ret = true;
     const int numAppLayers = ctx->listStats[mDpy].numAppLayers;
+    bool ret = true;
 
     if(!isEnabled()) {
         ALOGD_IF(isDebug(),"%s: MDP Comp. not enabled.", __FUNCTION__);