Permalink
Browse files

CurlFile: add "GetServerReportedCharset" function

  • Loading branch information...
1 parent 4d63ef9 commit 05e35cd1e40de19263c066d751a07361b5867cd5 @Karlson2k Karlson2k committed Aug 18, 2013
Showing with 9 additions and 0 deletions.
  1. +8 −0 xbmc/filesystem/CurlFile.cpp
  2. +1 −0 xbmc/filesystem/CurlFile.h
@@ -1546,6 +1546,14 @@ void CCurlFile::SetRequestHeader(CStdString header, long value)
m_requestheaders[header] = buffer;
}
+std::string CCurlFile::GetServerReportedCharset(void)
+{
+ if (!m_state)
+ return "";
+
+ return m_state->m_httpheader.GetCharset();
+}
+
/* STATIC FUNCTIONS */
bool CCurlFile::GetHttpHeader(const CURL &url, CHttpHeader &headers)
{
@@ -90,6 +90,7 @@ namespace XFILE
void SetBufferSize(unsigned int size);
const CHttpHeader& GetHttpHeader() { return m_state->m_httpheader; }
+ std::string GetServerReportedCharset(void);
/* static function that will get content type of a file */
static bool GetHttpHeader(const CURL &url, CHttpHeader &headers);

0 comments on commit 05e35cd

Please sign in to comment.