Add parameters validation to glShaderSource() API

According to GLES2.0 Spec., add parameters validataion to
glShaderSource() API.

Change-Id: I5b0e939fd9657ccbb40a13896c8fc74ef02fd085
Signed-off-by: Tina Zhang <tina.zhang@intel.com>
diff --git a/shared/OpenglCodecCommon/GLSharedGroup.cpp b/shared/OpenglCodecCommon/GLSharedGroup.cpp
old mode 100644
new mode 100755
index c7da37a..b079b6d
--- a/shared/OpenglCodecCommon/GLSharedGroup.cpp
+++ b/shared/OpenglCodecCommon/GLSharedGroup.cpp
@@ -240,6 +240,12 @@
     clearObjectMap(m_shaders);
 }
 
+bool GLSharedGroup::isObject(GLuint obj)
+{
+    android::AutoMutex _lock(m_lock);
+    return ((m_shaders.valueFor(obj)!=NULL) || (m_programs.valueFor(obj)!=NULL));
+}
+
 BufferData * GLSharedGroup::getBufferData(GLuint bufferId)
 {
     android::AutoMutex _lock(m_lock);
diff --git a/shared/OpenglCodecCommon/GLSharedGroup.h b/shared/OpenglCodecCommon/GLSharedGroup.h
old mode 100644
new mode 100755
index 61b8f00..6dfcd8f
--- a/shared/OpenglCodecCommon/GLSharedGroup.h
+++ b/shared/OpenglCodecCommon/GLSharedGroup.h
@@ -110,6 +110,7 @@
 public:
     GLSharedGroup();
     ~GLSharedGroup();
+    bool isObject(GLuint obj);
     BufferData * getBufferData(GLuint bufferId);
     void    addBufferData(GLuint bufferId, GLsizeiptr size, void * data);
     void    updateBufferData(GLuint bufferId, GLsizeiptr size, void * data);