private static void CallAsyncMethod(VssAsyncMethod method)
        {
            IVssAsync async;
            int       reserved = 0;
            uint      hResult;

            method(out async);

            async.Wait(60 * 1000);

            async.QueryStatus(out hResult, ref reserved);

            if (hResult != 0 && hResult != 0x0004230a /* VSS_S_ASYNC_FINISHED */)
            {
                Marshal.ThrowExceptionForHR((int)hResult);
            }
        }
Example #2
0
        private static void CallAsyncMethod(VssAsyncMethod method)
        {
            IVssAsync async;
            int reserved = 0;
            uint hResult;

            method(out async);

            async.Wait(60 * 1000);

            async.QueryStatus(out hResult, ref reserved);

            if (hResult != 0 && hResult != 0x0004230a /* VSS_S_ASYNC_FINISHED */)
            {
                Marshal.ThrowExceptionForHR((int)hResult);
            }
        }