evas: remove unused variable in evas_tangent_space_get.
authorperepelits.m <perepelits.m@samsung.com>
Mon, 21 Sep 2015 21:19:57 +0000 (23:19 +0200)
committerCedric BAIL <cedric@osg.samsung.com>
Mon, 21 Sep 2015 21:20:02 +0000 (23:20 +0200)
Summary:
Firstly it was the main point of in CID1323089 from Coverity, but this variable is unused. So I've deleted it.

CID1323089

Reviewers: raster, Hermet, cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D3067

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
src/lib/evas/include/evas_3d_utils.h

index 8591d97..ed1e91f 100644 (file)
@@ -2829,14 +2829,6 @@ evas_tangent_space_get(float *data, float *tex_data, float *normal_data, unsigne
         return;
      }
 
-   unsigned short int *tmp_index = (unsigned short int*) malloc((vertex_count) * sizeof(unsigned short int));
-
-   if (tmp_index == NULL)
-     {
-        ERR("Failed to allocate memory %d %s", __LINE__, __FILE__);
-        return;
-     }
-
    float *tmp_tangent = (float*) malloc((3 * vertex_count) * sizeof(float));
    if (tmp_tangent == NULL)
      {
@@ -2934,7 +2926,6 @@ evas_tangent_space_get(float *data, float *tex_data, float *normal_data, unsigne
 
 
    memcpy(*tangent, tmp_tangent, (3 * vertex_count) * sizeof(float));
-   free(tmp_index);
    free(tmp_tangent);
 
    return;