Skip to content

Instantly share code, notes, and snippets.

@j0sh
Created November 16, 2011 03:54
Show Gist options
  • Select an option

  • Save j0sh/1369191 to your computer and use it in GitHub Desktop.

Select an option

Save j0sh/1369191 to your computer and use it in GitHub Desktop.
Check for valid input to GetProtocolHandler.
diff --git a/sources/thelib/src/application/baseclientapplication.cpp b/sources/thelib/src/application/baseclientapplication.cpp
index f308186..063b179 100644
--- a/sources/thelib/src/application/baseclientapplication.cpp
+++ b/sources/thelib/src/application/baseclientapplication.cpp
@@ -154,6 +154,7 @@ bool BaseClientApplication::StreamNameAvailable(string streamName,
}
BaseAppProtocolHandler *BaseClientApplication::GetProtocolHandler(BaseProtocol *pProtocol) {
+ if (NULL == pProtocol) return NULL;
return GetProtocolHandler(pProtocol->GetType());
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment