|
|
|
@ -29,9 +29,9 @@ along with LinBPQ/BPQ32. If not, see http://www.gnu.org/licenses
|
|
|
|
|
|
|
|
|
|
|
|
// Bulls should not be distributed outside their designated area.
|
|
|
|
// Bulls should not be distributed outside their designated area.
|
|
|
|
|
|
|
|
|
|
|
|
// Use 4 char continent codes if this isn't defined
|
|
|
|
// Use 4 char continent codes if this is set
|
|
|
|
|
|
|
|
|
|
|
|
#define TWOCHARCONT
|
|
|
|
int FOURCHARCONT = 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include "bpqmail.h"
|
|
|
|
#include "bpqmail.h"
|
|
|
|
@ -95,21 +95,21 @@ struct Continent Continents[] =
|
|
|
|
|
|
|
|
|
|
|
|
struct Country Countries[] =
|
|
|
|
struct Country Countries[] =
|
|
|
|
{
|
|
|
|
{
|
|
|
|
"AFG", "****", "AS", // Afghanistan
|
|
|
|
"AFG", "ASIA", "AS", // Afghanistan
|
|
|
|
"ALA", "EURO", "EU", // Åland Islands
|
|
|
|
"ALA", "EURO", "EU", // Åland Islands
|
|
|
|
"ALB", "EURO", "EU", // Albania
|
|
|
|
"ALB", "EURO", "EU", // Albania
|
|
|
|
"DZA", "NAFR", "AF", // Algeria
|
|
|
|
"DZA", "NAFR", "AF", // Algeria
|
|
|
|
"ASM", "****", "AS", // American Samoa
|
|
|
|
"ASM", "ASIA", "AS", // American Samoa
|
|
|
|
"AND", "EURO", "EU", // Andorra
|
|
|
|
"AND", "EURO", "EU", // Andorra
|
|
|
|
"AGO", "CAFR", "AF", // Angola
|
|
|
|
"AGO", "CAFR", "AF", // Angola
|
|
|
|
"AIA", "CARB", "NA", // Anguilla
|
|
|
|
"AIA", "CARB", "NA", // Anguilla
|
|
|
|
"ATG", "CARB", "NA", // Antigua and Barbuda
|
|
|
|
"ATG", "CARB", "NA", // Antigua and Barbuda
|
|
|
|
"ARG", "SOAM", "SA", // Argentina
|
|
|
|
"ARG", "SOAM", "SA", // Argentina
|
|
|
|
"ARM", "****", "AS", // Armenia
|
|
|
|
"ARM", "ASIA", "AS", // Armenia
|
|
|
|
"ABW", "CARB", "NA", // Aruba
|
|
|
|
"ABW", "CARB", "NA", // Aruba
|
|
|
|
"AUS", "AUNZ", "OC", // Australia
|
|
|
|
"AUS", "AUNZ", "OC", // Australia
|
|
|
|
"AUT", "EURO", "EU", // Austria
|
|
|
|
"AUT", "EURO", "EU", // Austria
|
|
|
|
"AZE", "****", "AS", // Azerbaijan
|
|
|
|
"AZE", "ASIA", "AS", // Azerbaijan
|
|
|
|
"BHS", "CARB", "NA", // Bahamas
|
|
|
|
"BHS", "CARB", "NA", // Bahamas
|
|
|
|
"BHR", "MDLE", "AS", // Bahrain
|
|
|
|
"BHR", "MDLE", "AS", // Bahrain
|
|
|
|
"BGD", "INDE", "AS", // Bangladesh
|
|
|
|
"BGD", "INDE", "AS", // Bangladesh
|
|
|
|
@ -122,14 +122,14 @@ struct Country Countries[] =
|
|
|
|
"BTN", "ASIA", "AS", // Bhutan
|
|
|
|
"BTN", "ASIA", "AS", // Bhutan
|
|
|
|
"BOL", "SOAM", "SA", // Bolivia (Plurinational State of)
|
|
|
|
"BOL", "SOAM", "SA", // Bolivia (Plurinational State of)
|
|
|
|
"BIH", "EURO", "EU", // Bosnia and Herzegovina
|
|
|
|
"BIH", "EURO", "EU", // Bosnia and Herzegovina
|
|
|
|
"BWA", "****", "AF", // Botswana
|
|
|
|
"BWA", "SAFR", "AF", // Botswana
|
|
|
|
"BRA", "SOAM", "SA", // Brazil
|
|
|
|
"BRA", "SOAM", "SA", // Brazil
|
|
|
|
"VGB", "CARB", "NA", // British Virgin Islands
|
|
|
|
"VGB", "CARB", "NA", // British Virgin Islands
|
|
|
|
"BRN", "ASIA", "AS", // Brunei Darussalam
|
|
|
|
"BRN", "ASIA", "AS", // Brunei Darussalam
|
|
|
|
"BGR", "EURO", "EU", // Bulgaria
|
|
|
|
"BGR", "EURO", "EU", // Bulgaria
|
|
|
|
"BFA", "CAFR", "AF", // Burkina Faso
|
|
|
|
"BFA", "CAFR", "AF", // Burkina Faso
|
|
|
|
"BDI", "CAFR", "AF", // Burundi
|
|
|
|
"BDI", "CAFR", "AF", // Burundi
|
|
|
|
"KHM", "****", "AS", // Cambodia
|
|
|
|
"KHM", "ASIA", "AS", // Cambodia
|
|
|
|
"CMR", "CAFR", "AF", // Cameroon
|
|
|
|
"CMR", "CAFR", "AF", // Cameroon
|
|
|
|
"CAN", "NOAM", "NA", // Canada
|
|
|
|
"CAN", "NOAM", "NA", // Canada
|
|
|
|
"CPV", "NAFR", "AF", // Cape Verde
|
|
|
|
"CPV", "NAFR", "AF", // Cape Verde
|
|
|
|
@ -137,12 +137,12 @@ struct Country Countries[] =
|
|
|
|
"CAF", "CAFR", "AF", // Central African Republic
|
|
|
|
"CAF", "CAFR", "AF", // Central African Republic
|
|
|
|
"TCD", "CAFR", "AF", // Chad
|
|
|
|
"TCD", "CAFR", "AF", // Chad
|
|
|
|
"CHL", "SOAM", "SA", // Chile
|
|
|
|
"CHL", "SOAM", "SA", // Chile
|
|
|
|
"CHN", "****", "AS", // China
|
|
|
|
"CHN", "ASIA", "AS", // China
|
|
|
|
"HKG", "****", "AS", // Hong Kong Special Administrative Region of China
|
|
|
|
"HKG", "ASIA", "AS", // Hong Kong Special Administrative Region of China
|
|
|
|
"MAC", "****", "AS", // Macao Special Administrative Region of China
|
|
|
|
"MAC", "ASIA", "AS", // Macao Special Administrative Region of China
|
|
|
|
"COL", "****", "SA", // Colombia
|
|
|
|
"COL", "ASIA", "SA", // Colombia
|
|
|
|
"COM", "SAFR", "AF", // Comoros
|
|
|
|
"COM", "SAFR", "AF", // Comoros
|
|
|
|
"COG", "****", "AF", // Congo
|
|
|
|
"COG", "CAFR", "AF", // Congo
|
|
|
|
"COK", "SPAC", "OC", // Cook Islands
|
|
|
|
"COK", "SPAC", "OC", // Cook Islands
|
|
|
|
"CRI", "CEAM", "NA", // Costa Rica
|
|
|
|
"CRI", "CEAM", "NA", // Costa Rica
|
|
|
|
"CIV", "CAFR", "AF", // Côte d'Ivoire
|
|
|
|
"CIV", "CAFR", "AF", // Côte d'Ivoire
|
|
|
|
@ -150,8 +150,8 @@ struct Country Countries[] =
|
|
|
|
"CUB", "CARB", "NA", // Cuba
|
|
|
|
"CUB", "CARB", "NA", // Cuba
|
|
|
|
"CYP", "EURO", "EU", // Cyprus
|
|
|
|
"CYP", "EURO", "EU", // Cyprus
|
|
|
|
"CZE", "EURO", "EU", // Czech Republic
|
|
|
|
"CZE", "EURO", "EU", // Czech Republic
|
|
|
|
"PRK", "****", "AS", // Democratic People's Republic of Korea
|
|
|
|
"PRK", "ASIA", "AS", // Democratic People's Republic of Korea
|
|
|
|
"COD", "****", "AF", // Democratic Republic of the Congo
|
|
|
|
"COD", "CAFR", "AF", // Democratic Republic of the Congo
|
|
|
|
"DNK", "EURO", "EU", // Denmark
|
|
|
|
"DNK", "EURO", "EU", // Denmark
|
|
|
|
"DJI", "NAFR", "AF", // Djibouti
|
|
|
|
"DJI", "NAFR", "AF", // Djibouti
|
|
|
|
"DMA", "CARB", "NA", // Dominica
|
|
|
|
"DMA", "CARB", "NA", // Dominica
|
|
|
|
@ -160,9 +160,9 @@ struct Country Countries[] =
|
|
|
|
"EGY", "MDLE", "AF", // Egypt
|
|
|
|
"EGY", "MDLE", "AF", // Egypt
|
|
|
|
"SLV", "CEAM", "NA", // El Salvador
|
|
|
|
"SLV", "CEAM", "NA", // El Salvador
|
|
|
|
"GNQ", "CAFR", "AF", // Equatorial Guinea
|
|
|
|
"GNQ", "CAFR", "AF", // Equatorial Guinea
|
|
|
|
"ERI", "****", "AF", // Eritrea
|
|
|
|
"ERI", "NAFR", "AF", // Eritrea
|
|
|
|
"EST", "EURO", "EU", // Estonia
|
|
|
|
"EST", "EURO", "EU", // Estonia
|
|
|
|
"ETH", "****", "AF", // Ethiopia
|
|
|
|
"ETH", "NAFR", "AF", // Ethiopia
|
|
|
|
"FRO", "EURO", "EU", // Faeroe Islands
|
|
|
|
"FRO", "EURO", "EU", // Faeroe Islands
|
|
|
|
"FLK", "SOAM", "SA", // Falkland Islands (Malvinas)
|
|
|
|
"FLK", "SOAM", "SA", // Falkland Islands (Malvinas)
|
|
|
|
"FJI", "SPAC", "OC", // Fiji
|
|
|
|
"FJI", "SPAC", "OC", // Fiji
|
|
|
|
@ -192,7 +192,7 @@ struct Country Countries[] =
|
|
|
|
"HUN", "EURO", "EU", // Hungary
|
|
|
|
"HUN", "EURO", "EU", // Hungary
|
|
|
|
"ISL", "EURO", "EU", // Iceland
|
|
|
|
"ISL", "EURO", "EU", // Iceland
|
|
|
|
"IND", "INDI", "AS", // India
|
|
|
|
"IND", "INDI", "AS", // India
|
|
|
|
"IDN", "****", "AS", // Indonesia
|
|
|
|
"IDN", "ASIA", "AS", // Indonesia
|
|
|
|
"IRN", "MDLE", "AS", // Iran (Islamic Republic of)
|
|
|
|
"IRN", "MDLE", "AS", // Iran (Islamic Republic of)
|
|
|
|
"IRQ", "MDLE", "AS", // Iraq
|
|
|
|
"IRQ", "MDLE", "AS", // Iraq
|
|
|
|
"IRL", "EURO", "EU", // Ireland
|
|
|
|
"IRL", "EURO", "EU", // Ireland
|
|
|
|
@ -200,11 +200,11 @@ struct Country Countries[] =
|
|
|
|
"ISR", "MDLE", "AS", // Israel
|
|
|
|
"ISR", "MDLE", "AS", // Israel
|
|
|
|
"ITA", "EURO", "EU", // Italy
|
|
|
|
"ITA", "EURO", "EU", // Italy
|
|
|
|
"JAM", "CEAM", "NA", // Jamaica
|
|
|
|
"JAM", "CEAM", "NA", // Jamaica
|
|
|
|
"JPN", "****", "AS", // Japan
|
|
|
|
"JPN", "ASIA", "AS", // Japan
|
|
|
|
"JEY", "EURO", "EU", // Jersey
|
|
|
|
"JEY", "EURO", "EU", // Jersey
|
|
|
|
"JOR", "MDLE", "AS", // Jordan
|
|
|
|
"JOR", "MDLE", "AS", // Jordan
|
|
|
|
"KAZ", "****", "AS", // Kazakhstan
|
|
|
|
"KAZ", "ASIA", "AS", // Kazakhstan
|
|
|
|
"KEN", "****", "AF", // Kenya
|
|
|
|
"KEN", "CAFR", "AF", // Kenya
|
|
|
|
"KIR", "EPAC", "OC", // Kiribati
|
|
|
|
"KIR", "EPAC", "OC", // Kiribati
|
|
|
|
"KWT", "MDLE", "AS", // Kuwait
|
|
|
|
"KWT", "MDLE", "AS", // Kuwait
|
|
|
|
"KGZ", "ASIA", "AS", // Kyrgyzstan
|
|
|
|
"KGZ", "ASIA", "AS", // Kyrgyzstan
|
|
|
|
@ -228,25 +228,25 @@ struct Country Countries[] =
|
|
|
|
"MRT", "NAFR", "AF", // Mauritania
|
|
|
|
"MRT", "NAFR", "AF", // Mauritania
|
|
|
|
"MUS", "SAFR", "AF", // Mauritius
|
|
|
|
"MUS", "SAFR", "AF", // Mauritius
|
|
|
|
"MYT", "SAFR", "AF", // Mayotte
|
|
|
|
"MYT", "SAFR", "AF", // Mayotte
|
|
|
|
"MEX", "****", "NA", // Mexico
|
|
|
|
"MEX", "NOAM", "NA", // Mexico
|
|
|
|
"FSM", "WPAC", "OC", // Micronesia (Federated States of)
|
|
|
|
"FSM", "WPAC", "OC", // Micronesia (Federated States of)
|
|
|
|
"MCO", "EURO", "EU", // Monaco
|
|
|
|
"MCO", "EURO", "EU", // Monaco
|
|
|
|
"MNG", "****", "AS", // Mongolia
|
|
|
|
"MNG", "ASIA", "AS", // Mongolia
|
|
|
|
"MNE", "EURO", "EU", // Montenegro
|
|
|
|
"MNE", "EURO", "EU", // Montenegro
|
|
|
|
"MSR", "CARB", "NA", // Montserrat
|
|
|
|
"MSR", "CARB", "NA", // Montserrat
|
|
|
|
"MAR", "NAFR", "AF", // Morocco
|
|
|
|
"MAR", "NAFR", "AF", // Morocco
|
|
|
|
"MOZ", "SAFR", "AF", // Mozambique
|
|
|
|
"MOZ", "SAFR", "AF", // Mozambique
|
|
|
|
"MMR", "ASIA", "AS", // Myanmar
|
|
|
|
"MMR", "ASIA", "AS", // Myanmar
|
|
|
|
"NAM", "****", "AF", // Namibia
|
|
|
|
"NAM", "SAFR", "AF", // Namibia
|
|
|
|
"NRU", "WPAC", "OC", // Nauru
|
|
|
|
"NRU", "WPAC", "OC", // Nauru
|
|
|
|
"NPL", "****", "AS", // Nepal
|
|
|
|
"NPL", "ASIA", "AS", // Nepal
|
|
|
|
"NLD", "EURO", "EU", // Netherlands
|
|
|
|
"NLD", "EURO", "EU", // Netherlands
|
|
|
|
"ANT", "CARB", "NA", // Netherlands Antilles
|
|
|
|
"ANT", "CARB", "NA", // Netherlands Antilles
|
|
|
|
"NCL", "SPAC", "OC", // New Caledonia
|
|
|
|
"NCL", "SPAC", "OC", // New Caledonia
|
|
|
|
"NZL", "AUNZ", "OC", // New Zealand
|
|
|
|
"NZL", "AUNZ", "OC", // New Zealand
|
|
|
|
"NIC", "****", "SA", // Nicaragua
|
|
|
|
"NIC", "CEAM", "SA", // Nicaragua
|
|
|
|
"NER", "NAFR", "AF", // Niger
|
|
|
|
"NER", "NAFR", "AF", // Niger
|
|
|
|
"NGA", "****", "AF", // Nigeria
|
|
|
|
"NGA", "CAFR", "AF", // Nigeria
|
|
|
|
"NIU", "SPAC", "OC", // Niue
|
|
|
|
"NIU", "SPAC", "OC", // Niue
|
|
|
|
"NFK", "SPAC", "OC", // Norfolk Island
|
|
|
|
"NFK", "SPAC", "OC", // Norfolk Island
|
|
|
|
"MNP", "WPAC", "OC", // Northern Mariana Islands
|
|
|
|
"MNP", "WPAC", "OC", // Northern Mariana Islands
|
|
|
|
@ -270,7 +270,7 @@ struct Country Countries[] =
|
|
|
|
"REU", "SAFR", "AF", // Réunion
|
|
|
|
"REU", "SAFR", "AF", // Réunion
|
|
|
|
"ROU", "EURO", "EU", // Romania
|
|
|
|
"ROU", "EURO", "EU", // Romania
|
|
|
|
"RUS", "ASIA", "AS", // Russian Federation
|
|
|
|
"RUS", "ASIA", "AS", // Russian Federation
|
|
|
|
"RWA", "****", "AF", // Rwanda
|
|
|
|
"RWA", "CAFR", "AF", // Rwanda
|
|
|
|
"BLM", "CARB", "NA", // Saint-Barthélemy
|
|
|
|
"BLM", "CARB", "NA", // Saint-Barthélemy
|
|
|
|
"SHN", "SOAM", "SA", // Saint Helena
|
|
|
|
"SHN", "SOAM", "SA", // Saint Helena
|
|
|
|
"KNA", "CARB", "NA", // Saint Kitts and Nevis
|
|
|
|
"KNA", "CARB", "NA", // Saint Kitts and Nevis
|
|
|
|
@ -285,50 +285,50 @@ struct Country Countries[] =
|
|
|
|
"SEN", "CAFR", "AF", // Senegal
|
|
|
|
"SEN", "CAFR", "AF", // Senegal
|
|
|
|
"SRB", "EURO", "EU", // Serbia
|
|
|
|
"SRB", "EURO", "EU", // Serbia
|
|
|
|
"SYC", "SAFR", "AF", // Seychelles
|
|
|
|
"SYC", "SAFR", "AF", // Seychelles
|
|
|
|
"SLE", "****", "AF", // Sierra Leone
|
|
|
|
"SLE", "NAFR", "AF", // Sierra Leone
|
|
|
|
"SGP", "****", "AS", // Singapore
|
|
|
|
"SGP", "ASIA", "AS", // Singapore
|
|
|
|
"SVK", "EURO", "EU", // Slovakia
|
|
|
|
"SVK", "EURO", "EU", // Slovakia
|
|
|
|
"SVN", "EURO", "EU", // Slovenia
|
|
|
|
"SVN", "EURO", "EU", // Slovenia
|
|
|
|
"SLB", "SPAC", "OC", // Solomon Islands
|
|
|
|
"SLB", "SPAC", "OC", // Solomon Islands
|
|
|
|
"SOM", "****", "AF", // Somalia
|
|
|
|
"SOM", "NAFR", "AF", // Somalia
|
|
|
|
"ZAF", "SAFR", "AF", // South Africa
|
|
|
|
"ZAF", "SAFR", "AF", // South Africa
|
|
|
|
"ESP", "EURO", "EU", // Spain
|
|
|
|
"ESP", "EURO", "EU", // Spain
|
|
|
|
"LKA", "INDE", "AS", // Sri Lanka
|
|
|
|
"LKA", "INDE", "AS", // Sri Lanka
|
|
|
|
"SDN", "****", "AF", // Sudan
|
|
|
|
"SDN", "NAFR", "AF", // Sudan
|
|
|
|
"SUR", "SOAM", "SA", // Suriname
|
|
|
|
"SUR", "SOAM", "SA", // Suriname
|
|
|
|
"SJM", "EURO", "EU", // Svalbard and Jan Mayen Islands
|
|
|
|
"SJM", "EURO", "EU", // Svalbard and Jan Mayen Islands
|
|
|
|
"SWZ", "****", "AF", // Swaziland
|
|
|
|
"SWZ", "SAFR", "AF", // Swaziland
|
|
|
|
"SWE", "EURO", "EU", // Sweden
|
|
|
|
"SWE", "EURO", "EU", // Sweden
|
|
|
|
"CHE", "EURO", "EU", // Switzerland
|
|
|
|
"CHE", "EURO", "EU", // Switzerland
|
|
|
|
"SYR", "MDLE", "AS", // Syrian Arab Republic
|
|
|
|
"SYR", "MDLE", "AS", // Syrian Arab Republic
|
|
|
|
"TJK", "ASIA", "AS", // Tajikistan
|
|
|
|
"TJK", "ASIA", "AS", // Tajikistan
|
|
|
|
"THA", "****", "AS", // Thailand
|
|
|
|
"THA", "ASIA", "AS", // Thailand
|
|
|
|
"MKD", "EURO", "EU", // The former Yugoslav Republic of Macedonia
|
|
|
|
"MKD", "EURO", "EU", // The former Yugoslav Republic of Macedonia
|
|
|
|
"TLS", "ASIA", "AS", // Timor-Leste
|
|
|
|
"TLS", "ASIA", "AS", // Timor-Leste
|
|
|
|
"TGO", "CAFR", "AF", // Togo
|
|
|
|
"TGO", "CAFR", "AF", // Togo
|
|
|
|
"TKL", "AUNZ", "OC", // Tokelau
|
|
|
|
"TKL", "AUNZ", "OC", // Tokelau
|
|
|
|
"TON", "SPAC", "OC", // Tonga
|
|
|
|
"TON", "SPAC", "OC", // Tonga
|
|
|
|
"TTO", "CARB", "NA", // Trinidad and Tobago
|
|
|
|
"TTO", "CARB", "NA", // Trinidad and Tobago
|
|
|
|
"TUN", "****", "AF", // Tunisia
|
|
|
|
"TUN", "NAFR", "AF", // Tunisia
|
|
|
|
"TUR", "EURO", "EU", // Turkey
|
|
|
|
"TUR", "EURO", "EU", // Turkey
|
|
|
|
"TKM", "****", "AS", // Turkmenistan
|
|
|
|
"TKM", "ASIA", "AS", // Turkmenistan
|
|
|
|
"TCA", "CARB", "NA", // Turks and Caicos Islands
|
|
|
|
"TCA", "CARB", "NA", // Turks and Caicos Islands
|
|
|
|
"TUV", "SPAC", "OC", // Tuvalu
|
|
|
|
"TUV", "SPAC", "OC", // Tuvalu
|
|
|
|
"UGA", "****", "AF", // Uganda
|
|
|
|
"UGA", "SAFR", "AF", // Uganda
|
|
|
|
"UKR", "EURO", "EU", // Ukraine
|
|
|
|
"UKR", "EURO", "EU", // Ukraine
|
|
|
|
"ARE", "MDLE", "AS", // United Arab Emirates
|
|
|
|
"ARE", "MDLE", "AS", // United Arab Emirates
|
|
|
|
"GBR", "EURO", "EU", // United Kingdom of Great Britain and Northern Ireland
|
|
|
|
"GBR", "EURO", "EU", // United Kingdom of Great Britain and Northern Ireland
|
|
|
|
"TZA", "****", "AF", // United Republic of Tanzania
|
|
|
|
"TZA", "SAFR", "AF", // United Republic of Tanzania
|
|
|
|
"USA", "NOAM", "NA", // United States of America
|
|
|
|
"USA", "NOAM", "NA", // United States of America
|
|
|
|
"VIR", "CARB", "NA", // United States Virgin Islands
|
|
|
|
"VIR", "CARB", "NA", // United States Virgin Islands
|
|
|
|
"URY", "SOAM", "SA", // Uruguay
|
|
|
|
"URY", "SOAM", "SA", // Uruguay
|
|
|
|
"UZB", "ASIA", "AS", // Uzbekistan
|
|
|
|
"UZB", "ASIA", "AS", // Uzbekistan
|
|
|
|
"VUT", "SPAC", "OC", // Vanuatu
|
|
|
|
"VUT", "SPAC", "OC", // Vanuatu
|
|
|
|
"VEN", "SOAM", "SA", // Venezuela (Bolivarian Republic of)
|
|
|
|
"VEN", "SOAM", "SA", // Venezuela (Bolivarian Republic of)
|
|
|
|
"VNM", "****", "AS", // Viet Nam
|
|
|
|
"VNM", "ASIA", "AS", // Viet Nam
|
|
|
|
"WLF", "SPAC", "OC", // Wallis and Futuna Islands
|
|
|
|
"WLF", "SPAC", "OC", // Wallis and Futuna Islands
|
|
|
|
"ESH", "****", "AF", // Western Sahara
|
|
|
|
"ESH", "CAFR", "AF", // Western Sahara
|
|
|
|
"YEM", "****", "AF", // Yemen
|
|
|
|
"YEM", "NAFR", "AF", // Yemen
|
|
|
|
"ZMB", "SAFR", "AF", // Zambia
|
|
|
|
"ZMB", "SAFR", "AF", // Zambia
|
|
|
|
"ZWE", "SAFR", "AF" // Zimbabwe
|
|
|
|
"ZWE", "SAFR", "AF" // Zimbabwe
|
|
|
|
};
|
|
|
|
};
|
|
|
|
@ -339,9 +339,9 @@ struct ALIAS ** NTSAliases = NULL;
|
|
|
|
|
|
|
|
|
|
|
|
/*struct ALIAS Aliases[] =
|
|
|
|
/*struct ALIAS Aliases[] =
|
|
|
|
{
|
|
|
|
{
|
|
|
|
"AMSAT", "WW",
|
|
|
|
"AMSAT", "WW",
|
|
|
|
"USBBS", "USA",
|
|
|
|
"USBBS", "USA",
|
|
|
|
"ALLUS", "USA"};
|
|
|
|
"ALLUS", "USA"};
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
int NumberofContinents = sizeof(Continents)/sizeof(Continents[1]);
|
|
|
|
int NumberofContinents = sizeof(Continents)/sizeof(Continents[1]);
|
|
|
|
@ -435,7 +435,8 @@ VOID SetupMyHA()
|
|
|
|
|
|
|
|
|
|
|
|
if (MyElements[1])
|
|
|
|
if (MyElements[1])
|
|
|
|
{
|
|
|
|
{
|
|
|
|
#ifdef TWOCHARCONT
|
|
|
|
if (FOURCHARCONT == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(MyElements[1]) == 4)
|
|
|
|
if (strlen(MyElements[1]) == 4)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
@ -446,7 +447,9 @@ VOID SetupMyHA()
|
|
|
|
MyElements[1] = _strdup(Continent->TwoCharCode);
|
|
|
|
MyElements[1] = _strdup(Continent->TwoCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else
|
|
|
|
}
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(MyElements[1]) == 2)
|
|
|
|
if (strlen(MyElements[1]) == 2)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
@ -457,7 +460,7 @@ VOID SetupMyHA()
|
|
|
|
MyElements[1] = _strdup(Continent->FourCharCode);
|
|
|
|
MyElements[1] = _strdup(Continent->FourCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@ -579,7 +582,8 @@ VOID SetupHAElements(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
|
|
|
|
|
|
|
|
if (ForwardingInfo->BBSHAElements[1])
|
|
|
|
if (ForwardingInfo->BBSHAElements[1])
|
|
|
|
{
|
|
|
|
{
|
|
|
|
#ifdef TWOCHARCONT
|
|
|
|
if (FOURCHARCONT == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(ForwardingInfo->BBSHAElements[1]) == 4)
|
|
|
|
if (strlen(ForwardingInfo->BBSHAElements[1]) == 4)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
@ -590,7 +594,9 @@ VOID SetupHAElements(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
ForwardingInfo->BBSHAElements[1] = _strdup(Continent->TwoCharCode);
|
|
|
|
ForwardingInfo->BBSHAElements[1] = _strdup(Continent->TwoCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else
|
|
|
|
}
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(ForwardingInfo->BBSHAElements[1]) == 2)
|
|
|
|
if (strlen(ForwardingInfo->BBSHAElements[1]) == 2)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
@ -601,8 +607,7 @@ VOID SetupHAElements(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
ForwardingInfo->BBSHAElements[1] = _strdup(Continent->FourCharCode);
|
|
|
|
ForwardingInfo->BBSHAElements[1] = _strdup(Continent->FourCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
free(SaveHText);
|
|
|
|
free(SaveHText);
|
|
|
|
@ -614,7 +619,7 @@ VOID SetupHAddreses(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
int Count=0;
|
|
|
|
int Count=0;
|
|
|
|
char ** HText = ForwardingInfo->Haddresses;
|
|
|
|
char ** HText = ForwardingInfo->Haddresses;
|
|
|
|
char * SaveHText, * ptr2;
|
|
|
|
char * SaveHText, * ptr2;
|
|
|
|
// char * TopElement;
|
|
|
|
// char * TopElement;
|
|
|
|
char * Num;
|
|
|
|
char * Num;
|
|
|
|
struct Continent * Continent;
|
|
|
|
struct Continent * Continent;
|
|
|
|
|
|
|
|
|
|
|
|
@ -671,7 +676,7 @@ VOID SetupHAddreses(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
// Far simpler to config it, but can users cope??
|
|
|
|
// Far simpler to config it, but can users cope??
|
|
|
|
// Will config for testing. HA, N
|
|
|
|
// Will config for testing. HA, N
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
/*
|
|
|
|
TopElement=ForwardingInfo->HADDRS[Count][0];
|
|
|
|
TopElement=ForwardingInfo->HADDRS[Count][0];
|
|
|
|
|
|
|
|
|
|
|
|
if (strcmp(TopElement, MyElements[0]) == 0)
|
|
|
|
if (strcmp(TopElement, MyElements[0]) == 0)
|
|
|
|
@ -687,14 +692,16 @@ VOID SetupHAddreses(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
if (Elements < MyElementCount)
|
|
|
|
if (Elements < MyElementCount)
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
|
|
FullHR:
|
|
|
|
FullHR:
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
ForwardingInfo->HADDROffet[Count] = (Num)? atoi(Num): 0;
|
|
|
|
ForwardingInfo->HADDROffet[Count] = (Num)? atoi(Num): 0;
|
|
|
|
|
|
|
|
|
|
|
|
if (ForwardingInfo->HADDRS[Count][1])
|
|
|
|
if (ForwardingInfo->HADDRS[Count][1])
|
|
|
|
{
|
|
|
|
{
|
|
|
|
#ifdef TWOCHARCONT
|
|
|
|
if (FOURCHARCONT == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
if (strlen(ForwardingInfo->HADDRS[Count][1]) == 4)
|
|
|
|
if (strlen(ForwardingInfo->HADDRS[Count][1]) == 4)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
@ -705,7 +712,9 @@ FullHR:
|
|
|
|
ForwardingInfo->HADDRS[Count][1] = _strdup(Continent->TwoCharCode);
|
|
|
|
ForwardingInfo->HADDRS[Count][1] = _strdup(Continent->TwoCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else
|
|
|
|
}
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(ForwardingInfo->HADDRS[Count][1]) == 2)
|
|
|
|
if (strlen(ForwardingInfo->HADDRS[Count][1]) == 2)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
@ -716,8 +725,7 @@ FullHR:
|
|
|
|
ForwardingInfo->HADDRS[Count][1] = _strdup(Continent->FourCharCode);
|
|
|
|
ForwardingInfo->HADDRS[Count][1] = _strdup(Continent->FourCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
free(SaveHText);
|
|
|
|
free(SaveHText);
|
|
|
|
HText++;
|
|
|
|
HText++;
|
|
|
|
@ -732,7 +740,7 @@ VOID SetupHAddresesP(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
int Count=0;
|
|
|
|
int Count=0;
|
|
|
|
char ** HText = ForwardingInfo->HaddressesP;
|
|
|
|
char ** HText = ForwardingInfo->HaddressesP;
|
|
|
|
char * SaveHText, * ptr2;
|
|
|
|
char * SaveHText, * ptr2;
|
|
|
|
// char * TopElement;
|
|
|
|
// char * TopElement;
|
|
|
|
char * Num;
|
|
|
|
char * Num;
|
|
|
|
struct Continent * Continent;
|
|
|
|
struct Continent * Continent;
|
|
|
|
|
|
|
|
|
|
|
|
@ -781,7 +789,9 @@ VOID SetupHAddresesP(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
|
|
|
|
|
|
|
|
if (ForwardingInfo->HADDRSP[Count][1])
|
|
|
|
if (ForwardingInfo->HADDRSP[Count][1])
|
|
|
|
{
|
|
|
|
{
|
|
|
|
#ifdef TWOCHARCONT
|
|
|
|
if (FOURCHARCONT == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
if (strlen(ForwardingInfo->HADDRSP[Count][1]) == 4)
|
|
|
|
if (strlen(ForwardingInfo->HADDRSP[Count][1]) == 4)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
@ -792,7 +802,9 @@ VOID SetupHAddresesP(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
ForwardingInfo->HADDRSP[Count][1] = _strdup(Continent->TwoCharCode);
|
|
|
|
ForwardingInfo->HADDRSP[Count][1] = _strdup(Continent->TwoCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else
|
|
|
|
}
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(ForwardingInfo->HADDRSP[Count][1]) == 2)
|
|
|
|
if (strlen(ForwardingInfo->HADDRSP[Count][1]) == 2)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
@ -803,7 +815,7 @@ VOID SetupHAddresesP(struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
ForwardingInfo->HADDRSP[Count][1] = _strdup(Continent->FourCharCode);
|
|
|
|
ForwardingInfo->HADDRSP[Count][1] = _strdup(Continent->FourCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
free(SaveHText);
|
|
|
|
free(SaveHText);
|
|
|
|
HText++;
|
|
|
|
HText++;
|
|
|
|
@ -1070,7 +1082,7 @@ int MatchMessagetoBBSList(struct MsgInfo * Msg, CIRCUIT * conn)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// See if sending @ winlink.org
|
|
|
|
// See if sending @ winlink.org
|
|
|
|
|
|
|
|
|
|
|
|
if (_stricmp(Msg->to, "RMS") == 0)
|
|
|
|
if (_stricmp(Msg->to, "RMS") == 0)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
@ -1223,11 +1235,11 @@ int MatchMessagetoBBSList(struct MsgInfo * Msg, CIRCUIT * conn)
|
|
|
|
if (Country)
|
|
|
|
if (Country)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Just need to add Continent and WW
|
|
|
|
// Just need to add Continent and WW
|
|
|
|
#ifdef TWOCHARCONT
|
|
|
|
if (FOURCHARCONT == 0)
|
|
|
|
sprintf_s(FullRoute, sizeof(FullRoute),"%s.%s.WW", RouteElements, Country->Continent2);
|
|
|
|
sprintf_s(FullRoute, sizeof(FullRoute),"%s.%s.WW", RouteElements, Country->Continent2);
|
|
|
|
#else
|
|
|
|
else
|
|
|
|
sprintf_s(FullRoute, sizeof(FullRoute),"%s.%s.WW", RouteElements, Country->Continent4);
|
|
|
|
sprintf_s(FullRoute, sizeof(FullRoute),"%s.%s.WW", RouteElements, Country->Continent4);
|
|
|
|
#endif
|
|
|
|
|
|
|
|
goto FULLHA;
|
|
|
|
goto FULLHA;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@ -1270,29 +1282,32 @@ FULLHA:
|
|
|
|
|
|
|
|
|
|
|
|
if (HElements[1])
|
|
|
|
if (HElements[1])
|
|
|
|
{
|
|
|
|
{
|
|
|
|
#ifdef TWOCHARCONT
|
|
|
|
if (FOURCHARCONT == 0)
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(HElements[1]) == 4)
|
|
|
|
if (strlen(HElements[1]) == 4)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
// Convert to 2 char Continent;
|
|
|
|
Continent = FindContinent(HElements[1]);
|
|
|
|
Continent = FindContinent(HElements[1]);
|
|
|
|
if (Continent)
|
|
|
|
if (Continent)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// free(MyElements[1]);
|
|
|
|
// free(MyElements[1]);
|
|
|
|
HElements[1] = _strdup(Continent->TwoCharCode);
|
|
|
|
HElements[1] = _strdup(Continent->TwoCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#else
|
|
|
|
}
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
{
|
|
|
|
if (strlen(HElements[1]) == 2)
|
|
|
|
if (strlen(HElements[1]) == 2)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
// Convert to 4 char Continent;
|
|
|
|
Continent = FindContinent(HElements[1]);
|
|
|
|
Continent = FindContinent(HElements[1]);
|
|
|
|
if (Continent)
|
|
|
|
if (Continent)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// free(MyElements[1]);
|
|
|
|
// free(MyElements[1]);
|
|
|
|
HElements[1] = _strdup(Continent->FourCharCode);
|
|
|
|
HElements[1] = _strdup(Continent->FourCharCode);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -1386,6 +1401,62 @@ NOHA:
|
|
|
|
goto CheckWildCardedAT;
|
|
|
|
goto CheckWildCardedAT;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// First check P message to multiple destinations
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// We should choose the BBS with most matching elements (ie match on #23.GBR better that GBR)
|
|
|
|
|
|
|
|
// If SendPtoMultiple is set I think we send to any with same match level
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// So if SendPtoMultiple is set I think I need to find the best depth then send to all with the same depth
|
|
|
|
|
|
|
|
// If none are found on HA match drop through.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (SendPtoMultiple && Msg->type == 'P')
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
struct UserInfo * bestbbs = NULL;
|
|
|
|
|
|
|
|
int bestmatch = 0;
|
|
|
|
|
|
|
|
int depth;
|
|
|
|
|
|
|
|
int Matched = 0;
|
|
|
|
|
|
|
|
int MultiPDepth = 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Count = 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "SendPtoMultiple is set. Checking for best match level");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (bbs = BBSChain; bbs; bbs = bbs->BBSNext)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
ForwardingInfo = bbs->ForwardingInfo;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
depth = CheckBBSHElements(Msg, bbs, ForwardingInfo, ATBBS, &HElements[0]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (depth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (depth > MultiPDepth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
MultiPDepth = depth;
|
|
|
|
|
|
|
|
bestbbs = bbs;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (MultiPDepth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
for (bbs = BBSChain; bbs; bbs = bbs->BBSNext)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
ForwardingInfo = bbs->ForwardingInfo;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
depth = CheckBBSHElements(Msg, bbs, ForwardingInfo, ATBBS, &HElements[0]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (depth == MultiPDepth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "Routing Trace HR Matches BBS %s Depth %d", bbs->Call, depth);
|
|
|
|
|
|
|
|
CheckAndSend(Msg, conn, bbs);
|
|
|
|
|
|
|
|
Count++;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return Count;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "SendPtoMultiple is set but no match on HA");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (Msg->type == 'P' || Flood == 0)
|
|
|
|
if (Msg->type == 'P' || Flood == 0)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
@ -1467,50 +1538,7 @@ NOHA:
|
|
|
|
return 1;
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// We should choose the BBS with most matching elements (ie match on #23.GBR better that GBR)
|
|
|
|
// Normal HA match (not SendPToMultiple)
|
|
|
|
// If SendPtoMultiple is set I think we send to any with same match level
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// So if SendPtoMultiple is set I think I need to find the best depth then send to all with the same depth
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (SendPtoMultiple && Msg->type == 'P')
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "SendPtoMultiple is set. Checking for best match level");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (bbs = BBSChain; bbs; bbs = bbs->BBSNext)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
ForwardingInfo = bbs->ForwardingInfo;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
depth = CheckBBSHElements(Msg, bbs, ForwardingInfo, ATBBS, &HElements[0]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (depth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (depth > MultiPDepth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
MultiPDepth = depth;
|
|
|
|
|
|
|
|
bestbbs = bbs;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (MultiPDepth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
for (bbs = BBSChain; bbs; bbs = bbs->BBSNext)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
ForwardingInfo = bbs->ForwardingInfo;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
depth = CheckBBSHElements(Msg, bbs, ForwardingInfo, ATBBS, &HElements[0]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (depth == MultiPDepth)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "Routing Trace HR Matches BBS %s Depth %d", bbs->Call, depth);
|
|
|
|
|
|
|
|
CheckAndSend(Msg, conn, bbs);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return 1;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (bbs = BBSChain; bbs; bbs = bbs->BBSNext)
|
|
|
|
for (bbs = BBSChain; bbs; bbs = bbs->BBSNext)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
@ -1644,10 +1672,10 @@ CheckWildCardedAT:
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "Routing Trace - No Match");
|
|
|
|
Logprintf(LOG_BBS, conn, '?', "Routing Trace - No Match");
|
|
|
|
|
|
|
|
|
|
|
|
return Count;
|
|
|
|
return Count;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
BOOL CheckBBSToList(struct MsgInfo * Msg, struct UserInfo * bbs, struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
BOOL CheckBBSToList(struct MsgInfo * Msg, struct UserInfo * bbs, struct BBSForwardingInfo * ForwardingInfo)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
char ** Calls;
|
|
|
|
char ** Calls;
|
|
|
|
|
|
|
|
|
|
|
|
// Check TO distributions
|
|
|
|
// Check TO distributions
|
|
|
|
@ -1665,10 +1693,10 @@ CheckWildCardedAT:
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return FALSE;
|
|
|
|
return FALSE;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
BOOL CheckBBSAtList(struct MsgInfo * Msg, struct BBSForwardingInfo * ForwardingInfo, char * ATBBS)
|
|
|
|
BOOL CheckBBSAtList(struct MsgInfo * Msg, struct BBSForwardingInfo * ForwardingInfo, char * ATBBS)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
char ** Calls;
|
|
|
|
char ** Calls;
|
|
|
|
|
|
|
|
|
|
|
|
// Check AT distributions
|
|
|
|
// Check AT distributions
|
|
|
|
@ -1689,10 +1717,10 @@ CheckWildCardedAT:
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return FALSE;
|
|
|
|
return FALSE;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
int CheckBBSHElements(struct MsgInfo * Msg, struct UserInfo * bbs, struct BBSForwardingInfo * ForwardingInfo, char * ATBBS, char ** HElements)
|
|
|
|
int CheckBBSHElements(struct MsgInfo * Msg, struct UserInfo * bbs, struct BBSForwardingInfo * ForwardingInfo, char * ATBBS, char ** HElements)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
// Used for Personal Messages, and Bulls not yot at their target area
|
|
|
|
// Used for Personal Messages, and Bulls not yot at their target area
|
|
|
|
|
|
|
|
|
|
|
|
char *** HRoutes;
|
|
|
|
char *** HRoutes;
|
|
|
|
@ -1729,11 +1757,11 @@ CheckWildCardedAT:
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return bestmatch;
|
|
|
|
return bestmatch;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int CheckBBSHElementsFlood(struct MsgInfo * Msg, struct UserInfo * bbs, struct BBSForwardingInfo * ForwardingInfo, char * ATBBS, char ** HElements)
|
|
|
|
int CheckBBSHElementsFlood(struct MsgInfo * Msg, struct UserInfo * bbs, struct BBSForwardingInfo * ForwardingInfo, char * ATBBS, char ** HElements)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
char *** HRoutes;
|
|
|
|
char *** HRoutes;
|
|
|
|
char ** BBSHA;
|
|
|
|
char ** BBSHA;
|
|
|
|
|
|
|
|
|
|
|
|
|