Skip to content

Commit

Permalink
Removed compiler warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
montywi committed Feb 10, 2018
1 parent 76dc6af commit 7ed0156
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions storage/sphinx/ha_sphinx.cc
Expand Up @@ -1041,8 +1041,8 @@ static bool ParseUrl ( CSphSEShare * share, TABLE * table, bool bCreate )
bool bOk = true;
bool bQL = false;
char * sScheme = NULL;
char * sHost = SPHINXAPI_DEFAULT_HOST;
char * sIndex = SPHINXAPI_DEFAULT_INDEX;
char * sHost = (char*) SPHINXAPI_DEFAULT_HOST;
char * sIndex = (char*) SPHINXAPI_DEFAULT_INDEX;
int iPort = SPHINXAPI_DEFAULT_PORT;

// parse connection string, if any
Expand All @@ -1068,12 +1068,12 @@ static bool ParseUrl ( CSphSEShare * share, TABLE * table, bool bCreate )
sHost--; // reuse last slash
iPort = 0;
if (!( sIndex = strrchr ( sHost, ':' ) ))
sIndex = SPHINXAPI_DEFAULT_INDEX;
sIndex = (char*) SPHINXAPI_DEFAULT_INDEX;
else
{
*sIndex++ = '\0';
if ( !*sIndex )
sIndex = SPHINXAPI_DEFAULT_INDEX;
sIndex = (char*) SPHINXAPI_DEFAULT_INDEX;
}
bOk = true;
break;
Expand All @@ -1095,19 +1095,19 @@ static bool ParseUrl ( CSphSEShare * share, TABLE * table, bool bCreate )
if ( sIndex )
*sIndex++ = '\0';
else
sIndex = SPHINXAPI_DEFAULT_INDEX;
sIndex = (char*) SPHINXAPI_DEFAULT_INDEX;

iPort = atoi(sPort);
if ( !iPort )
iPort = SPHINXAPI_DEFAULT_PORT;
iPort = SPHINXAPI_DEFAULT_PORT;
}
} else
{
sIndex = strchr ( sHost, '/' );
if ( sIndex )
*sIndex++ = '\0';
else
sIndex = SPHINXAPI_DEFAULT_INDEX;
sIndex = (char*) SPHINXAPI_DEFAULT_INDEX;
}
bOk = true;
break;
Expand Down Expand Up @@ -1303,8 +1303,8 @@ CSphSEQuery::CSphSEQuery ( const char * sQuery, int iLength, const char * sIndex
, m_sGeoLongAttr ( "" )
, m_fGeoLatitude ( 0.0f )
, m_fGeoLongitude ( 0.0f )
, m_sComment ( "" )
, m_sSelect ( "*" )
, m_sComment ( (char*) "" )
, m_sSelect ( (char*) "*" )

, m_pBuf ( NULL )
, m_pCur ( NULL )
Expand Down

0 comments on commit 7ed0156

Please sign in to comment.