changeset 24700:bf2ca2c5ac40

Use av_len in the same manner as everywhere else, for consistency.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Fri, 12 Dec 2008 00:01:40 +0000
parents 34b02adafd9b
children 93f0249b4ff4
files libpurple/plugins/perl/common/Certificate.xs
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/plugins/perl/common/Certificate.xs	Thu Dec 11 22:36:47 2008 +0000
+++ b/libpurple/plugins/perl/common/Certificate.xs	Fri Dec 12 00:01:40 2008 +0000
@@ -231,8 +231,8 @@
 		int len = 0, i = 0;
 		struct cb_data *d = NULL;
 	PPCODE:
-		len = av_len(cert_chain) + 1;
-		for(i = 0; i < len; i++) {
+		len = av_len(cert_chain);
+		for(i = 0; i <= len; i++) {
 			SV **sv = av_fetch(cert_chain, i, 0);
 			if(!sv || !purple_perl_is_ref_object(*sv)) {
 				g_list_free(l);