… | |
… | |
288 | // this genewrates quite ugly code, but the overhead |
288 | // this genewrates quite ugly code, but the overhead |
289 | // of copying the bytes for these lengths is probably so high |
289 | // of copying the bytes for these lengths is probably so high |
290 | // that a slightly inefficient get_length won't matter. |
290 | // that a slightly inefficient get_length won't matter. |
291 | |
291 | |
292 | if (expect_false (cnt == 0)) |
292 | if (expect_false (cnt == 0)) |
293 | error ("indefinite BER value lengths not supported"); |
293 | error ("illegal use of indefinite BER length form in primitive encoding (X.690 8.1.3.2)"); |
294 | |
294 | |
295 | if (expect_false (cnt > UVSIZE)) |
295 | if (expect_false (cnt > UVSIZE)) |
296 | error ("BER value length too long (must fit into UV) or BER reserved value in length (X.690 8.1.3.5)"); |
296 | error ("BER value length too long (must fit into UV) or BER reserved value in length (X.690 8.1.3.5)"); |
297 | |
297 | |
298 | want (cnt); |
298 | want (cnt); |