Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
alandekok committed Sep 27, 2014
1 parent ba5087c commit 128b512
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/modules/rlm_mschap/rlm_mschap.c
Original file line number Diff line number Diff line change
Expand Up @@ -964,20 +964,20 @@ static int CC_HINT(nonnull (1, 2, 4, 5)) do_mschap_cpw(rlm_mschap_t *inst,
* Gah. nasty. maybe we should just pull in iconv?
*/
if (c < 0x7f) {
x[new_pass->length++] = c;
*x++ = c;

} else if (c < 0x7ff) {
x[new_pass->length++] = 0xc0 + (c >> 6);
x[new_pass->length++] = 0x80 + (c & 0x3f);
*x++ = 0xc0 + (c >> 6);
*x++ = 0x80 + (c & 0x3f);

} else {
x[new_pass->length++] = 0xe0 + (c >> 12);
x[new_pass->length++] = 0x80 + ((c>>6) & 0x3f);
x[new_pass->length++] = 0x80 + (c & 0x3f);
*x++ = 0xe0 + (c >> 12);
*x++ = 0x80 + ((c>>6) & 0x3f);
*x++ = 0x80 + (c & 0x3f);
}
}

x[new_pass->length] = '\0';
*x = '\0';

/* Perform the xlat */
result_len = radius_xlat(result, sizeof(result), request, inst->local_cpw, NULL, NULL);
Expand Down

0 comments on commit 128b512

Please sign in to comment.