[asterisk-bugs] [Asterisk 0014970]: [patch] chan_vpb fails to catch exception on 1.4
Asterisk Bug Tracker
noreply at bugs.digium.com
Tue Aug 25 08:19:13 CDT 2009
A NOTE has been added to this issue.
======================================================================
https://issues.asterisk.org/view.php?id=14970
======================================================================
Reported By: tzafrir
Assigned To: lmadsen
======================================================================
Project: Asterisk
Issue ID: 14970
Category: Channels/General
Reproducibility: have not tried
Severity: minor
Priority: normal
Status: ready for testing
Asterisk Version: SVN
Regression: No
SVN Branch (only for SVN checkouts, not tarball releases): 1.4
SVN Revision (number only!): 189391
Request Review:
======================================================================
Date Submitted: 2009-04-25 04:01 CDT
Last Modified: 2009-08-25 08:19 CDT
======================================================================
Summary: [patch] chan_vpb fails to catch exception on 1.4
Description:
On module startup, chan_vpb asks libvpb to scan for relevant hardware. If
libvpb fails to find any, it raises an exception:
try {
num_cards = vpb_get_num_cards();
} catch (VpbException e) {
ast_log(LOG_ERROR, "No Voicetronix cards detected\n");
return AST_MODULE_LOAD_DECLINE;
}
This seems to work as planned on trunk . However with 1.4 (on the same
system and same libvpb) I get
*CLI> module load chan_vpb.so
[Apr 25 11:56:50] ERROR[20919]: chan_vpb.cc:2720 ast_module_load_result
terminate called after throwing an instance of 'VpbException'
what(): VPBREG_NO_VPB_DEVICES_DETECTED
/home/tzafrir/Proj/Asterisk/Git/asterisk/live_ast: line 170: 20919 Aborted
$AST_BIN -C $AST_CONF "$@"
The fix/workaround (attached) is to use the parent class std::exception .
After which I get:
*CLI> module load chan_vpb.so
[Apr 25 11:58:40] ERROR[21550]: chan_vpb.cc:2722 ast_module_load_result
load_module(): No Voicetronix cards detected
and no panic.
======================================================================
----------------------------------------------------------------------
(0109582) lmadsen (administrator) - 2009-08-25 08:19
https://issues.asterisk.org/view.php?id=14970#c109582
----------------------------------------------------------------------
Which version of the VPB driver are you guys using? I'm getting an error
just building it:
[LDXX] chan_vpb.oo -> chan_vpb.so
/usr/bin/ld: /usr/local/lib/libvpb.a(call.o): relocation R_X86_64_32
against `a local symbol' can not be used when making a shared object;
recompile with -fPIC
/usr/local/lib/libvpb.a: could not read symbols: Bad value
Issue History
Date Modified Username Field Change
======================================================================
2009-08-25 08:19 lmadsen Note Added: 0109582
======================================================================
More information about the asterisk-bugs
mailing list