On Wed, 2006-07-12 at 02:28 +0530, Ritesh Khadgaray wrote:
out of curiosity, the first patch reads through the list
and this patch, return if any one of the token is equal, anf not any
following it.
Would the below not be better ?
for (i = 0; i tokens_len; i ++)
On Tue, 2006-07-11 at 09:28 -0400, Chris Toshok wrote:
No opinion on the rest of the patch, but this:
+static void
+free_token (gchar *token)
+{
+ gint i=0;
+ gboolean no=FALSE;
+
+ for (i=0; (i tokens_len); i++)
+ {
+ if (tokens[i] ==
On Wed, 2006-07-12 at 02:27 +0530, Ritesh Khadgaray wrote:
On Tue, 2006-07-11 at 09:28 -0400, Chris Toshok wrote:
No opinion on the rest of the patch, but this:
+static void
+free_token (gchar *token)
+{
+ gint i=0;
+ gboolean no=FALSE;
+
+ for (i=0; (i
On Tue, 2006-07-11 at 17:06 -0400, Chris Toshok wrote:
On Wed, 2006-07-12 at 02:28 +0530, Ritesh Khadgaray wrote:
out of curiosity, the first patch reads through the list
and this patch, return if any one of the token is equal, anf not any
following it.
Would the below not be better
On Tue, 2006-07-11 at 09:28 -0400, Chris Toshok wrote:
static void
free_token (gchar *token)
{
gint i;
for (i = 0; i tokens_len; i ++)
if (tokens[i] == token)
return;
g_free (token);
}
ps. Maybe for real efficiency you can also
No opinion on the rest of the patch, but this:
+static void
+free_token (gchar *token)
+{
+ gint i=0;
+ gboolean no=FALSE;
+
+ for (i=0; (i tokens_len); i++)
+ {
+ if (tokens[i] == token)
+ no = TRUE;
+ }
+
+ if
On Tue, 2006-07-11 at 09:28 -0400, Chris Toshok wrote:
No opinion on the rest of the patch, but this:
static void
free_token (gchar *token)
{
gint i;
for (i = 0; i tokens_len; i ++)
if (tokens[i] == token)
return;
g_free (token);