microsoft.public.windows.backgroundtransfer
[Top] [All Lists]

Neverending Transient Error

Subject: Neverending Transient Error
From: "Edward"
Date: 5 May 2005 02:28:07 -0700
Newsgroups: microsoft.public.windows.backgroundtransfer
Hi I'm using BITS in my program to download files.  The bits code works
on most machines but fails on a certain test machine.  I've traced the
problem to a neverending BG_JOB_STATE_TRANSIENT_ERROR.  Calling
IBackgroundCopyJob::Resume doesn't seem to continue the download.

Here is a pseudo code of the download loop: [Note this is done on a
worker thread]

while( !m_userCancelledDownload ) {
    m_downloadJob->GetState( &jobState );

    if( jobState == BG_JOB_STATE_TRANSFERRED ) {
        break;
    }
    else if( jobState == BG_JOB_STATE_TRANSIENT_ERROR ) {
        m_downloadJob->Resume();
    }
    // handle other specific conditions

    ::Sleep( pollingLength );
}

That code is a stripped down version, minus all status setting code.
That code works fine except on one machine and I traced the problem
down to a jobState that was continuously returning
BG_JOB_STATE_TRANSIENT_ERROR.  The machine in question is running
Win2k.sp4.  Any ideas what could be wrong?

Thanks,
Edward


<Prev in Thread] Current Thread [Next in Thread>
Privacy Policy