您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ write_buf函数代码示例

51自学网 2021-06-03 10:05:07
  C++
这篇教程C++ write_buf函数代码示例写得很实用,希望能帮到您。

本文整理汇总了C++中write_buf函数的典型用法代码示例。如果您正苦于以下问题:C++ write_buf函数的具体用法?C++ write_buf怎么用?C++ write_buf使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。

在下文中一共展示了write_buf函数的26个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: send_exclude_list

void send_exclude_list(int f){	int i;	extern int remote_version;	if (!exclude_list) {		write_int(f,0);		return;	}	for (i=0;exclude_list[i];i++) {		char *pattern = exclude_list[i]->pattern; 		int l;		l = strlen(pattern);		if (l == 0) continue;		if (exclude_list[i]->include) {			if (remote_version < 19) {				rprintf(FERROR,"remote rsync does not support include syntax - aborting/n");				exit_cleanup(RERR_UNSUPPORTED);			}			write_int(f,l+2);			write_buf(f,"+ ",2);		} else {			write_int(f,l);		}		write_buf(f,pattern,l);	}    	write_int(f,0);}
开发者ID:AkankshaGovil,项目名称:Automation,代码行数:31,


示例2: varint_encode

int varint_encode(uint64_t source, char *buf, int size, int *written) {    int needed = varint_encode_size(source);    if (size < needed) {        return 1;    }    *written = 0;    int pos = 0;    if (source < 0) {        source = ~source;        if (source < 0x4) {            write_buf(buf, &pos, written, 0xFC | source);            return 0;        } else {            write_buf(buf, &pos, written, 0xF8);        }    }    if (source < 0x80) {        // Need top bit clear        write_buf(buf, &pos, written, source);    } else if (source < 0x4000) {        // Need top two bits clear        write_buf(buf, &pos, written, (source >> 8) | 0x80);        write_buf(buf, &pos, written, source & 0xFF);    } else if (source < 0x200000) {
开发者ID:jumpandspintowin,项目名称:mumble-web-demo,代码行数:28,


示例3: send_uid_list

/* send a complete uid/gid mapping to the peer */void send_uid_list(int f){	struct idlist *list;	if (numeric_ids) return;	if (preserve_uid) {		/* we send sequences of uid/byte-length/name */		list = uidlist;		while (list) {			int len = strlen(list->name);			write_int(f, list->id);			write_byte(f, len);			write_buf(f, list->name, len);			list = list->next;		}		/* terminate the uid list with a 0 uid. We explicitly exclude		   0 from the list */		write_int(f, 0);	}	if (preserve_gid) {		list = gidlist;		while (list) {			int len = strlen(list->name);			write_int(f, list->id);			write_byte(f, len);			write_buf(f, list->name, len);			list = list->next;		}		write_int(f, 0);	}}
开发者ID:AkankshaGovil,项目名称:Automation,代码行数:35,


示例4: write_cmd

static int write_cmd(char *buf, int len){  byte hd[2];  enc_int16(len, hd);  if (write_buf(1, (char *)hd, 2) != 2)    return 0;  if (write_buf(1, buf, len) != len)    return 0;  return 1;}
开发者ID:0879dc,项目名称:ejabberd,代码行数:10,


示例5: unix_pass_trigger

int     unix_pass_trigger(const char *service, const char *buf, ssize_t len, int timeout){    const char *myname = "unix_pass_trigger";    int     pair[2];    struct unix_pass_trigger *up;    int     fd;    if (msg_verbose > 1)	msg_info("%s: service %s", myname, service);    /*     * Connect...     */    if ((fd = unix_pass_connect(service, BLOCKING, timeout)) < 0) {	if (msg_verbose)	    msg_warn("%s: connect to %s: %m", myname, service);	return (-1);    }    close_on_exec(fd, CLOSE_ON_EXEC);    /*     * Create a pipe, and send one pipe end to the server.     */    if (pipe(pair) < 0)	msg_fatal("%s: pipe: %m", myname);    close_on_exec(pair[0], CLOSE_ON_EXEC);    close_on_exec(pair[1], CLOSE_ON_EXEC);    if (unix_send_fd(fd, pair[0]) < 0)	msg_fatal("%s: send file descriptor: %m", myname);    /*     * Stash away context.     */    up = (struct unix_pass_trigger *) mymalloc(sizeof(*up));    up->fd = fd;    up->service = mystrdup(service);    up->pair[0] = pair[0];    up->pair[1] = pair[1];    /*     * Write the request...     */    if (write_buf(pair[1], buf, len, timeout) < 0	|| write_buf(pair[1], "", 1, timeout) < 0)	if (msg_verbose)	    msg_warn("%s: write to %s: %m", myname, service);    /*     * Wakeup when the peer disconnects, or when we lose patience.     */    if (timeout > 0)	event_request_timer(unix_pass_trigger_event, (char *) up, timeout + 100);    event_enable_read(fd, unix_pass_trigger_event, (char *) up);    return (0);}
开发者ID:abhai2k,项目名称:postfix-mongodb,代码行数:55,


示例6: locking_reset

/** *	locking_reset - reset the channel *	@rchan: the channel *	@init: 1 if this is a first-time channel initialization */void locking_reset(struct rchan *rchan, int init){    if (init)        channel_lock(rchan) = RAW_SPIN_LOCK_UNLOCKED;    write_buf(rchan) = rchan->buf;    write_buf_end(rchan) = write_buf(rchan) + rchan->buf_size;    cur_write_pos(rchan) = write_buf(rchan);    write_limit(rchan) = write_buf_end(rchan) - rchan->end_reserve;    in_progress_event_pos(rchan) = NULL;    in_progress_event_size(rchan) = 0;    interrupted_pos(rchan) = NULL;    interrupting_size(rchan) = 0;}
开发者ID:GodFox,项目名称:magx_kernel_xpixl,代码行数:18,


示例7: write_buf

void NRF24L01::set_local_addr(uint8_t ch,uint8_t *addr){    uint8_t tmp_addr[5];    if(0 < ch && ch < 2)        write_buf(NRF_WRITE_REG + RX_ADDR_P0 + ch, addr, this->rx_aw);//写RX节点地址    else if(2 <= ch && ch < 6){        tmp_addr[0] = rx_addr_1[0];        tmp_addr[1] = rx_addr_1[1];        tmp_addr[2] = rx_addr_1[2];        tmp_addr[3] = rx_addr_1[3];        tmp_addr[4] = addr[4];        write_buf(NRF_WRITE_REG + RX_ADDR_P0 + ch, tmp_addr, this->rx_aw);//写RX节点地址    }       }
开发者ID:Hletian,项目名称:ebox_stm32,代码行数:15,


示例8: sim_main

/* start simulation, program loaded, processor precise state initialized */voidsim_main(void){  fprintf(stderr, "sim: ** starting *pipe* functional simulation **/n");  /* must have natural byte/word ordering */  if (sim_swap_bytes || sim_swap_words)    fatal("sim: *pipe* functional simulation cannot swap bytes or words");  /* set up initial default next PC */  /* maintain $r0 semantics */  regs.regs_R[MD_REG_ZERO] = 0;  regs.regs_PC -= sizeof(md_inst_t);  while (TRUE)  {	   do_if();     do_wb();     do_id();     do_ex();     do_mem();     print_env();     write_buf();     #ifndef NO_INSN_COUNT           sim_num_insn++;     #endif /* !NO_INSN_COUNT */  }}
开发者ID:ZZCer,项目名称:PISASimulator,代码行数:28,


示例9: write_data

/* write data to destination(s) */ssize_twrite_data( const struct dstream_ctx* spc,            const char* data,            const ssize_t len,            int fd ){    ssize_t n = 0, error = IO_ERR;    int32_t n_count = -1;    assert( spc && data && len );    if( fd <= 0 ) return 0;    if( spc->flags & F_SCATTERED ) {        n_count = spc->pkt_count;        n = writev( fd, spc->pkt, n_count );        if( n <= 0 ) {            if( EAGAIN == errno ) {                (void)tmfprintf( g_flog, "Write on fd=[%d] timed out/n", fd);                error = IO_BLK;            }            mperror( g_flog, errno, "%s: writev", __func__ );            return error;        }    }    else {        n = write_buf( fd, data, len, g_flog );        if( n < 0 )            error = n;    }    return (n > 0) ? n : error;}
开发者ID:Einheri,项目名称:wl500g,代码行数:34,


示例10: write_i64

/* write a i64 */static int write_i64(int f, i64 v){	if (write_buf(f, (uchar *)&v, 8))		return -1;	return 0;}
开发者ID:epa,项目名称:lrzip,代码行数:8,


示例11: gpfs_send_attr

void gpfs_send_attr(stat_x *sxp, int f){	struct rsync_gpfs_attr	*a = sxp->gpfs_attr;	if (a && a->buf) {		int ndx = (use_gpfs_attr_cache) ? gpfs_find_attr(a) : -1;		/* write 1 if it was 0; means not in cache (yet), +1 */		/* +1 is to compress the GPFS_NDX_NOATTR better */		write_varint(f, ndx + 1 + 1);		if (ndx < 0) {			write_varint(f, a->size);			write_buf(f, a->buf, a->size);		}	} else {		/* we have no attribute for this file */		/* +1 is just because of the trivial compression		 * of the mostly awaited GPFS_NDX_NOATTR  */		write_varint(f, GPFS_NDX_NOATTR + 1);	}}
开发者ID:OrlandoRichards,项目名称:gpfsug-tools,代码行数:25,


示例12: dump_program_headers

/*===========================================================================* *			  dump_program_headers			             * *===========================================================================*/static void dump_program_headers(struct filp *f, Elf_Phdr phdrs[], int phnum){  int i;  for (i = 0; i < phnum; i++)	write_buf(f, (char *) &phdrs[i], sizeof(Elf_Phdr));}
开发者ID:Hooman3,项目名称:minix,代码行数:10,


示例13: dump_segments

/*===========================================================================* *			      dump_segments 			             * *===========================================================================*/static void dump_segments(struct filp *f, Elf_Phdr phdrs[], int phnum){  int i;  vir_bytes len;  off_t off, seg_off;  int r;  static u8_t buf[CLICK_SIZE];  for (i = 1; i < phnum; i++) {	len = phdrs[i].p_memsz;	seg_off = phdrs[i].p_vaddr;	if (len > LONG_MAX) {		printf("VFS: segment too large to dump, truncating/n");		len = LONG_MAX;	}	for (off = 0; off < (off_t) len; off += CLICK_SIZE) {		vir_bytes p = (vir_bytes) (seg_off + off);		r = sys_datacopy_try(fp->fp_endpoint, p,			SELF, (vir_bytes) buf,			(phys_bytes) CLICK_SIZE);		if(r != OK) {			/* memory didn't exist; write as zeroes */			memset(buf, 0, sizeof(buf));			continue;		}		write_buf(f, (char *) buf, (off + CLICK_SIZE <= (off_t) len) ?					CLICK_SIZE : (len - off));	}  }}
开发者ID:Hooman3,项目名称:minix,代码行数:37,


示例14: TEST_F

/** Let the intermediate write request fail. The write should be retried and *  finally succeed. */TEST_F(AsyncWriteHandlerTest, IntermediateWriteFail) {  size_t blocks = 5;  size_t buffer_size = kBlockSize * blocks;  size_t middle = blocks / 2;  boost::scoped_array<char> write_buf(new char[buffer_size]());  vector<WriteEntry> expected_front(middle);  vector<WriteEntry> expected_tail(blocks - middle);  for (size_t i = 0; i < middle; ++i) {    expected_front[i] = WriteEntry(i, 0, kBlockSize);  }  for (size_t i = middle; i < blocks; ++i) {    expected_tail[i - middle] = WriteEntry(i, 0, kBlockSize);  }  test_env.osds[0]->AddDropRule(      new ProcIDFilterRule(xtreemfs::pbrpc::PROC_ID_WRITE,                           new SkipMDropNRule(middle, 1)));  ASSERT_NO_THROW(file->Write(write_buf.get(), buffer_size, 0));  ASSERT_NO_THROW(file->Flush());  EXPECT_TRUE(equal(expected_front.begin(),                    expected_front.end(),                    test_env.osds[0]->GetReceivedWrites().begin()));  EXPECT_TRUE(equal(expected_tail.begin(),                    expected_tail.end(),                    test_env.osds[0]->GetReceivedWrites().end() -                        expected_tail.size()));  ASSERT_NO_THROW(file->Close());}
开发者ID:2510,项目名称:xtreemfs,代码行数:35,


示例15: draw_char

uint8_t draw_char(uint8_t start_row, uint8_t start_col, unsigned char ch, uint8_t fg_col, uint8_t bg_col, uint8_t width) {	unsigned int w;	unsigned int i, cpos, cnt;	uint8 res = 0;		// NOTE maybe print a ? or something	if (ch > max_char) return 1;	/* We print nothing, character not encoded */		cpos = char_pos[ch];		// Start of glyph bits in font_bits[]		w = char_width(ch);		// Width of the character without inter character space	if (w > width) w = width;	// w is now min(char_width(ch), width)	// draw w columns into drawbuf	// each column is copied (with correct color) to drawbuf directly from font_bits	for (cnt = 0; cnt < w; cnt++, cpos+=bytes_per_col)		store_buf(cnt, font_bits[cpos] | (font_bits[cpos+1] << 8), fg_col, bg_col);	if ( (width - cnt) >= ic_space ){		for (i=0; i<ic_space; i++)			store_buf(cnt++, 0, fg_col, bg_col);		// inter character space		res = cnt;	};	write_buf(start_row, start_col, cnt, font_height);	return res;	}
开发者ID:HerrSchrader,项目名称:McBetty,代码行数:26,


示例16: stream_chargen

static void stream_chargen( const struct server *serp ){   char   line_buf[ LINE_LENGTH+2 ] ;   int    descriptor = SERVER_FD( serp ) ;   struct service *svc = SERVER_SERVICE( serp );   if( SVC_WAITS( svc ) ) {      descriptor = accept(descriptor, NULL, NULL);      if ( descriptor == -1 ) {         if ((errno == EMFILE) || (errno == ENFILE))            cps_service_stop(svc, "no available descriptors");         return;      }   }   (void) shutdown( descriptor, 0 ) ;   close_all_svc_descriptors();   for ( ;; )   {      if ( generate_line( line_buf, sizeof( line_buf ) ) == NULL )         break ;      if ( write_buf( descriptor, line_buf, sizeof( line_buf ) ) == FAILED )         break ;   }   if( SVC_WAITS( svc ) ) /* Service forks, so close it */      Sclose(descriptor);}
开发者ID:a5216652166,项目名称:rcp100,代码行数:28,


示例17: while

static void *dump_thread(void *arg_){	int ret;	struct btrfs_send *s = (struct btrfs_send*)arg_;	char buf[4096];	int readed;	while (1) {		readed = read(s->send_fd, buf, sizeof(buf));		if (readed < 0) {			ret = -errno;			error("failed to read stream from kernel: %s/n",				strerror(-ret));			goto out;		}		if (!readed) {			ret = 0;			goto out;		}		ret = write_buf(s->dump_fd, buf, readed);		if (ret < 0)			goto out;	}out:	if (ret < 0) {		exit(-ret);	}	return ERR_PTR(ret);}
开发者ID:ScarabMonkey,项目名称:btrfs-progs,代码行数:31,


示例18: lb_writestr_all

int lb_writestr_all(char **buf, int size, struct LineBuffer* lb) {	if(lb->eol == 0) return 0;	int eol = last_eol(lb);	int n = write_buf(*buf, size, lb->line, eol);	*buf += n;	lb->eol = n;   	// pretend this was the first one. so update clears it and looks for next.	return update_w(lb, n);}
开发者ID:denidoank,项目名称:avalonsailing,代码行数:8,


示例19: keyboard_handler

void keyboard_handler() {    disable_interrupts();    write_buf(inb(KEYBOARD_PORT));    outb(INT_CTL_REG, INT_CTL_DONE);        enable_interrupts();}
开发者ID:kikimo,项目名称:pebble,代码行数:9,


示例20: lzo_wwrite_block

static int lzo_wwrite_block(const char *buffer, off_t len, struct buffer_t *outbuf){	char b2[MAX_BUFFER_SIZE];	int err;	lzo_uint dst_len;	char scratch[LZO1X_1_MEM_COMPRESS];	outbuf->offset=0;	memset(scratch,0,sizeof(scratch));	err=lzo1x_1_compress((void*)buffer, len, 			(void*)b2, &dst_len, 			scratch);	switch(err) {		case LZO_E_OK:			break;		case LZO_E_ERROR:			return -EINVAL; /* WTF? */		case LZO_E_OUT_OF_MEMORY:			return -ENOMEM; /* Uh oh */		case LZO_E_NOT_COMPRESSIBLE:			return -EINVAL; /* Claimed not to be used, dunno what we'll do */		case LZO_E_INPUT_OVERRUN:			return -EINVAL;  /* Can't happen on compress? */		case LZO_E_OUTPUT_OVERRUN:			return -ENOMEM;		case LZO_E_LOOKBEHIND_OVERRUN:			return -EINVAL;		case LZO_E_EOF_NOT_FOUND:			return -ENOENT; /* Can't happen on compress? */		case LZO_E_INPUT_NOT_CONSUMED:			return -EINVAL;		case LZO_E_NOT_YET_IMPLEMENTED:			return -ENOSYS;		default:			fprintf(stderr,"Unknown lzo error %d/n",err);			return -EINVAL;	}	write32(outbuf, len); /* Original length */	write32(outbuf, min((uint32_t)len,(uint32_t)dst_len));	/* CRC32 of the uncompressed buffer */#if 0	write32(outbuf, lzo_crc32(CRC32_INIT_VALUE, (void*)buffer, len));#endif	write32(outbuf, 		lzo_adler32(ADLER32_INIT_VALUE, (const void*)buffer, len));	write_buf(outbuf, b2, dst_len);	/* Return the number of bytes compressed */	return len;}
开发者ID:EnjoyHacking,项目名称:libtrace,代码行数:53,


示例21: send_protected_args

void send_protected_args(int fd, char *args[]){	int i;#ifdef ICONV_OPTION	int convert = ic_send != (iconv_t)-1;	xbuf outbuf, inbuf;	if (convert)		alloc_xbuf(&outbuf, 1024);#endif	for (i = 0; args[i]; i++) {} /* find first NULL */	args[i] = "rsync"; /* set a new arg0 */	if (DEBUG_GTE(CMD, 1))		print_child_argv("protected args:", args + i + 1);	do {		if (!args[i][0])			write_buf(fd, ".", 2);#ifdef ICONV_OPTION		else if (convert) {			INIT_XBUF_STRLEN(inbuf, args[i]);			iconvbufs(ic_send, &inbuf, &outbuf,				  ICB_EXPAND_OUT | ICB_INCLUDE_BAD | ICB_INCLUDE_INCOMPLETE | ICB_INIT);			outbuf.buf[outbuf.len] = '/0';			write_buf(fd, outbuf.buf, outbuf.len + 1);			outbuf.len = 0;		}#endif		else			write_buf(fd, args[i], strlen(args[i]) + 1);	} while (args[++i]);	write_byte(fd, 0);#ifdef ICONV_OPTION	if (convert)		free(outbuf.buf);#endif}
开发者ID:ain-ver,项目名称:rsync,代码行数:38,


示例22: inomap_dump

rv_tinomap_dump( drive_t *drivep ){	seg_addr_t addr;	hnk_t *hnkp;	hnk_t tmphnkp;	/* use write_buf to dump the hunks	 */	for ( addr.hnkoff = 0 ;	      addr.hnkoff <= inomap.lastseg.hnkoff ;	      addr.hnkoff++ ) {		intgen_t rval;		rv_t rv;		drive_ops_t *dop = drivep->d_opsp;		hnkp = inomap_addr2hnk( &addr );		xlate_hnk(hnkp, &tmphnkp, 1);		rval = write_buf( ( char * )&tmphnkp,				  sizeof( tmphnkp ),				  ( void * )drivep,				  ( gwbfp_t )dop->do_get_write_buf,				  ( wfp_t )dop->do_write );		switch ( rval ) {		case 0:			rv = RV_OK;			break;		case DRIVE_ERROR_MEDIA:		case DRIVE_ERROR_EOM:			rv = RV_EOM;			break;		case DRIVE_ERROR_EOF:			rv = RV_EOF;			break;		case DRIVE_ERROR_DEVICE:			rv = RV_DRIVE;			break;		case DRIVE_ERROR_CORE:		default:			rv = RV_CORE;			break;		}		if ( rv != RV_OK ) {			return rv;		}	}	return RV_OK;}
开发者ID:jkkm,项目名称:xfsdump,代码行数:50,


示例23: send_sums

/*  send a sums struct down a fd  */static void send_sums(struct sum_struct *s,int f_out){	int i;  /* tell the other guy how many we are going to be doing and how many     bytes there are in the last chunk */	write_int(f_out,s?s->count:0);	write_int(f_out,s?s->n:block_size);	write_int(f_out,s?s->remainder:0);	if (s)		for (i=0;i<s->count;i++) {			write_int(f_out,s->sums[i].sum1);			write_buf(f_out,s->sums[i].sum2,csum_length);		}}
开发者ID:AkankshaGovil,项目名称:Automation,代码行数:18,


示例24: flush_buffer

/* flush out any data in a stream buffer. Return -1 on failure */static int flush_buffer(struct stream_info *sinfo, int stream){	int c_type = CTYPE_NONE;	i64 c_len = sinfo->s[stream].buflen;	if (seekto(sinfo, sinfo->s[stream].last_head) != 0)		return -1;	if (write_i64(sinfo->fd, sinfo->cur_pos) != 0)		return -1;	sinfo->s[stream].last_head = sinfo->cur_pos + 17;	if (seekto(sinfo, sinfo->cur_pos) != 0)		return -1;	if (!(control.flags & FLAG_NO_COMPRESS)) {		if (LZMA_COMPRESS(control.flags))			lzma_compress_buf(&sinfo->s[stream], &c_type, &c_len);		else if (control.flags & FLAG_LZO_COMPRESS)			lzo_compress_buf(&sinfo->s[stream], &c_type, &c_len);		else if (control.flags & FLAG_BZIP2_COMPRESS)			bzip2_compress_buf(&sinfo->s[stream], &c_type, &c_len);		else if (control.flags & FLAG_ZLIB_COMPRESS)			gzip_compress_buf(&sinfo->s[stream], &c_type, &c_len);		else if (control.flags & FLAG_ZPAQ_COMPRESS)			zpaq_compress_buf(&sinfo->s[stream], &c_type, &c_len);		else fatal("Dunno wtf compression to use!/n");	}	if (write_u8(sinfo->fd, c_type) != 0 ||	    write_i64(sinfo->fd, c_len) != 0 ||	    write_i64(sinfo->fd, sinfo->s[stream].buflen) != 0 ||	    write_i64(sinfo->fd, 0) != 0) {		return -1;	}	sinfo->cur_pos += 25;	if (write_buf(sinfo->fd, sinfo->s[stream].buf, c_len) != 0)		return -1;	sinfo->cur_pos += c_len;	sinfo->s[stream].buflen = 0;	free(sinfo->s[stream].buf);	sinfo->s[stream].buf = malloc(sinfo->bufsize);	if (!sinfo->s[stream].buf)		return -1;	return 0;}
开发者ID:epa,项目名称:lrzip,代码行数:49,


示例25: write_rtp2ts

/* write RTP record into TS stream */static ssize_twrite_rtp2ts( int fd, const char* data, size_t len, FILE* log ){    void* buf = (void*)data;    size_t pldlen = len;    const int NO_VERIFY = 0;    int rc = 0;    assert( (fd > 0) && data && len && log );    rc = RTP_process( &buf, &pldlen, NO_VERIFY, log );    if( -1 == rc ) return -1;    assert( !buf_overrun( buf, len, 0, pldlen, log ) );    return write_buf( fd, buf, pldlen, log );}
开发者ID:Einheri,项目名称:wl500g,代码行数:18,


示例26: main

int main (void){	int fd;	char buf [256];	int i;	if ((fd = open ("/tmp/test", O_RDWR | O_CREAT | O_TRUNC,		FILE_PERMS)) == -1) {		err_msg ("Can't open temp file");	}	for (i = 0; i < 100000; i++)		write_buf (fd, buf, sizeof (buf));	close (fd);	return (0);}
开发者ID:AlexKordic,项目名称:sandbox,代码行数:17,



注:本文中的write_buf函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


C++ write_buffer函数代码示例
C++ write_barrier函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。