Date: Wed Mar 19 05:19:12 2008
New Revision: 638811

URL: http://svn.apache.org/viewvc?rev=638811&view=rev
Log:
Axis2/C Hackathon: Improving code

Modified:
    webservices/axis2/trunk/c/axiom/src/attachments/axiom_mime_output.h
    webservices/axis2/trunk/c/axiom/src/attachments/data_handler.c
    webservices/axis2/trunk/c/axiom/src/attachments/mime_body_part.c
    webservices/axis2/trunk/c/axiom/src/attachments/mime_output.c
    webservices/axis2/trunk/c/include/axis2_http_transport.h
    webservices/axis2/trunk/c/src/core/transport/http/common/http_worker.c
    
webservices/axis2/trunk/c/src/core/transport/http/common/simple_http_svr_conn.c
    webservices/axis2/trunk/c/src/core/transport/http/sender/http_sender.c
    
webservices/axis2/trunk/c/src/core/transport/http/sender/libcurl/axis2_libcurl.c

Modified: webservices/axis2/trunk/c/axiom/src/attachments/axiom_mime_output.h
URL: 
http://svn.apache.org/viewvc/webservices/axis2/trunk/c/axiom/src/attachments/axiom_mime_output.h?rev=638811&r1=638810&r2=638811&view=diff
==============================================================================
--- webservices/axis2/trunk/c/axiom/src/attachments/axiom_mime_output.h 
(original)
+++ webservices/axis2/trunk/c/axiom/src/attachments/axiom_mime_output.h Wed Mar 
19 05:19:12 2008
@@ -1,4 +1,3 @@
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one or more
  * contributor license agreements.  See the NOTICE file distributed with
@@ -37,10 +36,7 @@
 {
 #endif
- /* This should be moved to header file later axutil_utils_defines.h*/
-#define axis2_byte_t char
-
-    typedef struct axiom_mime_output axiom_mime_output_t;
+    typedef void axiom_mime_output_t;

Modified: webservices/axis2/trunk/c/axiom/src/attachments/mime_output.c
URL: 
http://svn.apache.org/viewvc/webservices/axis2/trunk/c/axiom/src/attachments/mime_output.c?rev=638811&r1=638810&r2=638811&view=diff
==============================================================================
--- webservices/axis2/trunk/c/axiom/src/attachments/mime_output.c (original)
+++ webservices/axis2/trunk/c/axiom/src/attachments/mime_output.c Wed Mar 19 
05:19:12 2008
@@ -1,4 +1,3 @@
-
 /*
  * Licensed to the Apache Software Foundation (ASF) under one or more
  * contributor license agreements.  See the NOTICE file distributed with
@@ -17,69 +16,65 @@
  */
#include "axiom_mime_output.h"
-#include "axiom_data_handler.h"
+#include <axiom_data_handler.h>
 #include "axiom_mime_body_part.h"
 #include <axutil_string.h>
 #include <axiom_text.h>
 #include <axiom_mime_const.h>
-struct axiom_mime_output
-{
-    int dummy;
-};
-

AXIS2_EXTERN axiom_mime_output_t *AXIS2_CALL
 axiom_mime_output_create(
-    const axutil_env_t * env)
+    const axutil_env_t *env)
 {
     axiom_mime_output_t *mime_output = NULL;
     AXIS2_ENV_CHECK(env, NULL);
     mime_output = (axiom_mime_output_t *) AXIS2_MALLOC(env->allocator,
-                                                       sizeof
-                                                       (axiom_mime_output_t));
+        sizeof(axiom_mime_output_t));
if (!mime_output)
     {
         AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
+        AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
+            "No memory. Cannot create MIME output");
         return NULL;
     }

Hi Devs,

Because of this modification, sizeof(axiom_mime_output_t) will return 0. Hence, malloc will fail. Also, in windows, this gives a compilation error (since warnings are treated as error). Can we revert it or is it possible to fix it??

Regards,
Shankar.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to