Lines Matching refs:rcft
452 char* path = rtcp->rcft.rcfd.fName; in GetFileDownloadResponseMsgInBlocks()
456 if((rtcp->rcft.rcfd.downloadInProgress == FALSE) && (rtcp->rcft.rcfd.downloadFD == -1)) { in GetFileDownloadResponseMsgInBlocks()
457 if((rtcp->rcft.rcfd.downloadFD = open(path, O_RDONLY)) == -1) { in GetFileDownloadResponseMsgInBlocks()
462 rtcp->rcft.rcfd.downloadInProgress = TRUE; in GetFileDownloadResponseMsgInBlocks()
464 if((rtcp->rcft.rcfd.downloadInProgress == TRUE) && (rtcp->rcft.rcfd.downloadFD != -1)) { in GetFileDownloadResponseMsgInBlocks()
465 if( (numOfBytesRead = read(rtcp->rcft.rcfd.downloadFD, pBuf, SZ_RFBBLOCKSIZE)) <= 0) { in GetFileDownloadResponseMsgInBlocks()
466 close(rtcp->rcft.rcfd.downloadFD); in GetFileDownloadResponseMsgInBlocks()
467 rtcp->rcft.rcfd.downloadFD = -1; in GetFileDownloadResponseMsgInBlocks()
468 rtcp->rcft.rcfd.downloadInProgress = FALSE; in GetFileDownloadResponseMsgInBlocks()
470 return CreateFileDownloadZeroSizeDataMsg(rtcp->rcft.rcfd.mTime); in GetFileDownloadResponseMsgInBlocks()
486 char* path = rtcp->rcft.rcfd.fName; in ChkFileDownloadErr()
502 rtcp->rcft.rcfd.mTime = stat_buf.st_mtime; in ChkFileDownloadErr()
633 if( (rtcp->rcft.rcfu.fName == NULL) || in ChkFileUploadErr()
634 (strlen(rtcp->rcft.rcfu.fName) == 0) || in ChkFileUploadErr()
635 ((rtcp->rcft.rcfu.uploadFD = creat(rtcp->rcft.rcfu.fName, in ChkFileUploadErr()
643 rtcp->rcft.rcfu.uploadInProgress = TRUE; in ChkFileUploadErr()
667 numOfBytesWritten = write(rtcp->rcft.rcfu.uploadFD, pBuf, rtcp->rcft.rcfu.fSize); in ChkFileUploadWriteErr()
669 if(numOfBytesWritten != rtcp->rcft.rcfu.fSize) { in ChkFileUploadWriteErr()
686 utb.actime = utb.modtime = rtcp->rcft.rcfu.mTime; in FileUpdateComplete()
687 if(utime(rtcp->rcft.rcfu.fName, &utb) == -1) { in FileUpdateComplete()
690 __FUNCTION__, rtcp->rcft.rcfu.fName); in FileUpdateComplete()
693 if(rtcp->rcft.rcfu.uploadFD != -1) { in FileUpdateComplete()
694 close(rtcp->rcft.rcfu.uploadFD); in FileUpdateComplete()
695 rtcp->rcft.rcfu.uploadFD = -1; in FileUpdateComplete()
696 rtcp->rcft.rcfu.uploadInProgress = FALSE; in FileUpdateComplete()
745 if(rtcp->rcft.rcfu.uploadInProgress == TRUE) { in CloseUndoneFileTransfer()
746 rtcp->rcft.rcfu.uploadInProgress = FALSE; in CloseUndoneFileTransfer()
748 if(rtcp->rcft.rcfu.uploadFD != -1) { in CloseUndoneFileTransfer()
749 close(rtcp->rcft.rcfu.uploadFD); in CloseUndoneFileTransfer()
750 rtcp->rcft.rcfu.uploadFD = -1; in CloseUndoneFileTransfer()
753 if(unlink(rtcp->rcft.rcfu.fName) == -1) { in CloseUndoneFileTransfer()
755 __FILE__, __FUNCTION__, rtcp->rcft.rcfu.fName); in CloseUndoneFileTransfer()
758 memset(rtcp->rcft.rcfu.fName, 0 , PATH_MAX); in CloseUndoneFileTransfer()
761 if(rtcp->rcft.rcfd.downloadInProgress == TRUE) { in CloseUndoneFileTransfer()
762 rtcp->rcft.rcfd.downloadInProgress = FALSE; in CloseUndoneFileTransfer()
764 if(rtcp->rcft.rcfd.downloadFD != -1) { in CloseUndoneFileTransfer()
765 close(rtcp->rcft.rcfd.downloadFD); in CloseUndoneFileTransfer()
766 rtcp->rcft.rcfd.downloadFD = -1; in CloseUndoneFileTransfer()
768 memset(rtcp->rcft.rcfd.fName, 0 , PATH_MAX); in CloseUndoneFileTransfer()