Welcome, Guest. Please login or register.

Author Topic: Where's da bug  (Read 3239 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline itix

  • Hero Member
  • *****
  • Join Date: Oct 2002
  • Posts: 2380
    • Show all replies
Re: Where's da bug
« on: August 31, 2004, 10:10:44 PM »
Funny but my autodocs are saying that CreateProc() returns struct MsgPort * ...
My Amigas: A500, Mac Mini and PowerBook
 

Offline itix

  • Hero Member
  • *****
  • Join Date: Oct 2002
  • Posts: 2380
    • Show all replies
Re: Where's da bug
« Reply #1 on: August 31, 2004, 10:30:16 PM »
Quote
Documentation error?

As far as I recall, CreateMsgPort() should return struct MsgPort*, not CreateProc().

It is funny but looks intentional. Even my good old RKRM: Includes and Autodocs is saying CreateProc() returns struct MsgPort *.
My Amigas: A500, Mac Mini and PowerBook
 

Offline itix

  • Hero Member
  • *****
  • Join Date: Oct 2002
  • Posts: 2380
    • Show all replies
Re: Where's da bug
« Reply #2 on: August 31, 2004, 10:53:18 PM »
Quote
if (!(buffertask = (MsgPort *)CreateProc(Buffertaskname, 0L, buffertaskSegList, 1000L)))

Your casting is wrong. It should be (struct MsgPort *), just (MsgPort *) alone is nothing and VBCC complains.

And, do you have:

struct Process *buffertask;

?

If so, it is broken because it is not returning struct Process *...
My Amigas: A500, Mac Mini and PowerBook