Sjoerd Mullender wrote:
> Romulo Goncalves wrote:
>> Stefan Manegold wrote:
>>> Update of /cvsroot/monetdb/sql/src/server
>>> In directory sc8-pr-cvs16:/tmp/cvs-serv14592/src/server
>>>
>>> Modified Files:
>>> sql_schema.mx
>>> Log Message:
>>>
>>> [since I spent (almost) all night and morning on compiling & testing,
>>> anyway:]
>>>
>>> for the umpteenth time:
>>> make SQL compile with icc, again, by removind set but unused variable
>>> --- some more concentration during coding might save us quite some time ....
>>>
>>>
>>> Romulo,
>>>
>>> could you please check, whether the code still complies with you intention?
>>>
>>>
>>> Index: sql_schema.mx
>>> ===================================================================
>>> RCS file: /cvsroot/monetdb/sql/src/server/sql_schema.mx,v
>>> retrieving revision 1.122
>>> retrieving revision 1.123
>>> diff -u -d -r1.122 -r1.123
>>> --- sql_schema.mx 17 Apr 2007 12:27:07 -0000 1.122
>>> +++ sql_schema.mx 18 Apr 2007 09:16:26 -0000 1.123
>>> @@ -602,11 +602,10 @@
>>> {
>>> char *tname = qname_table(qname);
>>> sql_schema *ss = cur_schema(sql);
>>> - sql_trigger * t= NULL;
>>>
>>> if (!schema_privs(sql->role_id, ss))
>>> return sql_error(sql, 02, "DROP TRIGGER: access denied for %s
>>> to schema ;'%s'", stack_get_string(sql, "current_user"), ss->base.name);
>>> - if ((t = mvc_bind_trigger(sql, ss, tname )) == NULL)
>>> + if (mvc_bind_trigger(sql, ss, tname ) == NULL)
>> Why I should not use the t? I found similar examples in the code. Maybe
>> the the t was used after.
>> I agree with this change I think it does affect the semantics of the
>> function.
>
> If you look at the code, the t was not used anywhere in that function.
> It was assigned a value, and that's it. That's what icc warns about
> (and rightly so!). Stefan's question boils down to the question, should
> that t have been used after it had been assigned, i.e. did you need to
> do anything with the result of the function call? If not, then the
> assignment and hence the variable was superfluous.
In the last checkin I removed the line where the t (the trigger) was
used. Not using the icc compiler I did not realize that the t was not
used anymore. You are right it was my mistake. Next time I will try to
check this things.
Regards,
Romulo
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Monetdb-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-developers