internal Stream MakeResponseStream()
        {
            var state = new WinHttpRequestState();

            state.Pin();
            var handle = new FakeSafeWinHttpHandle(true);

            handle.Callback     = WinHttpRequestCallback.StaticCallbackDelegate;
            handle.Context      = state.ToIntPtr();
            state.RequestHandle = handle;

            return(new WinHttpResponseStream(handle, state, new HttpResponseMessage()));
        }
Beispiel #2
0
        internal Stream MakeRequestStream()
        {
            var state = new WinHttpRequestState();

            state.Pin();
            var handle = new FakeSafeWinHttpHandle(true);

            handle.Callback     = WinHttpRequestCallback.StaticCallbackDelegate;
            handle.Context      = state.ToIntPtr();
            state.RequestHandle = handle;

            return(new WinHttpRequestStream(state, WinHttpChunkMode.None));
        }
        internal Stream MakeResponseStream()
        {
            var state = new WinHttpRequestState();
            state.Pin();
            var handle = new FakeSafeWinHttpHandle(true);
            handle.Callback = WinHttpRequestCallback.StaticCallbackDelegate;
            handle.Context = state.ToIntPtr();
            state.RequestHandle = handle;

            return new WinHttpResponseStream(handle, state);
        }