]> git.ipfire.org Git - thirdparty/gnutls.git/commitdiff
gnutls_srtp_get_keys() returns the size of the key material
authorNikos Mavrogiannopoulos <nmav@gnutls.org>
Fri, 2 Nov 2012 15:08:49 +0000 (16:08 +0100)
committerNikos Mavrogiannopoulos <nmav@gnutls.org>
Fri, 2 Nov 2012 15:08:49 +0000 (16:08 +0100)
lib/ext/srtp.c

index e9899112aa7d0c551b9bfe609243d7a4fb8306d1..35e99facfc82d13b9ca2d107b61b1cac3b573c75 100644 (file)
@@ -451,8 +451,9 @@ gnutls_srtp_set_profile_direct (gnutls_session_t session,
  * and @server_salt are convenience datums that point inside the key material. The may
  * be %NULL.
  *
- * Returns: %GNUTLS_E_SHORT_MEMORY_BUFFER if the buffer given is not sufficient, 
- * %GNUTLS_E_SUCCESS on success, or an error code.
+ * Returns: On success the size of the key material is returned,
+ * %GNUTLS_E_SHORT_MEMORY_BUFFER if the buffer given is not sufficient, 
+ * or a negative error code.
  *
  * Since 3.1.4
  **/
@@ -515,7 +516,7 @@ uint8_t *km = key_material;
       server_salt->size = p->salt_length;
     }
 
-  return 0;
+  return msize;
 }
 
 static void