aboutsummaryrefslogtreecommitdiff
path: root/src/server/shared/Database/QueryResult.cpp
diff options
context:
space:
mode:
authorSubv <s.v.h21@hotmail.com>2012-02-14 12:46:26 -0500
committerSubv <s.v.h21@hotmail.com>2012-02-14 12:46:26 -0500
commit8a72aede1641ae19d539ed807e3bb0458c7a65e8 (patch)
tree19244d00341860f4f7f872af68763b9eaf2e0331 /src/server/shared/Database/QueryResult.cpp
parentf1182f0884e6d1eb5a279550d1b92d02cddb7c56 (diff)
Codestyle: Renamed some variables to fit codestyle, corrected order in structure/class fields to match alignment (they use slightly less memory now)
Signed-off-by: Subv <s.v.h21@hotmail.com>
Diffstat (limited to 'src/server/shared/Database/QueryResult.cpp')
-rwxr-xr-xsrc/server/shared/Database/QueryResult.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/server/shared/Database/QueryResult.cpp b/src/server/shared/Database/QueryResult.cpp
index dff055b8d3d..95034387089 100755
--- a/src/server/shared/Database/QueryResult.cpp
+++ b/src/server/shared/Database/QueryResult.cpp
@@ -20,13 +20,13 @@
#include "Log.h"
ResultSet::ResultSet(MYSQL_RES *result, MYSQL_FIELD *fields, uint64 rowCount, uint32 fieldCount) :
-m_rowCount(rowCount),
-m_fieldCount(fieldCount),
-m_result(result),
-m_fields(fields)
+_rowCount(rowCount),
+_fieldCount(fieldCount),
+_result(result),
+_fields(fields)
{
- m_currentRow = new Field[m_fieldCount];
- ASSERT(m_currentRow);
+ _currentRow = new Field[_fieldCount];
+ ASSERT(_currentRow);
}
PreparedResultSet::PreparedResultSet(MYSQL_STMT* stmt, MYSQL_RES *result, uint64 rowCount, uint32 fieldCount) :
@@ -150,18 +150,18 @@ bool ResultSet::NextRow()
{
MYSQL_ROW row;
- if (!m_result)
+ if (!_result)
return false;
- row = mysql_fetch_row(m_result);
+ row = mysql_fetch_row(_result);
if (!row)
{
CleanUp();
return false;
}
- for (uint32 i = 0; i < m_fieldCount; i++)
- m_currentRow[i].SetStructuredValue(row[i], m_fields[i].type);
+ for (uint32 i = 0; i < _fieldCount; i++)
+ _currentRow[i].SetStructuredValue(row[i], _fields[i].type);
return true;
}
@@ -196,16 +196,16 @@ bool PreparedResultSet::_NextRow()
void ResultSet::CleanUp()
{
- if (m_currentRow)
+ if (_currentRow)
{
- delete [] m_currentRow;
- m_currentRow = NULL;
+ delete [] _currentRow;
+ _currentRow = NULL;
}
- if (m_result)
+ if (_result)
{
- mysql_free_result(m_result);
- m_result = NULL;
+ mysql_free_result(_result);
+ _result = NULL;
}
}