kopia lustrzana https://github.com/jamescoxon/dl-fldigi
Merge tag 'v3.21.80' of http://git.code.sf.net/p/fldigi/fldigi
Conflicts: src/dialogs/confdialog.cxx src/dialogs/confdialog.flpull/1/head
commit
3fa6610928
15
ChangeLog
15
ChangeLog
|
@ -1,9 +1,20 @@
|
|||
|
||||
|
||||
=Version 3.21.80=
|
||||
|
||||
2014-03-19 David Freese <w1hkj@w1hkj.com>
|
||||
|
||||
d3aa1cc: FreeBSD nitems
|
||||
ca39b53: Cabrillo time off
|
||||
819a3ee: Change Fl_ListBox
|
||||
6baa7d1: Restore Fl_Choice
|
||||
cee5d0e: Olivia select fix
|
||||
0a7e37c: ComboBox
|
||||
36da549: fluid update
|
||||
|
||||
|
||||
=Version 3.21.79=
|
||||
|
||||
2014-03-07 David Freese <w1hkj@w1hkj.com>
|
||||
|
||||
2d189bd: RigCAT initialize
|
||||
b391b02: Modem cleanup
|
||||
720f88d: Missing build script
|
||||
|
|
|
@ -9,7 +9,7 @@ dnl major and minor must be integers; patch may
|
|||
dnl contain other characters or be empty
|
||||
m4_define(FLDIGI_MAJOR, [3])
|
||||
m4_define(FLDIGI_MINOR, [21])
|
||||
m4_define(FLDIGI_PATCH, [.79])
|
||||
m4_define(FLDIGI_PATCH, [.80])
|
||||
m4_define(FLARQ_MAJOR, [4])
|
||||
m4_define(FLARQ_MINOR, [3])
|
||||
m4_define(FLARQ_PATCH, [.4])
|
||||
|
|
|
@ -249,11 +249,11 @@ void btnComboBox_cb (Fl_Widget *v, void *d)
|
|||
}
|
||||
|
||||
Fl_ComboBox::Fl_ComboBox (int X,int Y,int W,int H, const char *lbl, int wtype)
|
||||
: Fl_Group (X, Y, W, H, lbl),
|
||||
type_(wtype)
|
||||
: Fl_Group (X, Y, W, H, lbl)
|
||||
{
|
||||
width = W; height = H;
|
||||
|
||||
type_ = wtype;
|
||||
if (type_ == LISTBOX) {
|
||||
valbox = new Fl_Box (FL_DOWN_BOX, X, Y, W-H, H, "");
|
||||
valbox->align(FL_ALIGN_INSIDE | FL_ALIGN_LEFT);
|
||||
|
@ -261,7 +261,6 @@ Fl_ComboBox::Fl_ComboBox (int X,int Y,int W,int H, const char *lbl, int wtype)
|
|||
} else {
|
||||
val = new Fl_Input (X, Y, W-H, H, "");
|
||||
val->align(FL_ALIGN_INSIDE | FL_ALIGN_LEFT);
|
||||
readonly();
|
||||
}
|
||||
|
||||
btn = new Fl_Button (X + W - H + 1, Y, H - 1, H, "@2>");
|
||||
|
|
Plik diff jest za duży
Load Diff
Plik diff jest za duży
Load Diff
|
@ -691,8 +691,8 @@ void set_olivia_default_integ()
|
|||
|
||||
void set_olivia_tab_widgets()
|
||||
{
|
||||
i_listbox_olivia_bandwidth->index(progdefaults.oliviabw+1);
|
||||
i_listbox_olivia_tones->index(progdefaults.oliviatones+1);
|
||||
i_listbox_olivia_bandwidth->index(progdefaults.oliviabw);
|
||||
i_listbox_olivia_tones->index(progdefaults.oliviatones);
|
||||
set_olivia_default_integ();
|
||||
}
|
||||
|
||||
|
@ -726,8 +726,8 @@ void set_contestia_default_integ()
|
|||
|
||||
void set_contestia_tab_widgets()
|
||||
{
|
||||
i_listbox_contestia_bandwidth->index(progdefaults.contestiabw+1);
|
||||
i_listbox_contestia_tones->index(progdefaults.contestiatones+1);
|
||||
i_listbox_contestia_bandwidth->index(progdefaults.contestiabw);
|
||||
i_listbox_contestia_tones->index(progdefaults.contestiatones);
|
||||
set_contestia_default_integ();
|
||||
}
|
||||
|
||||
|
@ -7703,7 +7703,7 @@ void set_olivia_tones(int tones)
|
|||
while (tones >>= 1)
|
||||
i++;
|
||||
bool changed = progdefaults.changed;
|
||||
i_listbox_olivia_tones->index(i);// - 1);
|
||||
i_listbox_olivia_tones->index(i+1);
|
||||
i_listbox_olivia_tones->do_callback();
|
||||
progdefaults.changed = changed;
|
||||
}
|
||||
|
@ -7734,7 +7734,7 @@ void set_contestia_tones(int tones)
|
|||
while (tones >>= 1)
|
||||
i++;
|
||||
bool changed = progdefaults.changed;
|
||||
i_listbox_contestia_tones->index(i);// - 1);
|
||||
i_listbox_contestia_tones->index(i+1);
|
||||
i_listbox_contestia_tones->do_callback();
|
||||
progdefaults.changed = changed;
|
||||
}
|
||||
|
|
|
@ -367,7 +367,7 @@ extern Fl_Tabs *tabsRig;
|
|||
extern Fl_Check_Button *btnPTTrightchannel;
|
||||
extern Fl_Group *grpHWPTT;
|
||||
extern Fl_Round_Button *btnTTYptt;
|
||||
extern Fl_ListBox *inpTTYdev;
|
||||
extern Fl_ComboBox *inpTTYdev;
|
||||
extern Fl_Round_Button *btnRTSptt;
|
||||
extern Fl_Round_Button *btnRTSplusV;
|
||||
extern Fl_Round_Button *btnDTRptt;
|
||||
|
@ -382,7 +382,7 @@ extern Fl_Check_Button *chkUSERIGCAT;
|
|||
extern Fl_Group *grpRigCAT;
|
||||
extern Fl_Output *txtXmlRigFilename;
|
||||
extern Fl_Button *btnSelectRigXmlFile;
|
||||
extern Fl_ListBox *inpXmlRigDevice;
|
||||
extern Fl_ComboBox *inpXmlRigDevice;
|
||||
extern Fl_Value_Input2 *cntRigCatRetries;
|
||||
extern Fl_Value_Input2 *cntRigCatTimeout;
|
||||
extern Fl_Value_Input2 *cntRigCatWait;
|
||||
|
@ -404,8 +404,8 @@ extern Fl_Value_Input2 *cntRigCatInitDelay;
|
|||
extern Fl_Group *tabHamlib;
|
||||
extern Fl_Check_Button *chkUSEHAMLIB;
|
||||
extern Fl_Group *grpHamlib;
|
||||
extern Fl_ListBox *cboHamlibRig;
|
||||
extern Fl_ListBox *inpRIGdev;
|
||||
extern Fl_ComboBox *cboHamlibRig;
|
||||
extern Fl_ComboBox *inpRIGdev;
|
||||
extern Fl_Value_Input2 *cntHamlibRetries;
|
||||
extern Fl_Value_Input2 *cntHamlibTimeout;
|
||||
extern Fl_Value_Input2 *cntHamlibWriteDelay;
|
||||
|
@ -430,10 +430,12 @@ extern Fl_Group *tabSoundCard;
|
|||
extern Fl_Tabs *tabsSoundCard;
|
||||
extern Fl_Group *tabAudio;
|
||||
extern Fl_Group *AudioOSS;
|
||||
extern Fl_ListBox *menuOSSDev;
|
||||
#include <FL/Fl_Input_Choice.H>
|
||||
extern Fl_Input_Choice *menuOSSDev;
|
||||
extern Fl_Group *AudioPort;
|
||||
extern Fl_ListBox *menuPortInDev;
|
||||
extern Fl_ListBox *menuPortOutDev;
|
||||
#include <FL/Fl_Choice.H>
|
||||
extern Fl_Choice *menuPortInDev;
|
||||
extern Fl_Choice *menuPortOutDev;
|
||||
extern Fl_Group *AudioPulse;
|
||||
extern Fl_Input2 *inpPulseServer;
|
||||
extern Fl_Group *AudioNull;
|
||||
|
|
|
@ -4,6 +4,14 @@
|
|||
#define lgbook_h
|
||||
#include <FL/Fl.H>
|
||||
#include "flinput2.h"
|
||||
// Avoid 'nitems' macro collision between FreeBSD's sys/params.h and fltk's
|
||||
// FL/Fl_Check_Browser.H (http://www.fltk.org/str.php?L2984)
|
||||
#undef nitems
|
||||
#include <FL/Fl_Check_Browser.H>
|
||||
#define FLTK_nitems nitems
|
||||
#undef nitems
|
||||
// ^^^ Avoid 'nitems' macro collision
|
||||
extern Fl_Check_Browser *chkExportBrowser;
|
||||
#include <FL/Fl_Double_Window.H>
|
||||
extern Fl_Double_Window *wExport;
|
||||
#include <FL/Fl_Group.H>
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
// ----------------------------------------------------------------------------
|
||||
|
||||
#ifndef SUPPORT_H
|
||||
#define SUPPORT_h
|
||||
#define SUPPORT_H
|
||||
|
||||
#include <string>
|
||||
|
||||
|
|
|
@ -207,7 +207,11 @@ inline bool read_until_delim( char delim, std::istream & istrm, double & ref )
|
|||
/// Reads a string up to the given delimiter.
|
||||
inline bool read_until_delim( char delim, std::istream & istrm, std::string & ref )
|
||||
{
|
||||
return std::getline( istrm, ref, delim );
|
||||
std::getline( istrm, ref, delim );
|
||||
if ( (istrm.rdstate() & std::istream::goodbit) == 0 )
|
||||
return true ;
|
||||
else
|
||||
return false ;
|
||||
}
|
||||
|
||||
/// For reading from a string with tokens separated by a char. Used to load CSV files.
|
||||
|
@ -215,12 +219,13 @@ template< typename Tp >
|
|||
bool read_until_delim( char delim, std::istream & istrm, Tp & ref, typename DtTyp< Tp >::Any = typename DtTyp< Tp >::Any() )
|
||||
{
|
||||
std::string parsed_str ;
|
||||
if( ! std::getline( istrm, parsed_str, delim ) ) {
|
||||
std::getline( istrm, parsed_str, delim );
|
||||
if( ! ((istrm.rdstate() & std::istream::goodbit) == 0)) {
|
||||
return false ;
|
||||
}
|
||||
imemstream sstrm( parsed_str );
|
||||
sstrm >> ref ;
|
||||
return sstrm ;
|
||||
return true ;
|
||||
}
|
||||
|
||||
/// Same, with a default value if there is nothing to read.
|
||||
|
@ -228,7 +233,8 @@ template< typename Tp >
|
|||
bool read_until_delim( char delim, std::istream & istrm, Tp & ref, const Tp dflt, typename DtTyp< Tp >::Any = typename DtTyp< Tp >::Any() )
|
||||
{
|
||||
std::string parsed_str ;
|
||||
if( ! std::getline( istrm, parsed_str, delim ) ) {
|
||||
std::getline( istrm, parsed_str, delim ) ;
|
||||
if( ! ((istrm.rdstate() & std::istream::goodbit) == 0) ) {
|
||||
return false ;
|
||||
}
|
||||
if( parsed_str.empty() ) {
|
||||
|
@ -237,7 +243,7 @@ bool read_until_delim( char delim, std::istream & istrm, Tp & ref, const Tp dflt
|
|||
}
|
||||
imemstream sstrm( parsed_str );
|
||||
sstrm >> ref ;
|
||||
return sstrm ;
|
||||
return true ;
|
||||
}
|
||||
|
||||
/// For reading from a string with tokens separated by a char to a fixed-size array.
|
||||
|
@ -246,7 +252,7 @@ bool read_until_delim( char delim, std::istream & istrm, Tp & ref, typename DtTy
|
|||
{
|
||||
istrm.getline( ref, DtTyp< Tp >::Size, delim );
|
||||
// Should we return an error if buffer is too small?
|
||||
return istrm ;
|
||||
return( (istrm.rdstate() & std::istream::goodbit) == 0 );
|
||||
}
|
||||
|
||||
/// Same, with a default value if there is nothing to read. Fixed-size array.
|
||||
|
@ -259,7 +265,7 @@ bool read_until_delim( char delim, std::istream & istrm, Tp & ref, const Tp dflt
|
|||
strncpy( ref, dflt, DtTyp< Tp >::Size - 1 );
|
||||
}
|
||||
// Should we return an error if buffer is too small?
|
||||
return istrm;
|
||||
return ((istrm.rdstate() & std::istream::goodbit) == 0 );
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
|
|
|
@ -23,6 +23,18 @@ decl {\#include "pixmaps.h"} {private local
|
|||
decl {\#include "flinput2.h"} {public local
|
||||
}
|
||||
|
||||
decl {
|
||||
// Avoid 'nitems' macro collision between FreeBSD's sys/params.h and fltk's
|
||||
// FL/Fl_Check_Browser.H (http://www.fltk.org/str.php?L2984)
|
||||
\#undef nitems
|
||||
\#include <FL/Fl_Check_Browser.H>
|
||||
\#define FLTK_nitems nitems
|
||||
\#undef nitems
|
||||
// ^^^ Avoid 'nitems' macro collision
|
||||
extern Fl_Check_Browser *chkExportBrowser;
|
||||
} {public local
|
||||
}
|
||||
|
||||
Function {create_logbook_dialogs()} {open return_type void
|
||||
} {
|
||||
Fl_Window wExport {
|
||||
|
|
|
@ -212,7 +212,7 @@ void Export_ADIF()
|
|||
}
|
||||
}
|
||||
string sp = p;
|
||||
if (sp.find("."ADIF_SUFFIX) == string::npos) sp.append("."ADIF_SUFFIX);
|
||||
if (sp.find("." ADIF_SUFFIX) == string::npos) sp.append("." ADIF_SUFFIX);
|
||||
adifFile.writeFile (sp.c_str(), &qsodb);
|
||||
}
|
||||
|
||||
|
@ -309,8 +309,8 @@ void cb_mnuSaveLogbook(Fl_Menu_*m, void* d) {
|
|||
const char* p = FSEL::saveas( title.c_str(), filter.c_str(), logbook_filename.c_str());
|
||||
if (p) {
|
||||
logbook_filename = p;
|
||||
if (logbook_filename.find("."ADIF_SUFFIX) == string::npos)
|
||||
logbook_filename.append("."ADIF_SUFFIX);
|
||||
if (logbook_filename.find("." ADIF_SUFFIX) == string::npos)
|
||||
logbook_filename.append("." ADIF_SUFFIX);
|
||||
dlgLogbook->label(fl_filename_name(logbook_filename.c_str()));
|
||||
|
||||
cQsoDb::reverse = false;
|
||||
|
@ -1386,7 +1386,9 @@ void cabrillo_append_qso (FILE *fp, cQsoRec *rec)
|
|||
}
|
||||
|
||||
if (contestnbr == BARTG_RTTY && exch_out.length() < 11) {
|
||||
exch_out.append(rec->getField(TIME_OFF)).append(" ");
|
||||
string toff = rec->getField(TIME_OFF);
|
||||
toff = toff.substr(0,4).append(" ");
|
||||
exch_out.append(toff);
|
||||
}
|
||||
|
||||
if (exch_out.length() > 14) exch_out = exch_out.substr(0,14);
|
||||
|
@ -1548,9 +1550,14 @@ SOAPBOX: \n\n",
|
|||
return;
|
||||
}
|
||||
|
||||
#ifdef __clang__
|
||||
# include <unordered_map>
|
||||
typedef std::unordered_map<string, unsigned> dxcc_entity_cache_t;
|
||||
#else
|
||||
# include <tr1/unordered_map>
|
||||
typedef tr1::unordered_map<string, unsigned> dxcc_entity_cache_t;
|
||||
#endif
|
||||
|
||||
#include <tr1/unordered_map>
|
||||
typedef tr1::unordered_map<string, unsigned> dxcc_entity_cache_t;
|
||||
static dxcc_entity_cache_t dxcc_entity_cache;
|
||||
static bool dxcc_entity_cache_enabled = false;
|
||||
|
||||
|
|
|
@ -30,7 +30,6 @@
|
|||
#include <string>
|
||||
#include <list>
|
||||
#include <map>
|
||||
#include <tr1/unordered_map>
|
||||
#include <algorithm>
|
||||
|
||||
#include <FL/filename.H>
|
||||
|
@ -44,8 +43,14 @@
|
|||
#include "main.h"
|
||||
|
||||
using namespace std;
|
||||
using tr1::unordered_map;
|
||||
|
||||
#ifdef __clang__
|
||||
# include <unordered_map>
|
||||
using std::unordered_map;
|
||||
#else
|
||||
# include <tr1/unordered_map>
|
||||
using tr1::unordered_map;
|
||||
#endif
|
||||
|
||||
dxcc::dxcc(const char* cn, int cq, int itu, const char* ct, float lat, float lon, float tz)
|
||||
: country(cn), cq_zone(cq), itu_zone(itu), latitude(lat), longitude(lon), gmt_offset(tz)
|
||||
|
|
|
@ -120,12 +120,21 @@ void re_t::suboff(size_t n, int* start, int* end) const
|
|||
}
|
||||
}
|
||||
|
||||
#include <tr1/functional>
|
||||
#ifdef __clang__
|
||||
# include <functional>
|
||||
#else
|
||||
# include <tr1/functional>
|
||||
#endif
|
||||
|
||||
size_t re_t::hash(void) const
|
||||
{
|
||||
#ifdef __clang__
|
||||
size_t h = std::hash<string>()(pattern);
|
||||
return h ^ (std::hash<int>()(cflags) + 0x9e3779b9 + (h << 6) + (h >> 2));
|
||||
#else
|
||||
size_t h = tr1::hash<string>()(pattern);
|
||||
return h ^ (tr1::hash<int>()(cflags) + 0x9e3779b9 + (h << 6) + (h >> 2));
|
||||
#endif
|
||||
}
|
||||
|
||||
// ------------------------------------------------------------------------
|
||||
|
|
|
@ -181,11 +181,11 @@ static void init_portaudio(void)
|
|||
}
|
||||
// add to menu
|
||||
if (ilist->dev->maxInputChannels > 0)
|
||||
menuPortInDev->add(menu_item.c_str(),
|
||||
reinterpret_cast<void *>(ilist->idx));
|
||||
menuPortInDev->add(menu_item.c_str(), 0, NULL,
|
||||
reinterpret_cast<void *>(ilist->idx), 0);
|
||||
if (ilist->dev->maxOutputChannels > 0)
|
||||
menuPortOutDev->add(menu_item.c_str(),
|
||||
reinterpret_cast<void *>(ilist->idx));
|
||||
menuPortOutDev->add(menu_item.c_str(), 0, NULL,
|
||||
reinterpret_cast<void *>(ilist->idx), 0);
|
||||
}
|
||||
|
||||
if (progdefaults.PortInDevice.length() == 0) {
|
||||
|
@ -214,18 +214,40 @@ static void init_portaudio(void)
|
|||
|
||||
// select the correct menu items
|
||||
|
||||
int size = menuPortInDev->lsize();
|
||||
for (int i = 1; i <= size; i++) {
|
||||
menuPortInDev->index(i);
|
||||
if (progdefaults.PortInDevice == menuPortInDev->value())
|
||||
break;
|
||||
const Fl_Menu_Item* menu;
|
||||
int size;
|
||||
int idx;
|
||||
|
||||
idx = -1;
|
||||
menu = menuPortInDev->menu();
|
||||
size = menuPortInDev->size();
|
||||
for (int i = 0; i < size - 1; i++, menu++) {
|
||||
if (menu->label() && progdefaults.PortInDevice == menu->label()) {
|
||||
idx = i; // near match
|
||||
if (reinterpret_cast<intptr_t>(menu->user_data()) == progdefaults.PortInIndex ||
|
||||
progdefaults.PortInIndex == -1) // exact match, or index was never saved
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (idx >= 0) {
|
||||
menuPortInDev->value(idx);
|
||||
menuPortInDev->set_changed();
|
||||
}
|
||||
|
||||
size = menuPortOutDev->lsize();
|
||||
for (int i = 1; i <= size; i++) {
|
||||
menuPortOutDev->index(i);
|
||||
if (progdefaults.PortOutDevice == menuPortOutDev->value())
|
||||
break;
|
||||
idx = -1;
|
||||
menu = menuPortOutDev->menu();
|
||||
size = menuPortOutDev->size();
|
||||
for (int i = 0; i < size - 1; i++, menu++) {
|
||||
if (menu->label() && progdefaults.PortOutDevice == menu->label()) {
|
||||
idx = i;
|
||||
if (reinterpret_cast<intptr_t>(menu->user_data()) == progdefaults.PortOutIndex ||
|
||||
progdefaults.PortOutIndex == -1)
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (idx >= 0) {
|
||||
menuPortOutDev->value(idx);
|
||||
menuPortOutDev->set_changed();
|
||||
}
|
||||
}
|
||||
#else
|
||||
|
@ -452,10 +474,10 @@ void sound_update(unsigned idx)
|
|||
case SND_IDX_PORT:
|
||||
menuPortInDev->activate();
|
||||
menuPortOutDev->activate();
|
||||
if (menuPortInDev->value())
|
||||
scDevice[0] = menuPortInDev->value();
|
||||
if (menuPortOutDev->value())
|
||||
scDevice[1] = menuPortOutDev->value();
|
||||
if (menuPortInDev->text())
|
||||
scDevice[0] = menuPortInDev->text();
|
||||
if (menuPortOutDev->text())
|
||||
scDevice[1] = menuPortOutDev->text();
|
||||
|
||||
{
|
||||
Fl_ListBox* listbox[2] = { menuInSampleRate, menuOutSampleRate };
|
||||
|
|
|
@ -35,21 +35,26 @@
|
|||
|
||||
#include "timeops.h"
|
||||
|
||||
#if (__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1)
|
||||
# define MAP_TYPE std::tr1::unordered_map
|
||||
# include <tr1/unordered_map>
|
||||
#ifdef __clang__
|
||||
# define MAP_TYPE std::unordered_map
|
||||
# include <unordered_map>
|
||||
#else
|
||||
# if (__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1)
|
||||
# define MAP_TYPE std::tr1::unordered_map
|
||||
# include <tr1/unordered_map>
|
||||
# else
|
||||
// use the non-standard gnu hash_map on gcc <= 4.0.x,
|
||||
// which has a broken tr1::unordered_map::operator=
|
||||
# define MAP_TYPE __gnu_cxx::hash_map
|
||||
# include <ext/hash_map>
|
||||
namespace __gnu_cxx {
|
||||
// define the missing hash specialisation for std::string
|
||||
// using the 'const char*' hash function
|
||||
template<> struct hash<std::string> {
|
||||
size_t operator()(const std::string& s) const { return __stl_hash_string(s.c_str()); }
|
||||
};
|
||||
}
|
||||
# define MAP_TYPE __gnu_cxx::hash_map
|
||||
# include <ext/hash_map>
|
||||
namespace __gnu_cxx {
|
||||
// define the missing hash specialisation for std::string
|
||||
// using the 'const char*' hash function
|
||||
template<> struct hash<std::string> {
|
||||
size_t operator()(const std::string& s) const { return __stl_hash_string(s.c_str()); }
|
||||
};
|
||||
}
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#include <unistd.h>
|
||||
|
|
|
@ -50,7 +50,11 @@
|
|||
#include <algorithm>
|
||||
#include <fstream>
|
||||
|
||||
#if (__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1)
|
||||
#if __clang__
|
||||
# define MAP_TYPE std::unordered_map
|
||||
#define HASH_TYPE std::hash
|
||||
# include <unordered_map>
|
||||
#elif (__GNUC__ > 4) || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1)
|
||||
# define MAP_TYPE std::tr1::unordered_map
|
||||
#define HASH_TYPE std::tr1::hash
|
||||
# include <tr1/unordered_map>
|
||||
|
@ -692,7 +696,7 @@ void pskrep_sender::write_preamble(void)
|
|||
tlen = sizeof(long_station_info_template);
|
||||
station_info = &long_station_info;
|
||||
}
|
||||
else if (template_count >= 0) {
|
||||
else if (template_count != 0) {
|
||||
station_info_template = short_station_info_template;
|
||||
tlen = sizeof(short_station_info_template);
|
||||
station_info = &short_station_info;
|
||||
|
|
|
@ -23,7 +23,11 @@
|
|||
#include <config.h>
|
||||
|
||||
#include <list>
|
||||
#ifdef __clang__
|
||||
#include <unordered_map>
|
||||
#else
|
||||
#include <tr1/unordered_map>
|
||||
#endif
|
||||
#include <functional>
|
||||
|
||||
#include "trx.h"
|
||||
|
@ -60,9 +64,14 @@ struct fre_comp : std::unary_function<const fre_t*, bool>
|
|||
};
|
||||
|
||||
typedef list<callback_t*> callback_p_list_t;
|
||||
#ifdef __clang__
|
||||
typedef std::unordered_map<fre_t*, callback_p_list_t, fre_hash, fre_comp> rcblist_t;
|
||||
static std::unordered_map<int, string> buffers;
|
||||
#else
|
||||
typedef tr1::unordered_map<fre_t*, callback_p_list_t, fre_hash, fre_comp> rcblist_t;
|
||||
|
||||
static tr1::unordered_map<int, string> buffers;
|
||||
#endif
|
||||
static cblist_t cblist;
|
||||
static rcblist_t rcblist;
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue