# This patch file was generated by NetBeans IDE
# It uses platform neutral UTF-8 encoding and \n newlines.
--- Base (BASE)
+++ Locally Modified (Based On LOCAL)
@@ -296,9 +296,13 @@
i++;
}
}
+ Sql_FreeResult(sql_handle);
- if(!i) //No items found - No need to continue
+ if(!i) {//No items found - No need to continue
+ SqlStmt_Free(stmt);
+ StringBuf_Destroy(&buf);
return 0;
+ }
//First we delete the character's items
StringBuf_Clear(&buf);
@@ -311,7 +315,6 @@
StringBuf_Printf(&buf, " `id`=%d",items[j].id);
}
- stmt = SqlStmt_Malloc(sql_handle);
if( SQL_ERROR == SqlStmt_PrepareStr(stmt, StringBuf_Value(&buf))
|| SQL_ERROR == SqlStmt_Execute(stmt) )
{
@@ -342,7 +345,6 @@
StringBuf_AppendStr(&buf, ")");
}
- stmt = SqlStmt_Malloc(sql_handle);
if( SQL_ERROR == SqlStmt_PrepareStr(stmt, StringBuf_Value(&buf))
|| SQL_ERROR == SqlStmt_Execute(stmt) )
{
@@ -352,6 +354,8 @@
return 1;
}
+ SqlStmt_Free(stmt);
+ StringBuf_Destroy(&buf);
//Finally reload storage and tell map we're done
mapif_load_guild_storage(fd,aid,guild_id,0);
mapif_itembound_ack(fd,aid,guild_id);