From c1f1646dabefe773c7b069c797e6bd56c517c6e3 Mon Sep 17 00:00:00 2001 From: Akash Date: Thu, 22 Oct 2015 19:33:34 +0530 Subject: [PATCH 01/12] GSDX: Initialize class members CID 146973 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)2. uninit_member: Non-static class member overflow is not initialized in this constructor nor in any functions that it calls. 2999} --- plugins/GSdx/GSState.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/plugins/GSdx/GSState.cpp b/plugins/GSdx/GSState.cpp index b6b66fd038..0c6f6154dd 100644 --- a/plugins/GSdx/GSState.cpp +++ b/plugins/GSdx/GSState.cpp @@ -2994,6 +2994,7 @@ bool GSState::IsMipMapActive() GSState::GSTransferBuffer::GSTransferBuffer() { x = y = 0; + overflow = false; start = end = total = 0; buff = (uint8*)_aligned_malloc(1024 * 1024 * 4, 32); } From 61e1686da373c7c036989ad302b7063b22a08305 Mon Sep 17 00:00:00 2001 From: Akash Date: Thu, 22 Oct 2015 20:15:33 +0530 Subject: [PATCH 02/12] GUI: Initialize all class members CID 146977 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)6. uninit_member: Non-static class member SizeInMB is not initialized in this constructor nor in any functions that it calls. --- pcsx2/gui/Panels/MemoryCardPanels.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pcsx2/gui/Panels/MemoryCardPanels.h b/pcsx2/gui/Panels/MemoryCardPanels.h index f484d2cf0f..6b4ad36623 100644 --- a/pcsx2/gui/Panels/MemoryCardPanels.h +++ b/pcsx2/gui/Panels/MemoryCardPanels.h @@ -62,11 +62,14 @@ struct McdSlotItem McdSlotItem() { - Slot = -1; + Slot = -1; + SizeInMB = 0; + Type = MemoryCard_None; IsPSX = false; IsPresent = false; IsEnabled = false; + IsFormatted = false; } }; From 578b75aa761b4a309b9d58d5bf8c96ddbfeed07e Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 13:57:33 +0530 Subject: [PATCH 03/12] GUI: Initialize all class members CID 146978 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)4. uninit_member: Non-static class member s_rightside_buttons is not initialized in this constructor nor in any functions that it calls. --- pcsx2/gui/Panels/MemoryCardListPanel.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pcsx2/gui/Panels/MemoryCardListPanel.cpp b/pcsx2/gui/Panels/MemoryCardListPanel.cpp index d9371ff7f4..fdf11893f7 100644 --- a/pcsx2/gui/Panels/MemoryCardListPanel.cpp +++ b/pcsx2/gui/Panels/MemoryCardListPanel.cpp @@ -190,6 +190,8 @@ Panels::BaseMcdListPanel::BaseMcdListPanel( wxWindow* parent ) ); m_listview = NULL; + s_leftside_buttons = NULL; + s_rightside_buttons = NULL; m_btn_Refresh = new wxButton( this, wxID_ANY, _("Refresh list") ); From c912064c8d589f1070545ae2d01bda220c391264 Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 14:11:04 +0530 Subject: [PATCH 04/12] GUI: Initialize all class members CID 146979 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)2. uninit_member: Non-static class member m_miscGroup is not initialized in this constructor nor in any functions that it calls. --- pcsx2/gui/Panels/LogOptionsPanels.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pcsx2/gui/Panels/LogOptionsPanels.h b/pcsx2/gui/Panels/LogOptionsPanels.h index 967d6fc2d4..b7d51f4ef8 100644 --- a/pcsx2/gui/Panels/LogOptionsPanels.h +++ b/pcsx2/gui/Panels/LogOptionsPanels.h @@ -28,8 +28,8 @@ namespace Panels wxStaticBoxSizer* m_miscGroup; public: - BaseCpuLogOptionsPanel( wxWindow* parent, const wxString& title, wxOrientation orient=wxVERTICAL ) - : CheckedStaticBox( parent, orient, title ) {} + BaseCpuLogOptionsPanel(wxWindow* parent, const wxString& title, wxOrientation orient = wxVERTICAL) + : CheckedStaticBox(parent, orient, title), m_miscGroup(NULL){} virtual wxStaticBoxSizer* GetMiscGroup() const { return m_miscGroup; } virtual CheckedStaticBox* GetStaticBox( const wxString& subgroup ) const=0; From 589e838fa036a37d8296f8fdfeb25dad9870751e Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 14:54:45 +0530 Subject: [PATCH 05/12] GUI: Initialize all class members CID 146980 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)2. uninit_member: Non-static class member m_panel is not initialized in this constructor nor in any functions that it calls. --- pcsx2/gui/Panels/PluginSelectorPanel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pcsx2/gui/Panels/PluginSelectorPanel.cpp b/pcsx2/gui/Panels/PluginSelectorPanel.cpp index ec1d4118e7..99e3f433fe 100644 --- a/pcsx2/gui/Panels/PluginSelectorPanel.cpp +++ b/pcsx2/gui/Panels/PluginSelectorPanel.cpp @@ -227,7 +227,7 @@ protected: IMPLEMENT_DYNAMIC_CLASS(ApplyPluginsDialog, WaitForTaskDialog) ApplyPluginsDialog::ApplyPluginsDialog( BaseApplicableConfigPanel* panel ) - : WaitForTaskDialog( _("Applying settings...") ) +: WaitForTaskDialog(_("Applying settings...")), m_panel(NULL) { GetSysExecutorThread().PostEvent( new SysExecEvent_ApplyPlugins( this, m_sync ) ); } From 55a88688a3aa6154ea0a6f17b45ae45770ef850f Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 19:58:21 +0530 Subject: [PATCH 06/12] GUI: Initialize all class members CID 146984 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)6. uninit_member: Non-static class member m_performFileWrites is not initialized in this constructor nor in any functions that it calls. --- pcsx2/gui/MemoryCardFolder.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pcsx2/gui/MemoryCardFolder.cpp b/pcsx2/gui/MemoryCardFolder.cpp index f9acb749d0..2f6885af4e 100644 --- a/pcsx2/gui/MemoryCardFolder.cpp +++ b/pcsx2/gui/MemoryCardFolder.cpp @@ -29,6 +29,9 @@ bool RemoveDirectory( const wxString& dirname ); FolderMemoryCard::FolderMemoryCard() { m_slot = 0; m_isEnabled = false; + m_performFileWrites = false; + m_framesUntilFlush = 0; + m_timeLastWritten = 0; } void FolderMemoryCard::InitializeInternalData() { From f95664e84643a6fbb7eb783612d29f1ec2f12251 Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 20:13:42 +0530 Subject: [PATCH 07/12] GUI: Initialize all class members CID 146990 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)6. uninit_member: Non-static class member PluginId is not initialized in this constructor nor in any functions that it calls. --- pcsx2/gui/MainFrame.h | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/pcsx2/gui/MainFrame.h b/pcsx2/gui/MainFrame.h index 71d75da5a2..b8417d1d1a 100644 --- a/pcsx2/gui/MainFrame.h +++ b/pcsx2/gui/MainFrame.h @@ -47,22 +47,12 @@ protected: // A list of menu items belonging to this plugin's menu. MenuItemAddonList m_PluginMenuItems; - // Base index for inserting items, usually points to the position - // after the heading entry and separator. - int m_InsertIndexBase; - - // Current index for inserting menu items; increments with each item - // added by a plugin. - int m_InsertIndexCur; - public: PluginsEnum_t PluginId; - wxMenu& MyMenu; + wxMenu& MyMenu; public: - PerPluginMenuInfo() : MyMenu( *new wxMenu() ) - { - } + PerPluginMenuInfo() : MyMenu(*new wxMenu()), PluginId (PluginId_Count) {} virtual ~PerPluginMenuInfo() throw(); @@ -226,4 +216,4 @@ protected: friend class Pcsx2App; }; -extern int GetPluginMenuId_Settings( PluginsEnum_t pid ); \ No newline at end of file +extern int GetPluginMenuId_Settings( PluginsEnum_t pid ); From 1512b3ba6c641d11bc25462545641582b067a45c Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 20:22:21 +0530 Subject: [PATCH 08/12] pcsx2-debug: Initialize all class members CID 146995 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)member_not_init_in_gen_ctor: The compiler-generated constructor for this class does not initialize cpu --- pcsx2/DebugTools/DisassemblyManager.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pcsx2/DebugTools/DisassemblyManager.h b/pcsx2/DebugTools/DisassemblyManager.h index 068e105311..9058b9f5f0 100644 --- a/pcsx2/DebugTools/DisassemblyManager.h +++ b/pcsx2/DebugTools/DisassemblyManager.h @@ -206,7 +206,7 @@ public: private: DisassemblyEntry* getEntry(u32 address); std::map entries; - DebugInterface* cpu; + DebugInterface* cpu = NULL; static int maxParamChars; }; From b2ee732321ab59e4d4ce3c448e2f1ed0ae9d5698 Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 20:26:04 +0530 Subject: [PATCH 09/12] pcsx2-debug: Initialize all class members CID 147005 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)2. uninit_member: Non-static class member PrePrefix is not initialized in this constructor nor in any functions that it calls. --- pcsx2/DebugTools/Debug.h | 9 --------- 1 file changed, 9 deletions(-) diff --git a/pcsx2/DebugTools/Debug.h b/pcsx2/DebugTools/Debug.h index 9e9e4b0fdb..a55c0080ac 100644 --- a/pcsx2/DebugTools/Debug.h +++ b/pcsx2/DebugTools/Debug.h @@ -65,9 +65,6 @@ struct SysTraceLogDescriptor // logging volume). class SysTraceLog : public TextFileTraceLog { -public: - const char* PrePrefix; - public: TraceLog_ImplementBaseAPI(SysTraceLog) @@ -77,12 +74,6 @@ public: void DoWrite( const char *fmt ) const; - SysTraceLog& SetPrefix( const char* name ) - { - PrePrefix = name; - return *this; - } - }; class SysTraceLog_EE : public SysTraceLog From cfd02bff539a4baea355bec6bca2d912558c1c0b Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 20:30:47 +0530 Subject: [PATCH 10/12] Utilities: Initialize all class members CID 147010 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)4. uninit_member: Non-static class member Enabled is not initialized in this constructor nor in any functions that it calls. --- common/include/Utilities/TraceLog.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/include/Utilities/TraceLog.h b/common/include/Utilities/TraceLog.h index 0426b02b13..5884100cf8 100644 --- a/common/include/Utilities/TraceLog.h +++ b/common/include/Utilities/TraceLog.h @@ -77,7 +77,7 @@ public: bool Enabled; protected: - BaseTraceLogSource() {} + BaseTraceLogSource() : m_Descriptor(NULL), Enabled(false) {} public: TraceLog_ImplementBaseAPI(BaseTraceLogSource) From f6f8dc1a22e0bca7cc9b8d04e302301012f5c66a Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 20:36:02 +0530 Subject: [PATCH 11/12] CDVD: Initialze all class members CID 147025 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)8. uninit_member: Non-static class member m_current_count is not initialized in this constructor nor in any functions that it calls. --- pcsx2/CDVD/InputIsoFile.cpp | 3 +++ pcsx2/CDVD/IsoFileFormats.h | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/pcsx2/CDVD/InputIsoFile.cpp b/pcsx2/CDVD/InputIsoFile.cpp index ca0b3dd010..e0012db3bc 100644 --- a/pcsx2/CDVD/InputIsoFile.cpp +++ b/pcsx2/CDVD/InputIsoFile.cpp @@ -179,7 +179,10 @@ void InputIsoFile::_init() m_read_inprogress = false; m_read_count = 0; + ReadUnit = 0; + m_current_lsn = -1; m_read_lsn = -1; + m_reader = NULL; } // Tests the specified filename to see if it is a supported ISO type. This function typically diff --git a/pcsx2/CDVD/IsoFileFormats.h b/pcsx2/CDVD/IsoFileFormats.h index c390fb510a..d528afdbe9 100644 --- a/pcsx2/CDVD/IsoFileFormats.h +++ b/pcsx2/CDVD/IsoFileFormats.h @@ -48,7 +48,6 @@ protected: AsyncFileReader* m_reader; s32 m_current_lsn; - uint m_current_count; isoType m_type; u32 m_flags; From e4490694f18f8e76a9ce0543a24873714d8308a8 Mon Sep 17 00:00:00 2001 From: Akash Date: Fri, 23 Oct 2015 20:45:12 +0530 Subject: [PATCH 12/12] SPU2-X: Initialize all class members CID 147033 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR)16. uninit_member: Non-static class member ActualPaCallback is not initialized in this constructor nor in any functions that it calls. --- plugins/spu2-x/src/SndOut_Portaudio.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/plugins/spu2-x/src/SndOut_Portaudio.cpp b/plugins/spu2-x/src/SndOut_Portaudio.cpp index 8afa70a886..e42c77f7db 100644 --- a/plugins/spu2-x/src/SndOut_Portaudio.cpp +++ b/plugins/spu2-x/src/SndOut_Portaudio.cpp @@ -110,11 +110,18 @@ public: Portaudio() { - m_ApiId=-1; m_SuggestedLatencyMinimal = true; + m_UseHardware = false; + m_WasapiExclusiveMode = false; + started = false; + stream = NULL; + ActualPaCallback = NULL; + m_ApiId=-1; m_SuggestedLatencyMS = 20; - actualUsedChannels = 0; + writtenSoFar = 0; + writtenLastTime = 0; + availableLastTime = 0; } s32 Init()