diff options
author | Lev Walkin <vlm@lionet.info> | 2006-03-27 21:40:26 +0000 |
---|---|---|
committer | Lev Walkin <vlm@lionet.info> | 2006-03-27 21:40:26 +0000 |
commit | b386d2422e25fad5b84c398b112dd7311d7e4fcd (patch) | |
tree | 75946bca2f8317a2164733404f2e1aaf3d79830d /asn1c | |
parent | 5045dfaba4cd14cbcbb40b00dc3f3dfd0685e916 (diff) |
protection from DOS
Diffstat (limited to 'asn1c')
-rw-r--r-- | asn1c/unber.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/asn1c/unber.c b/asn1c/unber.c index 21761312..56176119 100644 --- a/asn1c/unber.c +++ b/asn1c/unber.c @@ -1,5 +1,6 @@ /*- - * Copyright (c) 2004, 2005 Lev Walkin <vlm@lionet.info>. All rights reserved. + * Copyright (c) 2004, 2005, 2006 Lev Walkin <vlm@lionet.info>. + * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -177,7 +178,7 @@ process(const char *fname) { ber_tlv_len_t frame_size = 0; /* Single frame size */ if(strcmp(fname, "-")) { - fp = fopen(fname, "r"); + fp = fopen(fname, "rb"); if(!fp) { perror(fname); return -1; |