Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: CC_OPT_GETMISCINFO status ??? solution !!!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CC_OPT_GETMISCINFO status ??? solution !!!



On vendredi, juin 14, 2002, at 09:17 , Jirome Foucher wrote:

On vendredi, juin 14, 2002, at 12:01 , Herb Hrowal wrote:

Unfortunately, I always receive error -3151 (kOTBadOptionErr) when
trying to do that.
Only the PP_OPT_GETCURRENTSTATE call work.

This is a documented problem although I don't remember where we found the
answer. The solution is to modify the initialization of the TOption and
TOptMgmt structures. On both structures you need to set the len member
to the full size of the buffer instead of just the size of the TOption
structure. Just use the same value you use for maxlen.

After making this change our PPP status problems on X went away and things
still worked beautifully on 9.

Sorry, but this still doesn't work for me.
I've also been told to zero-out the structure before sending it to OTOptionManagement, but this also doesn't work.

I've enclosed my code below.

Can anyone point out what's wrong ?


I just answer to myself (and to whoever couldn't sleep last night) :

the solution is to :
allocate a buffer long enough. Mine was only sizeof(TOption)+ sizeof(CCMiscInfo).
I added a sizeof(UInt32)
zero it out
set the len members to the full size of the buffer.

And now it works perfectly !!

Thanks everybody for the help !

Now, anybody got the notifiers to work on Jaguar ?????

Jirome
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: CC_OPT_GETMISCINFO status ??? (From: Jérome Foucher <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.