This instance will be upgraded to Heptapod 0.23.2 on 2021-08-05 at 11:00 UTC+2 (a few minutes of down time)

Commit fcdd2b0d authored by Aleksandr Bakhshiev's avatar Aleksandr Bakhshiev
Browse files

Some warnings removed

--HG--
branch : MockCompsTest
parent 7b54ee07eb67
QMAKE_CXXFLAGS += -Wno-misleading-indentation
DEFINES += LIBRDK_LIBRARY_EXPORT
DEFINES += RDK_UNICODE_RUN
......
......@@ -607,7 +607,7 @@ bool UApplication::SetStandartXMLInCatalog(void)
std::vector<std::string> results;
//int FindFilesList(const std::string &path, const std::string &mask, bool isfile, std::vector<std::string> &results)
int a = FindFilesList(path, mask, true, results);
for (int i=0; i< results.size(); i++)
for (size_t i=0; i< results.size(); i++)
{
StandartXMLInCatalog newXMLType;
RDK::USerStorageXML XmlStorage;
......
......@@ -36,8 +36,8 @@ UIntegralPerfomanceResults::UIntegralPerfomanceResults(void)
UPerfomanceResults::UPerfomanceResults(void)
: AvgDuration(0.0), Percentage(0.0), MinDuration(0.0), MaxDuration(0.0),
MinInterval(0.0), MaxInterval(0.0), AvgInterval(0.0)
: MinDuration(0.0), MaxDuration(0.0),
MinInterval(0.0), MaxInterval(0.0), AvgInterval(0.0), AvgDuration(0.0), Percentage(0.0)
{
}
......
......@@ -39,7 +39,7 @@ const char* BoostVersion(void)
//
// --------------------------
UEngineControlThread::UEngineControlThread(UEngineControl* engine_control, int channel_index)
: EngineControl(engine_control), EngineIndex(channel_index), Terminated(false)
: EngineIndex(channel_index), EngineControl(engine_control), Terminated(false)
{
ThreadTimeout=1000;
CalcState=UCreateEvent(false);
......
......@@ -17,7 +17,7 @@ URpcCommandInternal::URpcCommandInternal(void)
}
URpcCommandInternal::URpcCommandInternal(const std::string &request)
: ResponseStatus(0), Request(request)
: Request(request), ResponseStatus(0)
{
}
......
......@@ -365,7 +365,7 @@ bool UADItem::SetOutputDataAsPointer(int index, void *pointer)
//
void* UADItem::GetOutputDataAsPointer(int index)
{
if(index<NumOutputs && GetOutputDataSize(index)[1]>0 && POutputData[index].GetElementByteSize() >= sizeof(void*))
if(index<NumOutputs && GetOutputDataSize(index)[1]>0 && POutputData[index].GetElementByteSize() >= int(sizeof(void*)))
{
return POutputData[index].PVoid[0];
}
......@@ -441,7 +441,7 @@ vector<size_t> UADItem::GetOutputDataElementSize(void) const
return result;
}
/*
bool UADItem::SetOutputDataElementSize(const vector<size_t> &value)
{
// if(OutputData.size() != value.size())
......@@ -715,7 +715,7 @@ bool UADItem::CheckLink(const UEPtr<UConnector> &connector, const NameT &item_pr
{
return UItem::CheckLink(connector, item_property_name);
}
/*
// ,
bool UADItem::CheckLink(const UEPtr<UConnector> &connector, int item_index, int conn_index) const
{
......
......@@ -67,14 +67,14 @@ UELockVar<T>::UELockVar(void)
template<typename T>
UELockVar<T>::UELockVar(const T pdata)
: Mutex(UCreateMutex()), Data(pdata)
: Data(pdata), Mutex(UCreateMutex())
{
// new UGenericMutexLocker(mutex)
}
template<typename T>
UELockVar<T>::UELockVar(const UELockVar<T> &pdata)
: Mutex(UCreateMutex()),Data(pdata.Get())
: Data(pdata.Get()), Mutex(UCreateMutex())
{
}
......
This diff is collapsed.
......@@ -136,12 +136,12 @@ void UEnvironment::SetSystemDir(const std::string& dir)
}
/// ()
long long UEnvironment::GetMinInterstepsInterval(void) const
unsigned long long UEnvironment::GetMinInterstepsInterval(void) const
{
return MinInterstepsInterval;
}
bool UEnvironment::SetMinInterstepsInterval(long long value)
bool UEnvironment::SetMinInterstepsInterval(unsigned long long value)
{
if(MinInterstepsInterval == value)
return true;
......@@ -850,7 +850,7 @@ void UEnvironment::FastCalculate(double calc_interval)
ULongTime cur_time=(ULongTime)((Time.GetSourceCurrentGlobalTime()-Time.GetSourceStartGlobalTime())*(86400.0*1000.0));
Time.SetSourceCurrentLocalTime(cur_time/1000.0);
unsigned long long curtime;
//unsigned long long curtime;
unsigned long long timer_interval=0;
//double devicemodeltime=0;
......@@ -890,7 +890,7 @@ void UEnvironment::FastCalculate(double calc_interval)
break;
}
}
curtime=GetCurrentStartupTime();
// curtime=GetCurrentStartupTime();
if(Time.GetRealTime()/1e6<Time.GetDoubleTime())
{
......
......@@ -160,8 +160,8 @@ const std::string& GetSystemDir(void) const;
void SetSystemDir(const std::string& dir);
/// ()
long long GetMinInterstepsInterval(void) const;
bool SetMinInterstepsInterval(long long value);
unsigned long long GetMinInterstepsInterval(void) const;
bool SetMinInterstepsInterval(unsigned long long value);
/// ()
/// 0 -
......
......@@ -474,7 +474,7 @@ bool URuntimeLibrary::LoadCompDescriptions()
return false;
ClassesStructures.resize(comp_descriptions.size());
for(int i = 0 ; i < comp_descriptions.size(); i++)
for(size_t i = 0 ; i < comp_descriptions.size(); i++)
{
//
CurrentComponentStruct.LoadFromFile(LibPath+"/"+comp_descriptions[i],"");
......
......@@ -1286,7 +1286,7 @@ ULProperty<T,OwnerT,type>& operator = (const T &value)
};
/*
template<typename T, typename OwnerT, unsigned int type=ptPubParameter>
class UPropertyParam: public UPropertyLocal<T,OwnerT,type>
{
......
......@@ -119,7 +119,7 @@ UStorage::~UStorage(void)
ClearClassesStorage(true);
//
for(int i =0; i < CollectionList.size();i++)
for(int i =0; i < int(CollectionList.size());i++)
{
DelCollection(i);
}
......
......@@ -737,7 +737,7 @@ template<class T, unsigned Rows, unsigned Cols>
MMatrix<T,Rows,Cols>& MMatrix<T,Rows,Cols>::operator /= (T v)
{
T* pm1=&Data[0][0];
for(int i=0;i<Cols*Rows;i++)
for(unsigned int i=0;i<Cols*Rows;i++)
*pm1++ /= v;
return *this;
......
......@@ -237,7 +237,7 @@ template<class T, unsigned Rows>
double operator * (const MVector<T,Rows> &M1, const MVector<T,Rows> &M2)
{
double res=0;
for(int k=0;k<Rows;k++)
for(unsigned int k=0;k<Rows;k++)
{
res+=M1.Data[k][0]*M2.Data[k][0];
}
......
......@@ -211,6 +211,11 @@ USerStorageXML& operator >> (USerStorageXML& storage, std::pair<T1,T2> &data)
#pragma warning( push )
#pragma warning (disable: 4700)
#endif
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
template<typename T1, typename T2>
USerStorageXML& operator << (USerStorageXML& storage, const std::map<T1,T2> &data)
{
......@@ -250,6 +255,10 @@ USerStorageXML& operator << (USerStorageXML& storage, const std::map<T1,T2> &dat
return storage;
}
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef _MSC_VER
#pragma warning ( pop )
#endif
......@@ -291,6 +300,11 @@ USerStorageXML& operator >> (USerStorageXML& storage, std::map<T1,T2> &data)
#pragma warning( push )
#pragma warning (disable: 4700)
#endif
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
//
template<typename T>
USerStorageXML& operator << (USerStorageXML& storage, const std::list<T> &data)
......@@ -324,6 +338,10 @@ USerStorageXML& operator << (USerStorageXML& storage, const std::list<T> &data)
return storage;
}
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef _MSC_VER
#pragma warning ( pop )
#endif
......@@ -375,6 +393,11 @@ RDK_LIB_TYPE USerStorageXML& operator >> (USerStorageXML& storage, std::vector<i
#pragma warning( push )
#pragma warning (disable: 4700)
#endif
#ifdef __GNUC__
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
template<typename T>
USerStorageXML& operator << (USerStorageXML& storage, const std::vector<T> &data)
{
......@@ -460,6 +483,10 @@ USerStorageXML& operator << (USerStorageXML& storage, const std::vector<T> &data
return storage;
}
#ifdef __GNUC__
#pragma GCC diagnostic pop
#endif
#ifdef _MSC_VER
#pragma warning ( pop )
#endif
......
......@@ -264,7 +264,7 @@ int URdkCoreManager::LoadFonts(void)
//
bool URdkCoreManager::AddFont(const std::string &font_file_name)
{
int res=RDK_SUCCESS;
//int res=RDK_SUCCESS;
RDK_SYS_TRY
{
try
......@@ -290,18 +290,15 @@ bool URdkCoreManager::AddFont(const std::string &font_file_name)
catch (RDK::UException &exception)
{
SystemLogger.ProcessException(exception);
res=RDK_EXCEPTION_CATCHED;
}
catch (std::exception &exception)
{
SystemLogger.ProcessException(RDK::UExceptionWrapperStd(exception));
res=RDK_EXCEPTION_CATCHED;
}
}
RDK_SYS_CATCH
{
SystemLogger.ProcessException(RDK::UExceptionWrapperSEH(GET_SYSTEM_EXCEPTION_DATA));
res=RDK_EXCEPTION_CATCHED;
}
return false;
......
......@@ -140,9 +140,11 @@ QString UClassesListWidget::selctedClass() const
{
case 0:
return ui->listWidgetStorageByName->currentItem()->text();
break;
case 1:
if (ui->treeWidgetStorageByLibs->currentItem() && ui->treeWidgetStorageByLibs->currentItem()->childCount() == 0)
return ui->treeWidgetStorageByLibs->currentItem()->text(0);
break;
default:
return QString();
}
......@@ -840,7 +842,7 @@ void CrClassDialog::ReplaceClicked()
}
const bool CrClassDialog::GetReplace() const
bool CrClassDialog::GetReplace() const
{
return Replace;
}
......
......@@ -118,7 +118,7 @@ public:
const std::string GetClassName() const;
const std::string GetCompName() const;
const std::string GetLibName() const;
const bool GetReplace() const;
bool GetReplace() const;
public slots:
void ReplaceClicked();
void ProcessInput();
......
......@@ -30,7 +30,7 @@ UComponentLinksWidget::UComponentLinksWidget(QWidget *parent, RDK::UApplication
void UComponentLinksWidget::output1ItemSelectionChanged()
{
QTreeWidgetItem *outputItem1 = ui->treeWidgetOutputs->currentItem();
//QTreeWidgetItem *outputItem1 = ui->treeWidgetOutputs->currentItem();
}
UComponentLinksWidget::~UComponentLinksWidget()
......@@ -233,7 +233,7 @@ void UComponentLinksWidget::unInit()
void UComponentLinksWidget::switchLink()
{
QString output1Component, outputName1, output2Component, outputName2;
QModelIndex id = ui->treeWidgetOutputs->currentIndex();
//QModelIndex id = ui->treeWidgetOutputs->currentIndex();
QTreeWidgetItem *outputItem1 = ui->treeWidgetOutputs->currentItem();
QTreeWidgetItem *outputItem2 = ui->treeWidgetInputs->currentItem();
......@@ -341,7 +341,7 @@ void UComponentLinksWidget::createLink()
else if(mode==3)
{
QString output1Component, outputName1, output2Component, outputName2;
QModelIndex id = ui->treeWidgetOutputs->currentIndex();
//QModelIndex id = ui->treeWidgetOutputs->currentIndex();
QTreeWidgetItem *outputItem1 = ui->treeWidgetOutputs->currentItem();
QTreeWidgetItem *outputItem2 = ui->treeWidgetInputs->currentItem();
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment