projects
/
platform
/
upstream
/
freerdp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
54b26c4
)
Simplify code a bit.
author
Pawel Jakub Dawidek
<pawel@dawidek.net>
Tue, 28 Feb 2012 21:36:54 +0000
(22:36 +0100)
committer
Pawel Jakub Dawidek
<pawel@dawidek.net>
Tue, 28 Feb 2012 21:51:57 +0000
(22:51 +0100)
libfreerdp-crypto/per.c
patch
|
blob
|
history
diff --git
a/libfreerdp-crypto/per.c
b/libfreerdp-crypto/per.c
index
b10b57b
..
dad589a
100644
(file)
--- a/
libfreerdp-crypto/per.c
+++ b/
libfreerdp-crypto/per.c
@@
-407,18
+407,14
@@
void per_write_octet_string(STREAM* s, uint8* oct_str, int length, int min)
boolean per_read_numeric_string(STREAM* s, int min)
{
- int i;
int length;
uint16 mlength;
per_read_length(s, &mlength);
- length =
mlength + min
;
+ length =
(mlength + min + 1) / 2
;
- for (i = 0; i < length; i += 2)
- {
- stream_seek(s, 1);
- }
+ stream_seek(s, length);
return true;
}