patches for easier mirroring, to eliminate a special copy, to make www.freebsd.org/security a full copy of security.freebsd.org and be eventually be the same. For now files are just sitting there. The symlinks are missing. Discussed on: www (repository location) Discussed with: simon (so)
47 lines
1 KiB
Diff
47 lines
1 KiB
Diff
Index: crypto/openssl/ssl/ssl_lib.c
|
|
===================================================================
|
|
RCS file: /home/ncvs/src/crypto/openssl/ssl/ssl_lib.c,v
|
|
retrieving revision 1.1.1.12.2.1
|
|
diff -u -d -r1.1.1.12.2.1 ssl_lib.c
|
|
--- crypto/openssl/ssl/ssl_lib.c 28 Sep 2006 13:02:36 -0000 1.1.1.12.2.1
|
|
+++ crypto/openssl/ssl/ssl_lib.c 3 Oct 2007 17:01:24 -0000
|
|
@@ -1149,7 +1149,6 @@
|
|
char *SSL_get_shared_ciphers(SSL *s,char *buf,int len)
|
|
{
|
|
char *p;
|
|
- const char *cp;
|
|
STACK_OF(SSL_CIPHER) *sk;
|
|
SSL_CIPHER *c;
|
|
int i;
|
|
@@ -1162,20 +1161,21 @@
|
|
sk=s->session->ciphers;
|
|
for (i=0; i<sk_SSL_CIPHER_num(sk); i++)
|
|
{
|
|
- /* Decrement for either the ':' or a '\0' */
|
|
- len--;
|
|
+ int n;
|
|
+
|
|
c=sk_SSL_CIPHER_value(sk,i);
|
|
- for (cp=c->name; *cp; )
|
|
+ n=strlen(c->name);
|
|
+ if (n+1 > len)
|
|
{
|
|
- if (len-- <= 0)
|
|
- {
|
|
- *p='\0';
|
|
- return(buf);
|
|
- }
|
|
- else
|
|
- *(p++)= *(cp++);
|
|
+ if (p != buf)
|
|
+ --p;
|
|
+ *p='\0';
|
|
+ return buf;
|
|
}
|
|
+ strcpy(p,c->name);
|
|
+ p+=n;
|
|
*(p++)=':';
|
|
+ len-=n+1;
|
|
}
|
|
p[-1]='\0';
|
|
return(buf);
|