[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] patch:XaAES:taskman



Am 09.01.2010, 22:30 Uhr, schrieb Vincent Rivière <vincent.riviere@freesbee.fr>:

Helmut Karlowski wrote:
-							(const char *)t.text = title;
+							char *tx = wi->wname;
+							t.text = tx;

t.text is char*
title is const char *

So the obvious fix is:
t.text = (char*)title;

Your patch is correct, but unnecessary complex.

If I recall right, gcc 2.95 didn't want this.

../taskman.c:393: warning: cast discards qualifiers from pointer target type

That's why I did this weird cast. But it is still suboptimal - title doesn't need to be assigned at all.

-Helmut