]> git.pld-linux.org Git - packages/cyrus-sasl.git/blob - 0033-fix_segfault_in_GSSAPI.patch
- add db 5.3 and 5.2 to the search list
[packages/cyrus-sasl.git] / 0033-fix_segfault_in_GSSAPI.patch
1 --- a/plugins/gssapi.c
2 +++ b/plugins/gssapi.c
3 @@ -370,7 +370,7 @@ sasl_gss_encode(void *context, const str
4      }
5      
6      if (output_token->value && output) {
7 -       unsigned char * p = (unsigned char *) text->encode_buf;
8 +       int len;
9         
10         ret = _plug_buf_alloc(text->utils,
11                               &(text->encode_buf),
12 @@ -384,11 +384,8 @@ sasl_gss_encode(void *context, const str
13             return ret;
14         }
15         
16 -       p[0] = (output_token->length>>24) & 0xFF;
17 -       p[1] = (output_token->length>>16) & 0xFF;
18 -       p[2] = (output_token->length>>8) & 0xFF;
19 -       p[3] = output_token->length & 0xFF;
20 -
21 +       len = htonl(output_token->length);
22 +       memcpy(text->encode_buf, &len, 4);
23         memcpy(text->encode_buf + 4, output_token->value, output_token->length);
24      }
25      
This page took 0.03455 seconds and 3 git commands to generate.