|   | 
      | 
  
  
      | 
      | 
  
 
     | 
    | 
  
  
     | 
    | 
  
  
    |   | 
      | 
  
  
    | 
         
xen-changelog
[Xen-changelog] [xen-unstable] Fix allocation of the	error_description f
 
# HG changeset patch
# User Ewan Mellor <ewan@xxxxxxxxxxxxx>
# Date 1172016246 0
# Node ID 2414007d92ba0686ca22bff58ef691c34a14050b
# Parent  df08fe145d24d587151a0551fa292ad6b8b481a5
Fix allocation of the error_description fields.
Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx>
---
 tools/libxen/src/xen_common.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
diff -r df08fe145d24 -r 2414007d92ba tools/libxen/src/xen_common.c
--- a/tools/libxen/src/xen_common.c     Tue Feb 20 23:59:13 2007 +0000
+++ b/tools/libxen/src/xen_common.c     Wed Feb 21 00:04:06 2007 +0000
@@ -989,10 +989,10 @@ static void parse_failure(xen_session *s
         char **c = (char **)error_descriptions->contents;
         int n = error_descriptions->size;
 
-        char **strings = malloc(3 * sizeof(char *));
+        char **strings = malloc(n * sizeof(char *));
         for (int i = 0; i < n; i++)
         {
-            strings[i] = xen_strdup_(c[i]);
+            strings[i] = c[i];
         }
 
         session->error_description_count = n;
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
 |   
 
| <Prev in Thread] | 
Current Thread | 
[Next in Thread> |  
- [Xen-changelog] [xen-unstable] Fix allocation of the	error_description fields.,
Xen patchbot-unstable <=
  
 |  
  
 | 
    | 
  
  
    |   | 
    |