Bug 31748

Summary: Make WebSocketHandleCFNet respect proxy auto-configuration files via CFProxySupport
Product: WebKit Reporter: Alexey Proskuryakov <ap>
Component: PlatformAssignee: Alexey Proskuryakov <ap>
Status: RESOLVED FIXED    
Severity: Normal    
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
proposed patch beidson: review+

Description Alexey Proskuryakov 2009-11-20 14:56:45 PST
Patch forthcoming.

We'll also need custom code for Tiger, which didn't have CFProxySupport.
Comment 1 Alexey Proskuryakov 2009-11-20 15:11:56 PST
Created attachment 43617 [details]
proposed patch
Comment 2 Oliver Hunt 2009-11-22 21:43:35 PST
Comment on attachment 43617 [details]
proposed patch

I don't get the change in SocketStreamHandle -- is the new code tiger safe?  You seem to have removed the tiger guard...

Nothing else seems to stand out as being wrong, but this code is to far from anything i really understand to be able to meaningfully review it sorry :-(
Comment 3 Alexey Proskuryakov 2009-11-22 22:06:41 PST
> You seem to have removed the tiger guard...

Not removed, just moved.
Comment 4 Brady Eidson 2009-11-23 12:36:30 PST
Comment on attachment 43617 [details]
proposed patch

We can't layout test PAC stuff, can we?

r=me but...

> -struct MainThreadEventCallbackInfo {
> -    MainThreadEventCallbackInfo(CFStreamEventType type, SocketStreamHandle* handle) : type(type), handle(handle) { }
> -    CFStreamEventType type;
> -    SocketStreamHandle* handle;
> -};
> +struct MainThreadEventCallbackInfo {
> +    MainThreadEventCallbackInfo(CFStreamEventType type, SocketStreamHandle* handle) : type(type), handle(handle) { }
> +    CFStreamEventType type;
> +    SocketStreamHandle* handle;
> +};

Maybe I'm blind, I don't know why this diff exists.

>  #if PLATFORM(WIN)
> -void SocketStreamHandle::readStreamCallbackMainThread(void* invocation)
> -{
> -    MainThreadEventCallbackInfo* info = static_cast<MainThreadEventCallbackInfo*>(invocation);
> -    info->handle->readStreamCallback(info->type);
> -}
> -
> -void SocketStreamHandle::writeStreamCallbackMainThread(void* invocation)
> -{
> -    MainThreadEventCallbackInfo* info = static_cast<MainThreadEventCallbackInfo*>(invocation);
> -    info->handle->writeStreamCallback(info->type);
> -}
> +void SocketStreamHandle::readStreamCallbackMainThread(void* invocation)
> +{
> +    MainThreadEventCallbackInfo* info = static_cast<MainThreadEventCallbackInfo*>(invocation);
> +    info->handle->readStreamCallback(info->type);
> +}
> +
> +void SocketStreamHandle::writeStreamCallbackMainThread(void* invocation)
> +{
> +    MainThreadEventCallbackInfo* info = static_cast<MainThreadEventCallbackInfo*>(invocation);
> +    info->handle->writeStreamCallback(info->type);
> +}

Or this one.
Comment 5 Alexey Proskuryakov 2009-11-23 13:01:16 PST
>We can't layout test PAC stuff, can we?

We don't have the infrastructure to test proxies at all.

>Maybe I'm blind, I don't know why this diff exists.

Inconsistent line endings somehow got into svn repository (even though svn usually prevents this). Xcode automatically cured the problem.

Committed <http://trac.webkit.org/changeset/51314>.