---
name: "CoMarshalInterThreadInterfaceInStream"
section: "3w"
platform: "linux"
package: "libwine-dev"
version: "1.4.1-4"
release: "Debian 7 (Wheezy)"
platforms: ["linux"]
url: "https://new.carta.tech/CoMarshalInterThreadInterfaceInStream"
---

# CoMarshalInterThreadInterfaceInStream(3w)

## NAME

**CoMarshalInterThreadInterfaceInStream** (OLE32.@)

## SYNOPSIS

HRESULT CoMarshalInterThreadInterfaceInStream\
  (\
   REFIID    *riid*,\
   LPUNKNOWN *pUnk*,\
   LPSTREAM\* *ppStm*\
  )

## DESCRIPTION

Marshal an interface across threads in the same process.

## PARAMS

*riid* **\[In\]**  Identifier of the interface to be marshalled.

*pUnk* **\[In\]**  Pointer to IUnknown-derived interface that will be marshalled.

*ppStm* **\[Out\]**  Pointer to **IStream** object that is created and then used to store the marshalled interface.

## RETURNS

**Success:** **S\_OK**

**Failure:** **E\_OUTOFMEMORY** and other **COM** error codes.

## SEE ALSO

CoMarshalInterface(), **[CoUnmarshalInterface(3w)](/CoUnmarshalInterface/3w.md)** and **[CoGetInterfaceAndReleaseStream(3w)](/CoGetInterfaceAndReleaseStream/3w.md)**

## IMPLEMENTATION

Declared in **"objbase.h"**.

Implemented in **"dlls/ole32/marshal.c"**.

Debug channel **"ole"**.
