ecore: Ecore_Con_Eet reset size when receiving an Eet_Data.
authorCedric BAIL <cedric.bail@free.fr>
Sat, 8 Sep 2012 16:12:34 +0000 (16:12 +0000)
committerCedric BAIL <cedric.bail@free.fr>
Sat, 8 Sep 2012 16:12:34 +0000 (16:12 +0000)
SVN revision: 76345

legacy/ecore/src/lib/ecore_con/ecore_con_eet.c

index c420c2c..d9999b8 100644 (file)
@@ -268,7 +268,6 @@ static void
 _ecore_con_eet_data(Ecore_Con_Reply *n, void *data, unsigned int size)
 {
    /* FIXME: Enforce detection of attack and kill connection on that case */
-
    if (n->buffer)
      {
         if (n->buffer_current + size > n->buffer_length)
@@ -320,9 +319,13 @@ _ecore_con_eet_data(Ecore_Con_Reply *n, void *data, unsigned int size)
                             return ;
                          }
                        _ecore_con_eet_reply_cleanup(n);
+
+                       size += protocol_length + section_length;
                     }
                }
           }
+
+        size += 4 * sizeof (unsigned int) + 2;
      }
 
    eet_connection_received(n->econn, data, size);