svn rev #24876: trunk/src/lib/gssapi/krb5/

ghudson@MIT.EDU ghudson at MIT.EDU
Tue Apr 12 14:35:31 EDT 2011


http://src.mit.edu/fisheye/changelog/krb5/?cs=24876
Commit By: ghudson
Log Message:
ticket: 6898

In krb5_gss_display_status, correct the sense of the
g_make_string_buffer test, and return GSS_S_FAILURE if it fails.
Reported by snambakam at likewise.com.



Changed Files:
U   trunk/src/lib/gssapi/krb5/disp_status.c
Modified: trunk/src/lib/gssapi/krb5/disp_status.c
===================================================================
--- trunk/src/lib/gssapi/krb5/disp_status.c	2011-04-12 13:36:15 UTC (rev 24875)
+++ trunk/src/lib/gssapi/krb5/disp_status.c	2011-04-12 18:35:31 UTC (rev 24876)
@@ -185,12 +185,13 @@
         }
 
         /* If this fails, there's not much we can do...  */
-        if (g_make_string_buffer(krb5_gss_get_error_message(status_value),
-                                 status_string) != 0)
+        if (!g_make_string_buffer(krb5_gss_get_error_message(status_value),
+                                  status_string)) {
             *minor_status = ENOMEM;
-        else
-            *minor_status = 0;
-        return 0;
+            return(GSS_S_FAILURE);
+        }
+        *minor_status = 0;
+        return(GSS_S_COMPLETE);
     } else {
         *minor_status = 0;
         return(GSS_S_BAD_STATUS);




More information about the cvs-krb5 mailing list