这篇教程C++ umalloc函数代码示例写得很实用,希望能帮到您。
本文整理汇总了C++中umalloc函数的典型用法代码示例。如果您正苦于以下问题:C++ umalloc函数的具体用法?C++ umalloc怎么用?C++ umalloc使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。 在下文中一共展示了umalloc函数的29个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。 示例1: thrqueue_new/* * Create a new thread-safe queue of size sz. */thrqueue_t *thrqueue_new(size_t sz){ thrqueue_t *queue; if (!(queue = umalloc(sizeof(thrqueue_t)))) goto out0; if (!(queue->data = umalloc(sz * sizeof(void*)))) goto out1; if (0 != pthread_mutex_init(&queue->mutex, NULL)) goto out2; if (0 != pthread_cond_init(&queue->notempty, NULL)) goto out3; if (0 != pthread_cond_init(&queue->notfull, NULL)) goto out4; queue->sz = sz; queue->n = 0; queue->in = 0; queue->out = 0; queue->block_enqueue = 1; queue->block_dequeue = 1; return queue;out4: pthread_cond_destroy(&queue->notempty);out3: pthread_mutex_destroy(&queue->mutex);out2: free(queue->data);out1: free(queue);out0: return NULL;}
开发者ID:caidongyun,项目名称:backup,代码行数:37,
示例2: djulian_/*--------------------------------------------------------------------*/ | FUNCTION : djulian_ | COMMENT : | PARAMETERS : | RETURN VALUE : | RESTRICTIONS :/*--------------------------------------------------------------------*/double djulian_ (char *jwhen, char *jtype, ftnlen jwhenlen, ftnlen jtypelen) { char *when, *type; double retval; /* * copy strings and terminate */ when = (char *) umalloc(jwhenlen + 1); strncpy(when, jwhen, jwhenlen); when[jwhenlen] = '/0'; type = (char *) umalloc(jtypelen + 1); strncpy(type, jtype, jtypelen); type[jtypelen] = '/0'; /* * call C version of djulian() */ retval = djulian(when, type); /* * free up arrays *///ufree(when);//ufree(type); return retval;}
开发者ID:changliao,项目名称:PRMS,代码行数:40,
示例3: assertstatic GIFmetafile *init_meta(mf_cgmo *cgmo, int sx, int sy){ GIFmetafile *newmeta = (GIFmetafile *)umalloc(sizeof(GIFmetafile)); assert(newmeta); newmeta->image = gdImageCreate(sx, sy); newmeta->sx = sx; newmeta->sy = sy; newmeta->colors = (GIFcolor *)umalloc(sizeof(GIFcolor) * cgmo->ws->wscolour); newmeta->lineIndex = 1; newmeta->lineWidth = 1; newmeta->fillIndex = 1; newmeta->styleIndex = 1; newmeta->fillStyleIndex = 1; newmeta->style = 0; newmeta->resize = 1; /* OK to resize */ newmeta->ws = cgmo->ws; init_colors(newmeta, cgmo->ws->wscolour); /* Allocate colors -- background white, foreground black */ allocate_color(newmeta, 0, 1, 1, 1); allocate_color(newmeta, 1, 0, 0, 0); return newmeta;}
开发者ID:NOAA-PMEL,项目名称:Ferret,代码行数:25,
示例4: draw_help_buttonvoid draw_help_button(si32 n, ui32 background){ static si32 first_call = TRUE; static char **button_label; char *label_str; int i; gframe_t *frame; if (Glob->debug) { fprintf(stderr, "** draw_help_button **/n"); } frame = Glob->help_button_frame[n]; /* * if first call, load up the label strings */ if (first_call) { button_label = (char **) umalloc (N_HELP_BUTTONS * sizeof(char *)); label_str = (char *) umalloc((ui32) (strlen(HELP_BUTTON_LABELS) + 1)); strcpy(label_str, HELP_BUTTON_LABELS); for (i = 0; i < N_HELP_BUTTONS; i++) { if (i == 0) button_label[i] = strtok(label_str, " "); else button_label[i] = strtok((char *) NULL, " "); } first_call = FALSE; } /* * clear window and set background */ XSetWindowBackground(Glob->rdisplay, frame->x->drawable, background); safe_XClearWindow(Glob->rdisplay, frame->x->drawable); /* * write the label to the window */ GDrawString(XDEV, frame, frame->x->gc, frame->x->font, frame->psgc, XJ_CENTER, YJ_CENTER, (double) 0.5, (double) 0.5, button_label[n]); safe_XFlush(Glob->rdisplay);}
开发者ID:jbuonagurio,项目名称:lrose-core,代码行数:60,
示例5: inttype *type_uptree_find_or_new( type *to, enum type_kind idx, int (*eq)(type *, void *), void (*init)(type *, void *), void *ctx){ struct type_tree_ent **ent; to = type_skip_wheres(to); if(!to->uptree) to->uptree = umalloc(sizeof *to->uptree); for(ent = &to->uptree->ups[idx]; *ent; ent = &(*ent)->next){ type *candidate = (*ent)->t; assert(candidate->type == idx); if(eq(candidate, ctx)) return candidate; } { type *new_t = type_new(idx, to); if(init) init(new_t, ctx); *ent = umalloc(sizeof **ent); (*ent)->t = new_t; return new_t; }}
开发者ID:8l,项目名称:ucc-c-compiler,代码行数:32,
示例6: alloc_morphology_gridsvoid alloc_morphology_grids(void){ static int first_call = TRUE; static si32 nbytes_alloc; si32 nbytes_needed; nbytes_needed = Glob->nx * Glob->ny * sizeof(ui08); if (first_call) { Refl_margin_grid = (ui08 *) umalloc ((ui32) nbytes_needed); Morphology_grid = (ui08 *) umalloc ((ui32) nbytes_needed); Edm_grid = (ui08 *) umalloc ((ui32) nbytes_needed); Eroded_grid = (ui08 *) umalloc ((ui32) nbytes_needed); nbytes_alloc = nbytes_needed; first_call = FALSE; } else { /* * adjust grid allocation as necessary */ if (nbytes_needed < nbytes_alloc) { Refl_margin_grid = (ui08 *) urealloc ((char *) Refl_margin_grid, (ui32) nbytes_needed); Morphology_grid = (ui08 *) urealloc ((char *) Morphology_grid, (ui32) nbytes_needed); Edm_grid = (ui08 *) urealloc ((char *) Edm_grid, (ui32) nbytes_needed); Eroded_grid = (ui08 *) urealloc ((char *) Eroded_grid, (ui32) nbytes_needed); nbytes_alloc = nbytes_needed; } /* if (nbytes_needed < nbytes_alloc) */ } /* if (first_call) */ /* * zero out grids */ memset((void *) Refl_margin_grid, 0, (int) nbytes_alloc); memset((void *) Morphology_grid, 0, (int) nbytes_alloc); memset((void *) Edm_grid, 0, (int) nbytes_alloc); memset((void *) Eroded_grid, 0, (int) nbytes_alloc); return;}
开发者ID:jbuonagurio,项目名称:lrose-core,代码行数:55,
示例7: umalloc/* * new_hscprc * * create and init a new hsc process */HSCPRC *new_hscprc(void){ HSCPRC *hp = NULL; hp = (HSCPRC *) umalloc(sizeof(HSCPRC)); if (hp) { memset(hp, 0, sizeof(HSCPRC)); /* init lists */ hp->defent = init_dllist(del_entity); hp->deftag = init_hsctree(free_tag_node, cmp_tag_node, ubi_trOVERWRITE); hp->defattr = init_dllist(del_hscattr); hp->deflazy = init_hsctree(free_tag_node, cmp_tag_node, ubi_trOVERWRITE); hp->defstyle = init_hsctree(free_style_node, cmp_style_node, ubi_trOVERWRITE); hp->container_stack = init_dllist(del_hsctag); hp->content_stack = init_dllist(del_string_node); hp->inpf_stack = init_dllist(del_inpf_stack_node); hp->project = NULL; hp->idrefs = init_dllist(del_idref); hp->select_stack = init_dllist(del_select_stack_node); hp->tag_styles = init_dllist(&del_styleattr); hp->include_dirs = init_strlist(); /* precompile some regular expressions */ hp->re_uri = hscregcomp(hp, REGEXP_URI, TRUE, TRUE); /* init strings */ hp->destdir = init_estr(0); hp->reldir = init_estr(0); hp->iconbase = init_estr(0); hp->server_dir = init_estr(0); hp->if_stack = init_estr(0); hp->tag_name_str = init_estr(128); hp->tag_attr_str = init_estr(128); hp->tag_close_str = init_estr(0); hp->tmpstr = init_estr(0); hp->curr_msg = init_estr(64); hp->curr_ref = init_estr(64); hp->whtspc = init_estr(0); /* allocate message arrays */ hp->msg_ignore = (HSCIGN *) umalloc((MAX_MSGID + 1) * sizeof(HSCIGN)); hp->msg_class = (HSCMSG_CLASS *) umalloc((MAX_MSGID + 1) * sizeof(HSCMSG_CLASS)); /* allocate image buffer */ hp->image_buffer = (unsigned char *) umalloc(IMAGE_BUFFER_SIZE); reset_hscprc(hp); } return (hp);}
开发者ID:mbethke,项目名称:hsc,代码行数:59,
示例8: umalloc/* * new_hscprc * * create and init a new hsc process */HSCPRC *new_hscprc(void){ HSCPRC *hp = NULL; hp = (HSCPRC *) umalloc(sizeof(HSCPRC)); if (hp) { memset(hp, 0, sizeof(HSCPRC)); /* init lists */ hp->defent = init_dllist(del_entity); hp->deftag = init_dllist(del_hsctag); hp->defattr = init_dllist(del_hscattr); hp->container_stack = init_dllist(del_hsctag); hp->content_stack = init_dllist(del_string_node); hp->inpf_stack = init_dllist(del_inpf_stack_node); hp->project = NULL; hp->idrefs = init_dllist(del_idref); hp->select_stack = init_dllist(del_select_stack_node); hp->include_dirs = init_strlist(); /* init strings */ hp->destdir = init_estr(0); hp->reldir = init_estr(0); hp->iconbase = init_estr(0); hp->server_dir = init_estr(0); hp->if_stack = init_estr(0); hp->tag_name_str = init_estr(128); hp->tag_attr_str = init_estr(128); hp->tag_close_str = init_estr(0); hp->tmpstr = init_estr(0); hp->curr_msg = init_estr(64); hp->curr_ref = init_estr(64); hp->whtspc = init_estr(0);#if 0 /* TODO:remove */ hp->filename_project = NULL; hp->filename_document = NULL;#endif /* alloc message arrays */ hp->msg_ignore = (BOOL *) umalloc((MAX_MSGID + 1) * sizeof(BOOL)); hp->msg_class = (HSCMSG_CLASS *) umalloc((MAX_MSGID + 1) * sizeof(HSCMSG_CLASS)); reset_hscprc(hp); } return (hp);}
开发者ID:BackupTheBerlios,项目名称:hsc-svn,代码行数:55,
示例9: CClp_initint CClp_init(CClp **lp){ /* INITIALIZES the LP. */ CClp_free(lp); (*lp) = umalloc(sizeof(CClp)); (*lp)->lp = NULL; return 0;}
开发者ID:ecotox,项目名称:pacfm,代码行数:7,
示例10: umallocstruct list *list_new(void *d){ struct list *l = umalloc(sizeof(*l)); l->data = d; l->next = l->prev = NULL; return l;}
开发者ID:bobrippling,项目名称:uvi,代码行数:7,
示例11: b_readint b_read(int fd, char* buf, int len){ if (buf_load==0) { buf_load = umalloc( BUFFER_FOR_READ_SIZE ); if (buf_load==0) return 0; } int loaded=0, now=1; while (now && loaded<len) { now = len-loaded; if ( now > BUFFER_FOR_READ_SIZE ) now = BUFFER_FOR_READ_SIZE; now = read(fd,buf_load,now); memcpy(buf+loaded, buf_load, now); loaded+=now; } return loaded;}
开发者ID:DIYBookScanner,项目名称:chdk,代码行数:25,
示例12: strlenchar *out_label_goto(char *func, char *lbl){ int len = strlen(func) + strlen(lbl) + 6; char *ret = umalloc(len); SNPRINTF(ret, len, ASM_PLBL_PRE "%s.%s", func, lbl); return ret;}
开发者ID:doniexun,项目名称:ucc-c-compiler,代码行数:7,
示例13: GIFmoOpen/* * Open an output GIF file. */ intGIFmoOpen(WS_STATE_PTR ws){ /* Output file not opened or written to until flushed */ Gint status = 1; initLogFlag(); assert(ws != NULL); assert(ws->wscolour <= gdMaxColors); if ((ws->mf.cgmo = (mf_cgmo*)umalloc(sizeof(mf_cgmo))) != NULL) { mf_cgmo *cgmo = ws->mf.cgmo; cgmo->ws = ws; if (find_meta(cgmo) != 0){ msgWarn("GIFmoOpen:metafile already open/n"); } else { create_meta(cgmo, DefaultSize, DefaultSize); cgmo->ws = ws; cgmo->type = MF_GIF; unlink(ws->conn); status = OK; } } return status;}
开发者ID:NOAA-PMEL,项目名称:Ferret,代码行数:29,
示例14: umalloc/*** new_hscvar**** alloc & init a new variable*/HSCVAR *new_hscvar( STRPTR newname ){ HSCVAR *newvar = (HSCVAR*) umalloc( sizeof(HSCVAR) ); if (newvar) { /* init new varument item */ newvar->vartype = VT_NONE; newvar->name = strclone( newname ); newvar->deftext = NULL; newvar->text = NULL; newvar->enumstr = NULL; newvar->macro_id = 0; newvar->varflag = 0; newvar->quote = EOF; } if ( !( newvar->name ) ) { del_var( (APTR) newvar ); newvar = NULL; } return (newvar);}
开发者ID:BackupTheBerlios,项目名称:hsc-svn,代码行数:34,
示例15: umalloctab *tab_new(window *win){ tab *t = umalloc(sizeof *t); t->win = win; t->next = NULL; return t;}
开发者ID:bobrippling,项目名称:tim,代码行数:7,
示例16: switchchar *str_quote(char *quoteme, int free_in){ int len; const char *s; char *ret, *p; len = 3; /* ""/0 */ for(s = quoteme; *s; s++, len++) switch(*s){ case '"': case '//': len++; } p = ret = umalloc(len); *p++ = '"'; for(s = quoteme; *s; s++){ switch(*s){ case '"': case '//': *p++ = '//'; } *p++ = *s; } strcpy(p, "/""); if(free_in) free(quoteme); return ret;}
开发者ID:8l,项目名称:ucc-c-compiler,代码行数:33,
示例17: umallocchar *out_label_case(enum out_label_type lbltype, int val){ int len; char *ret = umalloc(len = 15 + 32); switch(lbltype){ case CASE_DEF: SNPRINTF(ret, len, ASM_PLBL_PRE "case_%d_default", switch_last); break; case CASE_CASE: case CASE_RANGE: { const char *extra = ""; if(val < 0){ val = -val; extra = "m"; } SNPRINTF(ret, len, ASM_PLBL_PRE "case%s_%d_%s%d", lbltype == CASE_RANGE ? "_rng" : "", switch_last, extra, val); break; } } switch_last++; return ret;}
开发者ID:doniexun,项目名称:ucc-c-compiler,代码行数:25,
示例18: init_metastatic GIFmetafile *copy_meta(mf_cgmo *cgmo, GIFmetafile *old, int sx, int sy){ GIFmetafile *newmeta = init_meta(cgmo, sx, sy); int i; /* Copy various stuff -- don't copy resize! */ newmeta->lineIndex = old->lineIndex; newmeta->lineWidth = old->lineWidth; newmeta->fillIndex = old->fillIndex; newmeta->styleIndex = old->styleIndex; newmeta->fillStyleIndex = old->fillStyleIndex; newmeta->style = (int *)umalloc(sizeof(int) * MaxLineStyleLength); memcpy(newmeta->style, old->style, sizeof(int)*MaxLineStyleLength); newmeta->ws = old->ws; /* Copy the color info */ for (i=0; i < old->numcolors; ++i){ GIFcolor *color = &old->colors[i]; if (old->colors[i].index == -1) break; allocate_color(newmeta, i, color->r, color->g, color->b); } /* Destroy the old metafile */ destroy_meta(cgmo, old); /* Add this one */ add_meta(cgmo, newmeta); return newmeta;}
开发者ID:NOAA-PMEL,项目名称:Ferret,代码行数:29,
示例19: set_lineStylestatic void set_lineStyle(GIFmetafile *meta, Gint attr, Gasf type){ if (type != xgks_state.gks_lnattr.type) return; if (type == GBUNDLED){ attr = meta->ws->lnbundl_table[attr].type; } msgInfo("set_lineStyle: setting style to %d/n", attr); if (attr <= 0 || attr > 4) attr = 1; meta->styleIndex = attr; { int currColor = meta->lineIndex; int i, length; char *cp = LineStyles[attr]; length = strlen(cp); assert(currColor != -1); if (meta->style) free(meta->style); meta->style = (int *)umalloc(sizeof(int) * MaxLineStyleLength); length = strlen(LineStyles[attr]); for (i=0; i < length; ++i){ if (cp[i] == '-'){ meta->style[i] = currColor; } else { meta->style[i] = gdTransparent; } } gdImageSetStyle(meta->image, meta->style, length); } }
开发者ID:NOAA-PMEL,项目名称:Ferret,代码行数:31,
示例20: umallocchar *str_quote(const char *quoteme){ int len; const char *s; char *ret, *p; len = 3; /* ""/0 */ for(s = quoteme; *s; s++, len++) if(*s == '"') len++; p = ret = umalloc(len); *p++ = '"'; for(s = quoteme; *s; s++){ if(*s == '"') *p++ = '//'; *p++ = *s; } strcpy(p, "/""); return ret;}
开发者ID:MoochMcGee,项目名称:ucc-c-compiler,代码行数:25,
示例21: escape_stringvoid escape_string(char *old_str, int *plen){ const int old_len = *plen; char *new_str = umalloc(*plen); int new_i, i; /* "parse" into another string */ for(i = new_i = 0; i < old_len; i++){ char add; if(old_str[i] == '//'){ int len; i++; if(escape_multi_char(old_str + i, &add, &len)){ i += len - 1; }else{ add = escape_char(old_str[i]); if(add == -1) DIE_AT(NULL, "unknown escape char '//%c'", add); } }else{ add = old_str[i]; } new_str[new_i++] = add; } memcpy(old_str, new_str, new_i); *plen = new_i; free(new_str);}
开发者ID:MoochMcGee,项目名称:ucc-c-compiler,代码行数:35,
示例22: umalloctree_vertex_t *alloc_vertices(si32 n_vertices){ static int n_alloc = 0; static tree_vertex_t *vertices; if (n_vertices > n_alloc) { if (vertices == NULL) { vertices = (tree_vertex_t *) umalloc ((ui32) (n_vertices * sizeof(*vertices))); } else { vertices = (tree_vertex_t *) urealloc ((char *) vertices, (ui32) (n_vertices * sizeof(*vertices))); } n_alloc = n_vertices; } return (vertices);}
开发者ID:jbuonagurio,项目名称:lrose-core,代码行数:25,
示例23: conf_save//-------------------------------------------------------------------void conf_save() { static const long t=CONF_MAGICK_VALUE; register int i; int fd; char *buf=umalloc(sizeof(t)+CONF_NUM*(sizeof(conf_info[0].id)+sizeof(conf_info[0].size))+sizeof(conf)); char *p=buf; fd = open(CONF_FILE, O_WRONLY|O_CREAT|O_TRUNC, 0777); if (fd>=0){ memcpy(p, &t, sizeof(t)); p+=sizeof(t); for (i=0; i<CONF_NUM; ++i) { memcpy(p, &(conf_info[i].id), sizeof(conf_info[i].id)); p+=sizeof(conf_info[i].id); memcpy(p, &(conf_info[i].size), sizeof(conf_info[i].size)); p+=sizeof(conf_info[i].size); memcpy(p, conf_info[i].var, conf_info[i].size); p+=conf_info[i].size; } write(fd, buf, p-buf); close(fd); } ufree(buf);}
开发者ID:barryk,项目名称:CHDK-SD1200,代码行数:26,
示例24: umallocstatic type *type_new(enum type_kind t, type *of){ type *r = umalloc(sizeof *r); r->type = t; r->ref = of; return r;}
开发者ID:8l,项目名称:ucc-c-compiler,代码行数:7,
示例25: umalloc/* * new_hsctag * * alloc & init a new hsctag */HSCTAG *new_hsctag(STRPTR newid){ HSCTAG *newtag = (HSCTAG*) umalloc(sizeof(HSCTAG)); if (newtag) { /* init new tag item */ newtag->name = upstr(strclone(newid)); /* set id */ newtag->option = 0; newtag->o_handle = NULL; /* no handle functions */ newtag->c_handle = NULL; newtag->occured = FALSE; newtag->op_text = NULL; newtag->cl_text = NULL; newtag->attr = init_dllist(del_hscattr); newtag->mbi = NULL; newtag->naw = NULL; newtag->uri_size = NULL; newtag->uri_stripext = NULL; newtag->start_fpos = NULL; newtag->end_fpos = NULL; if (!(newtag->name && newtag->attr)) { del_hsctag(newtag); newtag = NULL; } } return (newtag);}
开发者ID:BackupTheBerlios,项目名称:hsc-svn,代码行数:37,
示例26: faultINV *inv_create(int m, int max_upd){ INV *inv; int k; if (m < 1) fault("inv_create: m = %d; invalid parameter", m); if (max_upd < 0) fault("inv_create: max_upd = %d; invalid parameter", max_upd); inv = umalloc(sizeof(INV)); inv->m = m; inv->valid = 1; inv->luf = luf_create(m, 0); inv->hh_max = max_upd; inv->hh_nfs = 0; inv->hh_ndx = ucalloc(1+max_upd, sizeof(int)); inv->hh_ptr = ucalloc(1+max_upd, sizeof(int)); inv->hh_len = ucalloc(1+max_upd, sizeof(int)); inv->p0_row = ucalloc(1+m, sizeof(int)); inv->p0_col = ucalloc(1+m, sizeof(int)); for (k = 1; k <= m; k++) inv->p0_row[k] = inv->p0_col[k] = k; inv->cc_len = -1; inv->cc_ndx = ucalloc(1+m, sizeof(int)); inv->cc_val = ucalloc(1+m, sizeof(double));#if 0 inv->upd_tol = 1e-12;#else inv->upd_tol = 1e-6;#endif inv->nnz_h = 0; return inv;}
开发者ID:MasonXQY,项目名称:OPSP,代码行数:31,
示例27: CClp_sread_warmstartint CClp_sread_warmstart(CC_SFILE *file, CClp_warmstart **warm){ /* READS warmstart information from the file. */ int i, j, ccount, rcount; char name[5]; CClp_free_warmstart(warm); for (i = 0; i < 4; i++) if (CCutil_sread_char(file, &name[i])) goto fail; name[4] = '/0'; if (strncmp(name, SOLVER, 4)) { print("CClp_sread_warmstart: warmstart for another solver (%s)" " ignored", name); return 0; } if (CCutil_sread_int(file, &ccount)) goto fail; if (CCutil_sread_int(file, &rcount)) goto fail; (*warm) = umalloc(sizeof(CClp_warmstart)); (*warm)->ncols = 0; (*warm)->nrows = 0; (*warm)->cstat = NULL; (*warm)->rstat = NULL; (*warm)->cstat = ucalloc(ccount, sizeof(int)); (*warm)->rstat = ucalloc(rcount, sizeof(int)); for (j = 0; j < ccount; j++) if (CCutil_sread_bits(file, &(((*warm)->cstat)[j]), 2)) goto fail; for (i = 0; i < rcount; i++) if (CCutil_sread_bits(file, &(((*warm)->rstat)[i]), 1)) goto fail; (*warm)->ncols = ccount; (*warm)->nrows = rcount; return 0;fail: CClp_free_warmstart(warm); return 1;}
开发者ID:ecotox,项目名称:pacfm,代码行数:34,
示例28: umallocLPP *lpp_create_wksp(void){ LPP *lpp; lpp = umalloc(sizeof(LPP)); lpp->orig_m = 0; lpp->orig_n = 0; lpp->orig_nnz = 0; lpp->orig_dir = LPX_MIN; lpp->nrows = 0; lpp->ncols = 0; lpp->row_pool = dmp_create_pool(sizeof(LPPROW)); lpp->col_pool = dmp_create_pool(sizeof(LPPCOL)); lpp->aij_pool = dmp_create_pool(sizeof(LPPAIJ)); lpp->row_ptr = NULL; lpp->col_ptr = NULL; lpp->row_que = NULL; lpp->col_que = NULL; lpp->c0 = 0.0; lpp->tqe_pool = dmp_create_pool(0); lpp->tqe_list = NULL; lpp->m = 0; lpp->n = 0; lpp->nnz = 0; lpp->row_ref = NULL; lpp->col_ref = NULL; lpp->row_stat = NULL; lpp->row_prim = NULL; lpp->row_dual = NULL; lpp->col_stat = NULL; lpp->col_prim = NULL; lpp->col_dual = NULL; return lpp;}
开发者ID:ecotox,项目名称:pacfm,代码行数:32,
示例29: umallocsymtable *symtab_new(symtable *parent){ symtable *p = umalloc(sizeof *p); if(parent) symtab_set_parent(p, parent); return p;}
开发者ID:mtexier,项目名称:ucc,代码行数:7,
注:本文中的umalloc函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 C++ umask函数代码示例 C++ uma_zfree函数代码示例 |