Error C2036 (unknown size) when creating default structure

I am porting the server-list of a game to my own system in order for players to connect to gameservers (since the old GameSpy system shut down in June).
I am having to access a function inside a class that currently does not have a default constructor, so I created it with CMultiPlayerMenu() {};, but however I am now getting this error:
Error 1 error C2036: 'SStoredServer *' : unknown size C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\vector 1628 1 GameDll

I have not touched the source file where this variable (a struct) is declared in, and I have absolutely no idea why I am recieving this error.
I've searched this on the internet, but however didn't find anything relevant to my issue- what exactly is wrong and how do I fix this?

MultiplayerMenu.h:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
#ifndef __MULTIPLAYERMENU_H__
#define __MULTIPLAYERMENU_H__

#pragma once

#include "IFlashPlayer.h"
#include "MPHub.h"

struct  IServerBrowser;
struct  INetworkChat;
class   CGameNetworkProfile;
#include "MPLobbyUI.h"
struct  SStoredServer;

class CMultiPlayerMenu
{
public:
  struct SGSBrowser;
  struct SGSNetworkProfile;
  struct SChat;
  struct SCreateGame;

  class  CUI;
public:
	CMultiPlayerMenu(bool lan, IFlashPlayer* plr, CMPHub* hub);
	~CMultiPlayerMenu();
	CMultiPlayerMenu() {};
	bool HandleFSCommand(EGsUiCommand cmd, const char* pArgs);
	std::auto_ptr<CUI> GetLobbyUI() { return m_ui; };
  void OnUIEvent(const SUIEvent& event);
  void    DisplayServerList();
  void    SetServerListPos(double sb_pos);
  void    ChangeServerListPos(int dir);//either +1 or -1
  void    UpdateServerList();
  void    StopServerListUpdate();
  void    SelectServer(int id);
  void    JoinServer();
	void    ServerListUpdated();
	void    OnRefreshComplete(bool ok);
  
  IServerBrowser*             m_browser;
  CGameNetworkProfile*        m_profile;
  INetworkChat*               m_chat;
  std::auto_ptr<CUI>          m_ui;
  std::auto_ptr<SGSBrowser>   m_serverlist;
  std::auto_ptr<SChat>        m_chatlist;
  std::auto_ptr<SGSNetworkProfile> m_buddylist;
  std::auto_ptr<SCreateGame>  m_creategame;
  bool                        m_lan;
  std::vector<SStoredServer>  m_favouriteServers;
  std::vector<SStoredServer>  m_recentServers;
  CMPHub*                     m_hub;
	bool												m_joiningServer;
  
  EChatCategory               m_selectedCat;
  int                         m_selectedId;
};
#endif /*__MULTIPLAYERMENU_H__*/ 


SStoredServer is not used in the MultiplayerMenu.cpp file.
Sounds like std::vector wants to know its size.
Can you include SStoredServer's header at the top?
Registered users can post here. Sign in or register to post.