aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-smime-context.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2003-10-24 03:57:58 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2003-10-24 03:57:58 +0800
commitb1be2a6d83aa9b9404ca735e73e73dc903625dc7 (patch)
tree36ede0609588101ba900b8c018462b7c7a3591c9 /camel/camel-smime-context.c
parent18ca85654d06140f30ea9db347dcf4f7cf00d7f0 (diff)
downloadgsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.tar
gsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.tar.gz
gsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.tar.bz2
gsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.tar.lz
gsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.tar.xz
gsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.tar.zst
gsoc2013-evolution-b1be2a6d83aa9b9404ca735e73e73dc903625dc7.zip
Removed unneeded CAMEL_OBJECT() casts.
2003-10-23 Jeffrey Stedfast <fejj@ximian.com> * *.c: Removed unneeded CAMEL_OBJECT() casts. svn path=/trunk/; revision=23052
Diffstat (limited to 'camel/camel-smime-context.c')
-rw-r--r--camel/camel-smime-context.c26
1 files changed, 14 insertions, 12 deletions
diff --git a/camel/camel-smime-context.c b/camel/camel-smime-context.c
index dfd7ecd7f4..3c87c83f64 100644
--- a/camel/camel-smime-context.c
+++ b/camel/camel-smime-context.c
@@ -20,6 +20,8 @@
*
*/
+/* Note: much of the NSS code was copied from Mozilla's cmsutil.c program */
+
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
@@ -380,7 +382,7 @@ smime_sign (CamelCMSContext *ctx, CamelMimeMessage *message,
NSS_CMSEncoder_Update (ecx, buf->data, buf->len);
NSS_CMSEncoder_Finish (ecx);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
g_free (data);
/* write the result to a camel stream */
@@ -394,7 +396,7 @@ smime_sign (CamelCMSContext *ctx, CamelMimeMessage *message,
mesg = camel_mime_message_new ();
camel_stream_reset (stream);
camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (mesg), stream);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
return mesg;
}
@@ -495,7 +497,7 @@ smime_certsonly (CamelCMSContext *ctx, CamelMimeMessage *message,
NSS_CMSEncoder_Update (ecx, buf->data, buf->len);
NSS_CMSEncoder_Finish (ecx);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
g_free (data);
/* write the result to a camel stream */
@@ -509,7 +511,7 @@ smime_certsonly (CamelCMSContext *ctx, CamelMimeMessage *message,
mesg = camel_mime_message_new ();
camel_stream_reset (stream);
camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (mesg), stream);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
return mesg;
}
@@ -618,7 +620,7 @@ smime_envelope (CamelCMSContext *ctx, CamelMimeMessage *message,
NSS_CMSEncoder_Update (ecx, buf->data, buf->len);
NSS_CMSEncoder_Finish (ecx);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
g_free (data);
/* write the result to a camel stream */
@@ -632,7 +634,7 @@ smime_envelope (CamelCMSContext *ctx, CamelMimeMessage *message,
mesg = camel_mime_message_new ();
camel_stream_reset (stream);
camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (mesg), stream);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
return mesg;
}
@@ -747,14 +749,14 @@ smime_encrypt (CamelCMSContext *ctx, CamelMimeMessage *message,
stream = camel_stream_mem_new ();
camel_stream_mem_set_byte_array (CAMEL_STREAM_MEM (stream), buf);
camel_data_wrapper_write_to_stream (CAMEL_DATA_WRAPPER (message), stream);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
stream = camel_stream_mem_new ();
cmsg = encrypted_data (CAMEL_SMIME_CONTEXT (ctx), buf, bulkkey, stream, ex);
g_byte_array_free (buf, TRUE);
g_free (bulkkey);
if (!cmsg) {
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
return NULL;
}
@@ -764,7 +766,7 @@ smime_encrypt (CamelCMSContext *ctx, CamelMimeMessage *message,
mesg = camel_mime_message_new ();
camel_stream_reset (stream);
camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (mesg), stream);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
return mesg;
}
@@ -933,9 +935,9 @@ smime_decode (CamelCMSContext *ctx, CamelMimeMessage *message,
ostream = camel_stream_mem_new ();
cmsg = decode_data (CAMEL_SMIME_CONTEXT (ctx), buf, ostream, info, ex);
- camel_object_unref (CAMEL_OBJECT (stream));
+ camel_object_unref (stream);
if (!cmsg) {
- camel_object_unref (CAMEL_OBJECT (ostream));
+ camel_object_unref (ostream);
return NULL;
}
@@ -943,7 +945,7 @@ smime_decode (CamelCMSContext *ctx, CamelMimeMessage *message,
mesg = camel_mime_message_new ();
camel_stream_reset (ostream);
camel_data_wrapper_construct_from_stream (CAMEL_DATA_WRAPPER (mesg), ostream);
- camel_object_unref (CAMEL_OBJECT (ostream));
+ camel_object_unref (ostream);
return mesg;
}