亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? sites.c

?? 站點映像程序
?? C
?? 第 1 頁 / 共 4 頁
字號:
    for( search=the_site->files; search!=NULL; search=search->next ) {	if( search->diff != file_new )	    continue;	/* OK, we have us a new file... now iterate through the deleted	 * files and look for a match */	DEBUG( DEBUG_FILES, "- New file: %s\nComparing:", search->rel_local );	for( current=the_site->files; current!=NULL ; current=current->next ) {	    if( (current->diff != file_deleted) || current->dir ) {		/* Ignore files which aren't deleted, and dirs, completely.		 * (search->diff==file_new, so we DON'T need to check		 * that current != search as well) */		continue;	    }	    DEBUG( DEBUG_FILES, " %s", current->rel_local );	    if( (strcmp( search->filename, current->filename ) == 0) &&		current->remotesize == search->localsize &&		current->remotetime == search->localtime ) {		DEBUG( DEBUG_FILES, " - matched!\n" );		break;	    }	}	if( current != NULL ) {	    /* OK, current == the deleted file, search == the new file.	     * First make sure search knows where it WAS before the move... */	    search->old = current;	    /* Remove the deleted file from the list so it doesn't	     * actually get deleted by site_update */	    file_delete( the_site, current );	    /* Diddle the totals a bit */	    search->diff = file_moved;	    the_site->numdeleted--;	    the_site->numnew--;	    the_site->nummoved++;	} else {	    DEBUG( DEBUG_FILES, " - No match found.\n" );	}    }    DEBUG( DEBUG_FILES, "Finished checking for moved files.\n" );}/* This writes the remote files list back to the file * and has some hairy logic in the middle, but is otherwise * pretty simple. * TODO: This is crap. What we should really do is only  * write out the remote file info, regardless... that is what the  * info file is for. This would GREATLY simplify this entire function. * Would mean simply that in site_update, copying over the * modtimes + sizes. */#define WRITE_REMOTE_FILE( f ) \fprintf( fp, "%s\t%ld\t%ld\n", f->rel_remote, f->remotetime, f->remotesize );#define WRITE_LOCAL_FILE( f ) \fprintf( fp, "%s\t%ld\t%ld\n", f->rel_local, f->localtime, f->localsize );#define WRITE_REMOTE_LINK( f ) \fprintf( fp, "%s\t%s\t%s\n", f->rel_remote, LINKWORD, f->remotelink );#define WRITE_LOCAL_LINK( f ) \fprintf( fp, "%s\t%s\t%s\n", f->rel_local, LINKWORD, f->locallink );int site_writefiles( struct site_t *the_site ) {    FILE *fp;    struct site_file_t *current;    fp = fopen( the_site->infofile, "w" );    if( fp == NULL ) {	return -1;     }    for( current = the_site->files; current!=NULL; current=current->next ) {	if( current->dir ) {	    if( current->updated ) {		/* DIR: Updated */		switch( current->diff ) {		case file_new:		case file_unchanged:		    /* It's new, or it's already there... */		    fprintf( fp, "%s\t%s\n", current->rel_local, DIRWORD );		    break;		case file_moved: /* invalid */		case file_changed: /* invalid */		case file_deleted:/* it's not there now */		default:		    break;		} 	    } else {		/* DIR: Not Updated */		switch( current->diff ) {		case file_unchanged: /* ... it was there anyway */		case file_deleted: /* ... but it wasn't deleted */		    /* So the directory exists remotely */		    fprintf( fp, "%s\t%s\n", current->rel_remote, DIRWORD );		    break;		case file_new: /* ... but it wasn't created */		default:		    /* So the directory does not exist remotely */		    break;		}	    }	} else if( current->link ) {	    if( current->updated ) {		/* LINK: Updated */		switch( current->diff ) {		case file_new: /* it's there now */		case file_unchanged: /* it's still there now */		case file_changed: /* it's there now but differently */		    WRITE_LOCAL_LINK( current );		    break;		case file_deleted: /* it's not there now */		default: 		    break;		}	    } else {		/* LINK: Not Updated */		switch( current->diff ) {		case file_unchanged: /* it's still there anyway  */		case file_changed:   /* it's still there anyway */		case file_deleted: /* but actually still there */		    WRITE_REMOTE_LINK( current );		    break;		case file_new: /* it's not there */		default:		    break;		}	    }	} else {	    if( current->updated ) {		/* FILE: Updated */		switch( current->diff ) {		case file_unchanged:		    /* Write state of remote file */		    WRITE_REMOTE_FILE( current );		    break;		case file_moved:		case file_changed:		case file_new:		    /* Write state of local file */		    WRITE_LOCAL_FILE( current );		    break;		case file_deleted:		    /* So don't write anything out */		    break;		}	    } else {		/* FILE: Not Updated */		switch( current->diff ) {		case file_changed: /* ... but it hasn't been updated */		case file_unchanged: 		case file_deleted: /* ... but it hasn't been deleted */		    /* Write out the remote time */		    WRITE_REMOTE_FILE( current );		    break;		case file_moved: 		    /* But it hasn't actually been moved, so write out		     * the 'deleted' file (where the moved file WAS), and 		     * ignore the 'new' file (where it was moved TO) */		    WRITE_REMOTE_FILE( current->old );		    break;		case file_new: /* So ignore it... */		    break;		}	    }	}    }    fclose( fp );    return 0;}#undef WRITE_REMOTE_FILE#undef WRITE_LOCAL_FILE/* Simply marks all the files in the given site as 'updated'. * For 'dynamic updating', this will do, by diff== *   file_deleted: Remove the file from the list *   file_changed, file_new: Set diff=file_unchanged *   file_moved: Remove the ->old, set diff=file_unchanged *   file_unchanged: Do nothing. */void site_catchup( struct site_t *the_site ) {    struct site_file_t *current;    for( current=the_site->files; current!=NULL; current=current->next ) {	current->updated = true;    }    /* Mark it as mirrored */    the_site->is_different = false;}/* Reinitializes the site - clears any remote files * from the list, and marks all other files as 'new locally'. */void site_initialize( struct site_t *the_site ) {    struct site_file_t *current, *next;        current = the_site->files;    while( current!= NULL ) {	next = current->next;	switch( current->diff ) {	case file_deleted:	    file_delete( the_site, current );	    the_site->numdeleted--;	    break;	case file_moved:	    /* Current is the NEW file, current->old is the DELETED	     * file. So, simply nuke current->old. */	    current->old = NULL;	    current->updated = false;	    the_site->nummoved--;	    the_site->numnew++;	    current->diff = file_new;	    break;	case file_changed:	    current->updated = false;	    the_site->numchanged--;	    the_site->numnew++;	    current->diff = file_new;	    break;	case file_unchanged:	    current->updated = false;	    the_site->numunchanged--;	    the_site->numnew++;	    current->diff = file_new;	    break;	case file_new:	    current->updated = false;	    break;	}	current = next;    }        if( the_site->files == NULL ) {	/* There are no files remotely OR locally, so the	 * sites are the same */	the_site->is_different = false;    } else {	/* Otherwise, we KNOW that there are no files remotely	 * since we just removed them from memory, so any 	 * remaining files must be local ones. Hence, the sites	 * ARE different */	the_site->is_different = true;    }}/* This walks the files list as returned by the protocol driver, * and converts it into a 'real' files list. */void site_fetch_walk( struct site_t *the_site,		      struct proto_file_t *files ) {    struct proto_file_t *this_file, *next_file;    struct site_file_t *file;    char rel_local[BUFSIZ]; /* temporary */    site_destroy( the_site );    this_file = files;    while( this_file != NULL ) {	/* Check whether the filename is excluded.  Mock up a rel_local	 * for it. Bit noddy */	/* rel_local starts with a / */	rel_local[0] = '/'; rel_local[1] = '\0';	/* FIXME: Buffer ovverrun here. */	strcat( rel_local, this_file->directory );	strcat( rel_local, this_file->filename );		if( !file_isexcluded( this_file->filename, rel_local, the_site ) ) {	    /* Add the file to the list */	    if( this_file->isdir ) {		file = file_append( the_site );	    } else {		file = file_prepend( the_site );	    }	    	    /* Pointer copy the filename and directory strings...  nothing	     * to free out of this_file now. */	    file->filename = this_file->filename;	    file->directory = this_file->directory;	    file->dir = this_file->isdir;	    /* Sort out the names */	    site_assignnames( file, the_site );	    	    file->diff = file_deleted;	    file->updated = false;	    /* ... so, it exists remotely only and hasn't been deleted.	     * bit of a hack, but okay for the moment... */	    	    if( ! this_file->isdir ) {		file->remotesize = this_file->size;		file->remotetime = this_file->modtime;	    }	    	    fe_fetch_found( file );	    	}	next_file = this_file->next;	free( this_file );	this_file = next_file;    }}/* Updates the remote file list... site_fetch_callback is called for * every remote file found. */int site_fetch( struct site_t *the_site ) {    struct proto_file_t *files = NULL;    int ret;    if( CALL(fetch_list) == NULL ) {	return SITE_UNIMPL;    }    ret = proto_init( the_site );    if( ret != SITE_OK )	return ret;    ret = CALL(fetch_list)( the_site->remote_root, &files );    CALL(finish)( );        if( ret == PROTO_OK ) {	/* Copy over the list of files */	site_fetch_walk( the_site, files );	return SITE_OK;    } else {	return SITE_FAILED;    }}/* Destroys a file */void site_destroyfile( struct site_file_t *file ) {        free( file->directory );    free( file->filename );    free( file->full_local );    free( file->full_remote );    free( file->rel_local );    free( file->rel_remote );    free( file );}/* Called to delete all the files associated with the site */void site_destroy( struct site_t *the_site ) {    struct site_file_t *current, *next;    current = the_site->files;    while( current != NULL ) {	next = current->next;	if( current->old != NULL ) {	    site_destroyfile( current->old );	}	site_destroyfile( current );	current = next;    }    the_site->files = NULL;    the_site->files_tail = NULL;}/* Produces a section of the flat listing output, of all the items * with the given diff type in the given site, using the given section * name. */void site_flatlist_items( FILE *f, struct site_t *the_site, 			  const enum file_diff diff, const char *name ) {    struct site_file_t *current;    fprintf( f, "sectstart|%s", name );    putc( '\n', f );    for( current = the_site->files; current!=NULL; current=current->next) {	if( current->diff == diff ) {	    fprintf( f, "item|%s%s", current->rel_remote,		    current->dir?"/":"" );	    if( current->old !=NULL ) {		fprintf( f, "|%s\n", current->old->rel_remote );	    } else {		putc( '\n', f );	    }	    	}    }    fprintf( f, "sectend|%s\n", name );}/* Produce the flat listing output for the given site */void site_flatlist( FILE *f, struct site_t *the_site ) {    fprintf( f, "sitestart|%s", the_site->name );    if( the_site->url )	fprintf( f, "|%s", the_site->url );    putc( '\n', f );    if( the_site->numnew > 0 )	site_flatlist_items( f, the_site, file_new, "added" );    if( the_site->numchanged > 0 )	site_flatlist_items( f, the_site, file_changed, "changed" );    if( the_site->numdeleted > 0 )	site_flatlist_items( f, the_site, file_deleted, "deleted" );    if( the_site->nummoved > 0 )	site_flatlist_items( f, the_site, file_moved, "moved" );    fprintf( f, "siteend|%s\n", the_site->is_different?"changed":"unchanged" );}const char *site_pseudourl( struct site_t *the_site ) {    static char urlbuf[256];    snprintf( urlbuf, 256, 	      "%s://%s%s",	      the_site->driver->service_name, the_site->server, 	      the_site->remote_root_user +	      ( the_site->remote_isrel ? 1 : 0 ) );    return urlbuf;}	     

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美日韩精品一区二区三区四区| 精品国产不卡一区二区三区| 宅男噜噜噜66一区二区66| 极品少妇xxxx精品少妇| 精品国产91九色蝌蚪| 国产一区二区在线看| 成人免费观看视频| 99久久精品免费精品国产| 性感美女极品91精品| 国产三级精品视频| 欧美日韩精品久久久| 国产日产欧产精品推荐色| 亚洲一区二区三区激情| 亚洲国产wwwccc36天堂| 欧美一级国产精品| 色综合久久66| 6080亚洲精品一区二区| 国产精品一品视频| 97se亚洲国产综合自在线观| 日本精品一区二区三区高清 | 国产精品资源网站| 日本一区二区三区免费乱视频| 精品国产麻豆免费人成网站| 国产亚洲欧洲997久久综合| 欧美国产1区2区| 国产乱人伦精品一区二区在线观看 | 91免费在线视频观看| 国产激情91久久精品导航| 亚洲免费观看高清| 久久影院视频免费| 亚洲精品一区二区三区四区高清| 日韩亚洲欧美在线| 91精品国产免费| 美女一区二区在线观看| 亚洲精品一区在线观看| 国产福利一区二区三区视频| 日韩欧美一区二区在线视频| 久久这里只精品最新地址| 97久久精品人人做人人爽50路| 中文字幕一区二区不卡| 91福利国产精品| 精品一区二区三区蜜桃| 久久综合久久鬼色中文字| 国内精品不卡在线| 韩国视频一区二区| 久久综合久久综合九色| 91麻豆精品国产无毒不卡在线观看| 国产精品99久久久| 亚洲蜜桃精久久久久久久| 懂色av一区二区三区免费看| 夜夜揉揉日日人人青青一国产精品| 五月天一区二区三区| 精品日韩欧美一区二区| 中文字幕在线一区二区三区| 精品国产自在久精品国产| 欧美国产欧美亚州国产日韩mv天天看完整| 国产精品伦理在线| 欧美一区二区三区男人的天堂| 91国产精品成人| 男女男精品视频网| 国产精品中文字幕欧美| 国产精品福利一区二区三区| 日韩欧美综合一区| 欧美性一区二区| 五月天激情综合| 欧美精品一区男女天堂| 国产成人av电影在线| 91香蕉国产在线观看软件| 在线免费观看一区| 亚洲一二三区视频在线观看| 日本久久电影网| 婷婷久久综合九色综合绿巨人| 91免费看片在线观看| 一区二区三区免费网站| 国产一区二区看久久| 国产成人日日夜夜| 国产精品国产自产拍高清av | 日本亚洲欧美天堂免费| 99麻豆久久久国产精品免费| 日韩欧美卡一卡二| 99久久精品国产导航| 欧美一区二区女人| 日韩av一区二区三区四区| 91精品国产福利| 99国产精品久久久久| 91性感美女视频| 依依成人综合视频| 欧美日韩国产综合一区二区| 成人永久aaa| 成人黄色一级视频| 在线播放视频一区| 在线中文字幕一区二区| 国产精品美女久久久久aⅴ | 国产成人午夜片在线观看高清观看| 91精彩视频在线观看| 亚洲精品在线电影| **性色生活片久久毛片| 日韩免费一区二区三区在线播放| 午夜精品久久久久久久久久久| 视频一区二区欧美| 久久se这里有精品| 精品国产制服丝袜高跟| 亚洲欧美色图小说| 国内成人免费视频| 国产免费成人在线视频| 一区二区三区日本| 中文字幕欧美一| 色婷婷精品大在线视频| 91首页免费视频| 日韩黄色小视频| 国产亚洲精品精华液| 中文字幕一区二区视频| 在线精品视频一区二区三四 | 国产女同性恋一区二区| 日韩高清不卡一区| 欧美精品久久一区| 欧美人伦禁忌dvd放荡欲情| 久久影院午夜片一区| 日韩一区二区影院| 337p日本欧洲亚洲大胆色噜噜| 99久久夜色精品国产网站| 亚洲免费视频中文字幕| 国产亚洲精品免费| 成人一级片在线观看| 精品久久久久久久人人人人传媒 | 国产日本欧美一区二区| 欧美极品少妇xxxxⅹ高跟鞋| 成人免费视频网站在线观看| 国产精品黄色在线观看| 国产日韩亚洲欧美综合| 粉嫩高潮美女一区二区三区| 欧美一级二级三级乱码| 欧美麻豆精品久久久久久| 国产成人丝袜美腿| 欧美精品一区二区三区久久久| 久久综合九色综合97婷婷女人 | 亚洲综合色婷婷| 久久久久亚洲综合| 一区二区三区蜜桃| 久久9热精品视频| 6080午夜不卡| 在线亚洲+欧美+日本专区| 久久一日本道色综合| 国产欧美视频在线观看| 黄色日韩三级电影| 91精品麻豆日日躁夜夜躁| 欧美久久久久中文字幕| 日韩视频一区二区三区| 日本视频中文字幕一区二区三区| 欧美三级视频在线观看| 日本欧美一区二区三区乱码| 在线播放/欧美激情| 欧美一a一片一级一片| 日韩一区欧美二区| 欧美午夜精品电影| 91福利精品第一导航| 亚洲丝袜另类动漫二区| 日韩区在线观看| 国产精品羞羞答答xxdd| 欧美中文字幕亚洲一区二区va在线 | 91精选在线观看| 韩国欧美国产一区| 99re这里都是精品| 亚洲制服丝袜一区| 欧美日韩亚洲不卡| 亚洲国产精品99久久久久久久久| 久久精品国产99国产| 亚洲第一搞黄网站| 91丝袜国产在线播放| 国产一区二区三区免费看| 国产成人精品一区二区三区四区 | 亚洲美女淫视频| 1024成人网色www| 亚洲男人的天堂一区二区| 久久久99精品久久| 色老头久久综合| 亚洲高清一区二区三区| 国产精品视频你懂的| 蜜桃91丨九色丨蝌蚪91桃色| 成人欧美一区二区三区在线播放| 国产精品自在在线| 久久先锋资源网| 在线电影院国产精品| 另类成人小视频在线| 9191国产精品| 国产精品原创巨作av| 综合久久给合久久狠狠狠97色| 亚洲电影一级片| 欧美大片在线观看一区二区| 亚洲欧美偷拍另类a∨色屁股| 亚洲人成在线播放网站岛国| 无吗不卡中文字幕| 国产麻豆精品theporn| 亚洲一区二区在线免费观看视频| 欧美精品一区二区不卡| 一级精品视频在线观看宜春院| 国产午夜精品久久久久久久| 欧美一区二区三区不卡| 欧美性猛交xxxxxxxx| 26uuu精品一区二区三区四区在线 26uuu精品一区二区在线观看 |