]> granicus.if.org Git - curl/commitdiff
Fix getsockname argument type
authorPatrick Monnerat <Patrick.Monnerat@datasphere.ch>
Wed, 8 Aug 2007 10:37:07 +0000 (10:37 +0000)
committerPatrick Monnerat <Patrick.Monnerat@datasphere.ch>
Wed, 8 Aug 2007 10:37:07 +0000 (10:37 +0000)
Improve "universal" alignment type in struct memdebug

lib/krb5.c
lib/memdebug.c

index 989bc4959948ef7f178553d7db31d3b41a6060df..b2c04a9cbac96a7c4f20fcec4cd2a14740ff3aa4 100644 (file)
@@ -155,7 +155,7 @@ krb5_auth(void *app_data, struct connectdata *conn)
   char *p;
   const char *host = conn->dns_entry->addr->ai_canonname;
   ssize_t nread;
-  unsigned int l = sizeof(conn->local_addr);
+  socklen_t l = sizeof(conn->local_addr);
   struct SessionHandle *data = conn->data;
   CURLcode result;
   const char *service = "ftp", *srv_host = "host";
index 2eb4c5afb90f374280d089bfa72c750f1e1b596a..9d3ef3d5ea2826d70691df211b0e5c2e2ecf5729 100644 (file)
 
 struct memdebug {
   size_t size;
-  double mem[1];
+  union {
+    double d;
+    void * p;
+  } mem[1];
   /* I'm hoping this is the thing with the strictest alignment
    * requirements.  That also means we waste some space :-( */
 };