Mercurial > libavcodec.hg
comparison a52dec.c @ 368:1db6950d81ea libavcodec
- Segfault fixed when liba52 dynamic library isn't found.
author | pulento |
---|---|
date | Mon, 06 May 2002 21:34:50 +0000 |
parents | 1a38b3b4ea28 |
children | 718a22dc121f |
comparison
equal
deleted
inserted
replaced
367:abbed9f28d75 | 368:1db6950d81ea |
---|---|
78 | 78 |
79 #ifdef CONFIG_A52BIN | 79 #ifdef CONFIG_A52BIN |
80 s->handle = dlopen(liba52name, RTLD_LAZY); | 80 s->handle = dlopen(liba52name, RTLD_LAZY); |
81 if (!s->handle) | 81 if (!s->handle) |
82 { | 82 { |
83 fprintf(stderr, "A52 library %s could not be opened: %s\n", liba52name, dlerror()); | 83 fprintf(stderr, "A52 library %s could not be opened! \n%s\n", liba52name, dlerror()); |
84 return -1; | 84 return -1; |
85 } | 85 } |
86 s->a52_init = (a52_state_t* (*)(uint32_t)) dlsymm(s->handle, "a52_init"); | 86 s->a52_init = (a52_state_t* (*)(uint32_t)) dlsymm(s->handle, "a52_init"); |
87 s->a52_samples = (sample_t* (*)(a52_state_t*)) dlsymm(s->handle, "a52_samples"); | 87 s->a52_samples = (sample_t* (*)(a52_state_t*)) dlsymm(s->handle, "a52_samples"); |
88 s->a52_syncinfo = (int (*)(uint8_t*, int*, int*, int*)) dlsymm(s->handle, "a52_syncinfo"); | 88 s->a52_syncinfo = (int (*)(uint8_t*, int*, int*, int*)) dlsymm(s->handle, "a52_syncinfo"); |