comparison gendss.c @ 1121:bb3a03feb31f

Merge pull request #13 from gazoo74/fix-warnings Fix warnings
author Matt Johnston <matt@ucc.asn.au>
date Thu, 04 Jun 2015 22:25:28 +0800
parents c45d65392c1a
children 750ec4ec4cbe
comparison
equal deleted inserted replaced
1087:1e486f368ec3 1121:bb3a03feb31f
65 65
66 } 66 }
67 67
68 static void getq(dropbear_dss_key *key) { 68 static void getq(dropbear_dss_key *key) {
69 69
70 char buf[QSIZE]; 70 unsigned char buf[QSIZE];
71 71
72 /* 160 bit prime */ 72 /* 160 bit prime */
73 genrandom(buf, QSIZE); 73 genrandom(buf, QSIZE);
74 buf[0] |= 0x80; /* top bit high */ 74 buf[0] |= 0x80; /* top bit high */
75 buf[QSIZE-1] |= 0x01; /* bottom bit high */ 75 buf[QSIZE-1] |= 0x01; /* bottom bit high */