- or download this
my ($cnf,$thread) = @_;
if ($thread && !$db_connections{$cnf}{$thread}) {
...
#^^^^^^^^
"dbi:Pg:database=dirotext;host=domain.com", 'user', 'pass'
+
) or die $DBI::errstr;
- or download this
sub dbconn() {
my ($cnf,$thread) = @_;
- or download this
my %response_hash = ();
...
return \%response_hash;
...
my %tr_res = %{$running_threads{$name}->join()};
- or download this
my %response_hash; ## No need to initialise lexicals.
...
return %response_hash; ## Return a simple list of values
...
my %tr_res = $running_threads{$name}->join(); ## Assign the list to a
+local hash.
- or download this
$running_threads{$threadname} = threads->create(\&send_sms
+_message, $db_ids_in_progress{$id}{'uid'}, $db_ids_in_progress{$id}{'
+from'}, $db_ids_in_progress{$id}{'to'}, $db_ids_in_progress{$id}{'msg
+'}, $id, $db_ids_in_progress{$id}{'dlr_track_id'}, $processing);
- or download this
( $running_threads{$threadname} ) = threads->create(
\&send_sms_message,
...
$db_ids_in_progress{$id}{'dlr_track_id'},
$processing
);