gss-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CVS gss/lib


From: gss-commit
Subject: CVS gss/lib
Date: Thu, 14 Oct 2004 22:47:52 +0200

Update of /home/cvs/gss/lib
In directory dopio:/tmp/cvs-serv3847

Modified Files:
        name.c 
Log Message:
(gss_import_name, gss_duplicate_name): Don't clone OID.


--- /home/cvs/gss/lib/name.c    2004/10/05 19:15:21     1.32
+++ /home/cvs/gss/lib/name.c    2004/10/14 20:47:51     1.33
@@ -77,17 +77,7 @@
   (*output_name)->value = xmemdup (input_name_buffer->value,
                                  input_name_buffer->length);
 
-  if (input_name_type)
-    {
-      /* FIXME: perhaps this should only be this:
-        (*output_name)->type = input_name_type; */
-      major_stat = gss_duplicate_oid (minor_status, input_name_type,
-                                     &(*output_name)->type);
-      if (GSS_ERROR (major_stat))
-       return major_stat;
-    }
-  else
-    (*output_name)->type = GSS_C_NO_OID;
+  (*output_name)->type = input_name_type;
 
   if (minor_status)
     *minor_status = 0;
@@ -557,7 +547,6 @@
                    const gss_name_t src_name, gss_name_t * dest_name)
 {
   OM_uint32 maj_stat;
-  gss_OID tmp;
 
   if (src_name == GSS_C_NO_NAME)
     {
@@ -573,14 +562,8 @@
       return GSS_S_FAILURE | GSS_S_CALL_INACCESSIBLE_WRITE;
     }
 
-  /* FIXME: I'm not sure we should duplicate the OID.  Perhaps just
-     copy the pointer.  Who will deallocate this? */
-  maj_stat = gss_duplicate_oid (minor_status, src_name->type, &tmp);
-  if (GSS_ERROR (maj_stat))
-    return maj_stat;
-
   *dest_name = xmalloc (sizeof (**dest_name));
-  (*dest_name)->type = tmp;
+  (*dest_name)->type = src_name->type;
   (*dest_name)->length = src_name->length;
   (*dest_name)->value = xmalloc (src_name->length + 1);
   memcpy ((*dest_name)->value, src_name->value, src_name->length);





reply via email to

[Prev in Thread] Current Thread [Next in Thread]