functionSource
stringlengths
20
97.4k
CWE-119
bool
2 classes
CWE-120
bool
2 classes
CWE-469
bool
2 classes
CWE-476
bool
2 classes
CWE-other
bool
2 classes
combine
int64
0
1
find_sections_buffered(section_t *section, char *start, char *key, va_list args, char *buf, int len, array_t **sections) { section_t *found = NULL, *fallback; char *pos; int i; if (!section) { return; } pos = strchr(key, '.'); if (pos) { *pos = '\0'; } if (!print_key(buf, len, start, key, args)) ...
true
true
false
false
false
1
DiagMatSolve2(void* A, int indx[], int nindx, double b[], double x[],int n){ diagmat* AA = (diagmat*)A; double *v=AA->val; int i,j; memset((void*)x,0,n*sizeof(double)); for (j=0;j<nindx;j++){ i=indx[j]; x[i]=b[i]/v[i]; } return 0; }
false
false
false
false
false
0
games_scores_add_category (GamesScores *self, const char *key, const char *name) { GamesScoresPrivate *priv = self->priv; GamesScoresCategoryInternal *cat; cat = g_new (GamesScoresCategoryInternal, 1); cat->category.key = g_strdup (key); cat->category.nam...
false
false
false
false
false
0
gdImageCreateFromWebpPtr (int size, void *data) { int width, height, ret; unsigned char *Y = NULL; unsigned char *U = NULL; unsigned char *V = NULL; gdImagePtr im; ret = WebPDecode(data, size, &Y, &U, &V, &width, &height); if (ret != webp_success) { if (Y) free(Y); if (U) free(U); if (V) free(V); ...
false
false
false
false
false
0
init_request(struct client *client, struct fw_cdev_send_request *request, int destination_id, int speed) { struct outbound_transaction_event *e; int ret; if (request->tcode != TCODE_STREAM_DATA && (request->length > 4096 || request->length > 512 << speed)) return -EIO; if (request->tcode == TCODE_WRI...
false
false
false
false
false
0
acpi_ns_get_attached_data(struct acpi_namespace_node * node, acpi_object_handler handler, void **data) { union acpi_operand_object *obj_desc; obj_desc = node->object; while (obj_desc) { if ((obj_desc->common.type == ACPI_TYPE_LOCAL_DATA) && (obj_desc->data.handler == handler)) { *data = obj_desc->da...
false
false
false
false
false
0
f_ungetc(VALUE *v1, VALUE *v2) { VALUE result; NUMBER *q; int ch; int i; /* initialize VALUE */ result.v_subtype = V_NOSUBTYPE; errno = 0; if (v1->v_type != V_FILE) return error_value(E_UNGETC1); switch (v2->v_type) { case V_STR: ch = v2->v_str->s_str[0]; break; case V_NUM: q = v2->v_num; i...
false
false
false
false
false
0
installedEntries() const { EntryInternal::List entries; foreach (const EntryInternal& entry, mCachedEntries) { if (entry.status() == Entry::Installed || entry.status() == Entry::Updateable) { entries.append(entry); } } return entries; }
false
false
false
false
false
0
initializePgn() { m_pgn->setVariant(m_board->variant()); m_pgn->setStartingFenString(m_board->startingSide(), m_startingFen); m_pgn->setDate(QDate::currentDate()); m_pgn->setPlayerName(Chess::Side::White, m_player[Chess::Side::White]->name()); m_pgn->setPlayerName(Chess::Side::Black, m_player[Chess::Side::Black]->...
false
false
false
false
false
0
next_unifiable(struct term *t, struct context *subst_t, struct context *subst_ret, struct fpa_tree **pos_ptr, struct trail **tr_ptr, struct link_node *curr_node, struct link_node *target, char *target_here, int *hit_dp_count) { struct term *term_to_return; in...
false
false
false
false
false
0
configure(Vector<String> &conf, ErrorHandler *errh) { uint16_t ether_type; click_ether ethh; if (Args(conf, this, errh) .read_mp("ETHERTYPE", ether_type) .read_mp_with("SRC", EtherAddressArg(), ethh.ether_shost) .read_mp_with("DST", EtherAddressArg(), ethh.ether_dhost) .complete() < 0) return -1; e...
false
false
false
false
false
0
openssldsa_parse(dst_key_t *key, isc_lex_t *lexer, dst_key_t *pub) { dst_private_t priv; isc_result_t ret; int i; DSA *dsa = NULL; isc_mem_t *mctx = key->mctx; #define DST_RET(a) {ret = a; goto err;} UNUSED(pub); /* read private key file */ ret = dst__privstruct_parse(key, DST_ALG_DSA, lexer, mctx, &priv); i...
false
false
false
false
false
0
sdp_device_record_register(sdp_session_t *session, bdaddr_t *device, sdp_record_t *rec, uint8_t flags) { sdp_buf_t pdu; uint32_t handle; int err; SDPDBG(""); if (rec->handle && rec->handle != 0xffffffff) { uint32_t handle = rec->handle; sdp_data_t *data = sdp_data_alloc(SDP_UINT32, &handle); sdp_attr_repla...
false
false
false
false
false
0
p_cliptarget_togglebutton_toggled_cb (GtkToggleButton *togglebutton , GapStoryClipTargetEnum *clip_target_ptr) { GapStbMainGlobalParams *sgpp; if(gap_debug) { printf("CB: p_cliptarget_togglebutton_toggled_cb: %d\n", (int)togglebutton); } if(clip_target_ptr) { if (togglebutton->acti...
false
false
false
false
false
0
extend_info_get_description(char *buf, const extend_info_t *ei) { if (!ei) return "<null>"; return format_node_description(buf, ei->identity_digest, 0, ei->nickname, &ei->addr, ...
false
false
false
false
false
0
adjust_stab_sections (bfd *abfd, asection *sec, void *xxx ATTRIBUTE_UNUSED) { char *name; asection *strsec; char *p; int strsz, nsyms; if (strncmp (".stab", sec->name, 5)) return; if (!strcmp ("str", sec->name + strlen (sec->name) - 3)) return; name = (char *) alloca (strlen (sec->name) + 4); ...
false
false
false
false
false
0
telnet_print(const u_char *sp, u_int length) { int first = 1; const u_char *osp; int l; osp = sp; while (length > 0 && *sp == IAC) { l = telnet_parse(sp, length, 0); if (l < 0) break; /* * now print it */ if (Xflag && 2 < vflag) { if (first) printf("\nTelnet:"); hex_print_with_offset(...
false
false
false
false
false
0
sh_SortFreq(int *freq, uchar *symb) { int ls[8], hs[8]; int l, h, m, p, i, j, s, n; uchar t; /* Mark & count actual symbols */ for (i=n=0; i<SH_MAX_ALPHA; i++) if (freq[i]) symb[n++]=(uchar)i; ls[0]=0; hs[0]=n-1; for (s=0; s>=0; s--) { /* Pop next one */ l=ls[s]; h=hs...
false
false
false
false
false
0
p_string_set(li_object *args) { assert_nargs(3, args); assert_string(li_car(args)); assert_integer(li_cadr(args)); assert_character(li_caddr(args)); return li_character(li_to_string(li_car(args))[li_to_integer(li_cadr(args))] = li_to_character(li_caddr(args))); }
false
false
false
false
false
0
volume_id_get_buffer(struct volume_id *id, uint64_t off, size_t len) { info("get buffer off 0x%llx(%llu), len 0x%zx", (unsigned long long) off, (unsigned long long) off, len); /* check if requested area fits in superblock buffer */ if (off + len <= SB_BUFFER_SIZE) { /* check if we need to read */ if ((off + len)...
false
false
false
false
false
0
activate(bool _initial_state) { // If the buffer is activated already or the buffer is full, // then we can't activate it. if(isActive() || isFull()) return; // Save the time for this initial event start_time = get_cycles().get(); bInitialState = _initial_state; index = 0; // next state gets stor...
false
false
false
false
false
0
pccard_store_card_pm_state(struct device *dev, struct device_attribute *attr, const char *buf, size_t count) { struct pcmcia_socket *s = to_socket(dev); ssize_t ret = count; if (!count) return -EINVAL; if (!strncmp(buf, "off", 3)) pcmcia_parse_uevents(s, PCMCIA_UEVENT_SUSPEND); else { if (!st...
false
false
false
false
false
0
lam_tr_commname(char *name, int cid, double t) { struct trsrc *psrc; struct trrthdr *ptrr; struct trcommname *pcomm; int trsize; trsize = (sizeof(struct trsrc) + sizeof(struct trrthdr) + sizeof(struct trcommname)); psrc = (struct trsrc *) malloc(trsize); psrc->trs_node = ltot(getnodeid()); ...
false
false
false
false
true
1
op_sparse_multiply_AB(const CSparseMatrix &M1, const CSparseMatrix &M2, CSparseMatrix &res) { res = M1*M2; }
false
false
false
false
false
0
initScript() { if (script && !scriptInitialized) { setupScriptSupport(); script->init(); scriptInitialized = true; } }
false
false
false
false
false
0
getsample (void) { uae_s32 smp = 0; int div = 0, i; for (i = 0; i < 4; i++) { if (currprefs.floppyslots[i].dfxclick) { struct drvsample *ds_start = &drvs[i][DS_START]; struct drvsample *ds_spin = drv_has_disk[i] ? &drvs[i][DS_SPIN] : &drvs[i][DS_SPINND]; struct drvsample *ds_click = &drvs[i][DS_CLICK]; ...
false
false
false
false
false
0
gnucash_grid_find_loc_by_pixel (GnucashGrid *grid, gint x, gint y, VirtualLocation *virt_loc) { SheetBlock *block; if (virt_loc == NULL) return FALSE; block = gnucash_grid_find_block_by_pixel (grid, x, y, &virt_loc->vcell_loc); if (block == NULL) ...
false
false
false
false
false
0
get_scint_pars(struct ccd_frame *fr, struct vs_recipy *vs, double *t, double *d, double *am) { FITS_row * cp; float r; // determine exposure time if (fits_get_double(fr, "EXPTIME", t) <= 0 ) { err_printf("bad exposure time, assuming 1 sec\n"); *t = 1.0; } // telescope aperture cp = fits_keyword_lookup(fr, "...
false
false
false
false
false
0
getAddrCount(SPtr<TDUID> duid) { SPtr <TAddrClient> ptrClient; ClntsLst.first(); while ( ptrClient = ClntsLst.get() ) { if ( (*ptrClient->getDUID()) == (*duid)) break; } // Have we found this client? if (!ptrClient) { return 0; } unsigned long count=0; /...
false
false
false
false
false
0
setTime(const QTime &time) { if (d->time == time) return; const int index = d->combo->findData(time); if (index == -1) { // custom time, not found in combo items // QTime() is not the same as QTime(0,0)!! d->time = time.isNull()? QTime(0, 0) : time; d->combo->setEdi...
false
false
false
false
false
0
juldat( date ) struct ut_instant * date; { double frac, gyr; long iy0, im0; long ia, ib; long jd; /* decimal day fraction */ frac = (( double)date->i_hour/ 24.0) + ((double) date->i_minute / 1440.0) + (date->d_second / 86400.0); /* convert date to format YYYY.MMDDdd */ gyr = (double) date->year + (0.01 *...
false
false
false
false
false
0
bgav_rmff_file_header_read(bgav_rmff_chunk_t * c, bgav_input_context_t * input, bgav_rmff_file_header_t * ret) { return bgav_input_read_32_be(input, &ret->file_version) && bgav_input_read_32_be(input, &ret->num_headers); }
false
false
false
false
false
0
_get_sel_state (ipmi_interpret_ctx_t ctx, const void *record_buf, unsigned int record_buflen, uint8_t event_reading_type_code, uint8_t sensor_type, uint8_t event_direction, uint8_t offset_from_event_reading_type_code, ...
false
false
false
false
false
0
_save_to_uri (GESFormatter * formatter, GESTimeline * timeline, const gchar * uri, gboolean overwrite, GError ** error) { GFile *file; gboolean ret; GString *str; GOutputStream *stream; GError *lerror = NULL; g_return_val_if_fail (formatter->project, FALSE); file = g_file_new_for_uri (uri); stream...
false
false
false
false
false
0
bvl_addgen (lastgeneric,nat_lst,nam_lst,type,left,right) struct begen *lastgeneric; /* pointer on the last begen structure */ struct chain *nam_lst; /* generic's name list */ struct chain *nat_lst; /* generic's value list */ char *type; /* generic's type */ short left; /* array's left bound (...
false
false
false
false
false
0
multi_data_handle_incoming(int handle) { int player_index = -1; PSNET_SOCKET_RELIABLE sock = INVALID_SOCKET; char *fname; // get the player who is sending us this file sock = multi_xfer_get_sock(handle); player_index = find_player_socket(sock); // get the filename of the file fname = multi_xfer_get_filen...
false
false
false
false
false
0
clear_groups(struct isl_factor_groups *g) { if (!g) return; free(g->pos); free(g->group); free(g->cnt); free(g->rowgroup); }
false
false
false
false
false
0
gnc_table_destroy (Table * table) { /* invoke destroy callback */ if (table->gui_handlers.destroy) table->gui_handlers.destroy (table); /* free the dynamic structures */ gnc_table_free_data (table); /* free the cell tables */ g_table_destroy (table->virt_cells); gnc_table_layout_d...
false
false
false
false
false
0
io_read(void *data, char *buf, size_t size, size_t *pret) { struct _iostr *p = data; if (dico_stream_read(p->in, buf, size, pret)) { p->last_err = p->in; return dico_stream_last_error(p->in); } return 0; }
false
false
false
false
false
0
ves_icall_System_Array_CreateInstanceImpl (MonoReflectionType *type, MonoArray *lengths, MonoArray *bounds) { MonoClass *aklass, *klass; MonoArray *array; uintptr_t *sizes, i; gboolean bounded = FALSE; MONO_ARCH_SAVE_REGS; MONO_CHECK_ARG_NULL (type); MONO_CHECK_ARG_NULL (lengths); MONO_CHECK_ARG (lengths, mo...
false
false
false
false
false
0
bpa10x_tx_complete(struct urb *urb) { struct sk_buff *skb = urb->context; struct hci_dev *hdev = (struct hci_dev *) skb->dev; BT_DBG("%s urb %p status %d count %d", hdev->name, urb, urb->status, urb->actual_length); if (!test_bit(HCI_RUNNING, &hdev->flags)) goto done; if (!urb->status) hdev->stat.byte_...
false
false
false
false
false
0
process_game_info_packet( ubyte *data, header *hinfo ) { int offset; fix mission_time; ubyte paused; offset = HEADER_LENGTH; // get the mission time -- we should examine our time and the time from the server. If off by some delta // time, set our time to server time (should take ping time into account!!!) GET...
false
false
false
false
false
0
SVGCircleElement(const QualifiedName& tagName, Document* doc) : SVGStyledTransformableElement(tagName, doc) , SVGTests() , SVGLangSpace() , SVGExternalResourcesRequired() , m_cx(SVGLength(this, LengthModeWidth)) , m_cy(SVGLength(this, LengthModeHeight)) , m_r(SVGLength(this, LengthModeOther)...
false
false
false
false
false
0
aten_read_block( PIA *pi, char * buf, int count ) { int k, a, b, c, d; switch (pi->mode) { case 0: w0(0x48); w2(0xe); w2(6); for (k=0;k<count/2;k++) { w2(7); w2(6); w2(2); a = r1(); w0(0x58); b = r1(); w2(0); d = r1(); w0(0x48); c = r1(); buf[2*k] = j44(c,d); buf[2*k+1] = j44(a,b); } w2(0xc);...
false
false
false
false
false
0
drain_mpi(int4 node, int4 pid, int fd) { struct _gps *world; /* GPS array */ int4 n_index, n_flags; /* node entry info */ int4 p_index, p_flags; /* pid entry info */ int4 curr_node; /* current target */ int4 r; /* length of traces ret'd */ int4 nworld; /* # GPS records */ int flush_delay; /* signal...
false
true
false
true
true
1
setup_array (TestArray *test, gconstpointer unused) { test->array = g_pkcs11_array_new (); g_assert (test->array); }
false
false
false
false
false
0
plugin_add_hook (hexchat_plugin *pl, int type, int pri, const char *name, const char *help_text, void *callb, int timeout, void *userdata) { hexchat_hook *hook; hook = malloc (sizeof (hexchat_hook)); memset (hook, 0, sizeof (hexchat_hook)); hook->type = type; hook->pri = pri; if (name) hook->name = st...
false
false
false
false
false
0
lg_OpenCertDB(const char * configdir, const char *prefix, PRBool readOnly, NSSLOWCERTCertDBHandle **certdbPtr) { NSSLOWCERTCertDBHandle *certdb = NULL; CK_RV crv = CKR_NETSCAPE_CERTDB_FAILED; SECStatus rv; char * name = NULL; char * appName = NULL; if (prefix == NULL) { ...
false
false
false
false
false
0
smk_tskacc(struct task_smack *tsp, struct smack_known *obj_known, u32 mode, struct smk_audit_info *a) { struct smack_known *sbj_known = smk_of_task(tsp); int may; int rc; /* * Check the global rule list */ rc = smk_access(sbj_known, obj_known, mode, NULL); if (rc >= 0) { /* * If there is an entr...
false
false
false
false
false
0
ComputeBounds() { vtkIdType i; int j; double *x; if ( this->GetMTime() > this->ComputeTime ) { this->Bounds[0] = this->Bounds[2] = VTK_DOUBLE_MAX; this->Bounds[1] = this->Bounds[3] = -VTK_DOUBLE_MAX; for (i=0; i < this->GetNumberOfPoints(); ++i) { x = this->GetPoint(i); for (...
false
false
false
false
false
0
media_art_init (void) { GError *error = NULL; g_return_val_if_fail (initialized == FALSE, FALSE); media_art_plugin_init (0); /* Cache to know if we have already handled uris */ media_art_cache = g_hash_table_new_full (g_str_hash, g_str_equal, ...
false
false
false
false
false
0
cq_periodic_main_add(int period, cq_invoke_t event, void *arg) { cq_main_init(); return cq_periodic_add(callout_queue, period, event, arg); }
false
false
false
false
false
0
ph_state_irq(struct hfc_multi *hc, u_char r_irq_statech) { struct dchannel *dch; int ch; int active; u_char st_status, temp; /* state machine */ for (ch = 0; ch <= 31; ch++) { if (hc->chan[ch].dch) { dch = hc->chan[ch].dch; if (r_irq_statech & 1) { HFC_outb_nodebug(hc, R_ST_SEL, hc->chan[ch...
false
false
false
false
false
0
basic_autotools_plugin_instance_init (GObject *obj) { gint i; BasicAutotoolsPlugin *ba_plugin = ANJUTA_PLUGIN_BASIC_AUTOTOOLS (obj); for (i = 0; i < IANJUTA_BUILDABLE_N_COMMANDS; i++) ba_plugin->commands[i] = NULL; ba_plugin->fm_current_file = NULL; ba_plugin->pm_current_file = NULL; ba_plugin->current_editor...
false
false
false
false
false
0
check_numeric_or_string_types (expresion_result * left, expresion_result * right) { if (typedef_is_array(left->type) && left->type.chunk[1].type == TYPE_CHAR && typedef_is_string(right->type)) { left->type = typedef_new(TYPE_STRING); left->lvalue = 0; codeblock_add (code, MN_A2ST...
false
false
false
false
false
0
setFaceUp( bool faceUp ) { qreal flippedness = faceUp ? 1.0 : 0.0; if ( d->faceUp != faceUp || d->flipValue != flippedness ) { d->faceUp = faceUp; d->setFlippedness( flippedness ); } }
false
false
false
false
false
0
ComputeComponentCount(NodeList const& nl) { int count = 2; for(NodeList::const_iterator ni = nl.begin(); ni != nl.end(); ++ni) { if(cmTarget* target = this->EntryList[*ni].Target) { if(cmTarget::LinkInterface const* iface = target->GetLinkInterface(this->Config, this->HeadTarget)) ...
false
false
false
false
false
0
gsb_data_bank_new ( const gchar *name ) { struct_bank *bank; bank = g_malloc0 ( sizeof ( struct_bank )); bank -> bank_number = gsb_data_bank_max_number () + 1; if (name) bank -> bank_name = my_strdup (name); bank_list = g_slist_append ( bank_list, bank ); return bank -> bank_number; }
false
false
false
false
false
0
strnl0(const char *s) /* replace "\\n" by "\n" in a cmd-line arg */ { char *t,*u; t=malloc(strlen(s)+1); u=t; while (*s!=0) { if ((*s=='\\')&&(s[1]=='n')) { *u='\n'; s++; } else *u=*s; s++; u++; } *u=0; return t; }
false
false
false
false
false
0
r700_vm_init(struct drm_device *dev) { drm_radeon_private_t *dev_priv = dev->dev_private; /* initialise the VM to use the page table we constructed up there */ u32 vm_c0, i; u32 mc_vm_md_l1; u32 vm_l2_cntl, vm_l2_cntl3; /* okay set up the PCIE aperture type thingo */ RADEON_WRITE(R700_MC_VM_SYSTEM_APERTURE_LOW_A...
false
false
false
false
false
0
lightdm_get_language (void) { const gchar *lang; GList *link; static const gchar *short_lang = NULL; if (short_lang) goto match; lang = g_getenv ("LANG"); if (!lang) return NULL; /* Convert to a short form language code */ gchar *command = g_strconcat ("/usr/share/lang...
false
false
false
false
false
0
utils_get_selected_row (GtkTreeView* view, GtkTreeIter* iter) { GtkTreeIter _vala_iter = {0}; gint result = 0; GtkTreeSelection* select = NULL; GtkTreeView* _tmp0_ = NULL; GtkTreeSelection* _tmp1_ = NULL; GtkTreeSelection* _tmp2_ = NULL; GtkTreeSelection* _tmp3_ = NULL; GtkTreeIter _tmp4_ = {0}; gboolean _tmp5...
false
false
false
false
false
0
scroll_idl(int n, int del, int ins, NCURSES_CH_T blank) { int i; if (!((parm_delete_line || delete_line) && (parm_insert_line || insert_line))) return ERR; GoTo(del, 0); UpdateAttrs(blank); if (n == 1 && delete_line) { TPUTS_TRACE("delete_line"); putp(delete_line); } else if (parm_delete_li...
false
false
false
false
false
0
on_helpForumAction_activated() { bool tds=QDesktopServices::openUrl(QUrl("http://lalescu.ro/liviu/fet/forum/")); if(!tds){ QMessageBox::warning(this, tr("FET warning"), tr("Could not start the default Internet browser (trying to open the link %1)." " Maybe you can try to manually start your browser and open this...
false
false
false
false
false
0
setupdsp (int audiofd, int channelCount, int frequency) { int format = AFMT_S16_NE; if (ioctl(audiofd, SNDCTL_DSP_SETFMT, &format) == -1) { perror("set format"); exit(EXIT_FAILURE); } if (format != AFMT_S16_NE) { fprintf(stderr, "format not correct.\n"); exit(EXIT_FAILURE); } if (ioctl(audiofd, SNDCTL...
false
false
false
false
false
0
__lambda35_ (Block8Data* _data8_) { UnityResultPreviewer * self; void* result = NULL; UnityAbstractPreview* preview = NULL; UnityAbstractPreview* _tmp0_ = NULL; UnityAbstractPreviewCallback _tmp1_ = NULL; void* _tmp1__target = NULL; self = _data8_->self; _tmp0_ = unity_result_previewer_run (self); preview = _t...
false
false
false
false
false
0
mei_fw_status2str(struct mei_fw_status *fw_status, char *buf, size_t len) { ssize_t cnt = 0; int i; buf[0] = '\0'; if (len < MEI_FW_STATUS_STR_SZ) return -EINVAL; for (i = 0; i < fw_status->count; i++) cnt += scnprintf(buf + cnt, len - cnt, "%08X ", fw_status->status[i]); /* drop last space */ b...
false
false
false
false
false
0
report_iauth_stats(aClient *sptr, char *to) { aExtData *ectmp = iauth_stats; while (ectmp) { sendto_one(sptr, ":%s %d %s :%s", ME, RPL_STATSDEBUG, to, ectmp->line); ectmp = ectmp->next; } }
false
false
false
false
false
0
GetConnectedComponents() { if (this->ConnectedComponents) return (this->ConnectedComponents); int i,j; vtkIdType v1,v2; std::queue<int> VQueue; int *Visited=new int [this->GetNumberOfPoints()]; vtkIdList *Component; vtkIdList *VList=vtkIdList::New(); this->ConnectedComponents=vtkIdListCollection::New(); ...
false
false
false
false
false
0
ancestorScope (void) { tokenInfo *result = NULL; unsigned int i; for (i = Ancestors.count ; i > 0 && result == NULL ; --i) { tokenInfo *const token = Ancestors.list + i - 1; if (token->type == TOKEN_IDENTIFIER && token->tag != TAG_UNDEFINED && token->tag != TAG_INTERFACE) result = token; } return ...
false
false
false
false
false
0
SummarizeAverages() { int i; DBT key,value; Verbose(" x yN (Variable content)\n---------------------------------------------------------\n"); for (i = 0; i < CF_OBSERVABLES; i++) { Verbose("%2d. MAX <%-10s-in> = %10f - %10f u %10f\n",i,OBS[i][0],MIN.Q[i].expect,MAX.Q[i].expect,sqrt(MAX.Q[i].var)); } ...
false
false
false
false
true
1
update_after_action (Sheet *sheet, WorkbookControl *wbc) { gnm_app_recalc (); if (sheet != NULL) { g_return_if_fail (IS_SHEET (sheet)); sheet_mark_dirty (sheet); sheet_update (sheet); if (sheet->workbook == wb_control_get_workbook (wbc)) WORKBOOK_VIEW_FOREACH_CONTROL (wb_control_view (wbc), control, ...
false
false
false
false
false
0
parsed(int tok, const char* end, const char** errPos) { if (errPos) *errPos = end; return tok; }
false
false
false
false
false
0
gd_notification_size_allocate (GtkWidget *widget, GtkAllocation *allocation) { GdNotification *notification = GD_NOTIFICATION (widget); GdNotificationPrivate *priv = notification->priv; GtkBin *bin = GTK_BIN (widget); GtkAllocation child_allocation; GtkBorder padding; GtkRequ...
false
false
false
false
false
0
unmarshalProfile(const IOP::TaggedProfile& profile, IIOP::ProfileBody& body) { OMNIORB_ASSERT(profile.tag == IOP::TAG_INTERNET_IOP); cdrEncapsulationStream s(profile.profile_data.get_buffer(), profile.profile_data.length(), 1); body.version.major = s.unmarshalOctet(); body.version.minor =...
false
false
false
false
false
0
stb0899_release(struct dvb_frontend *fe) { struct stb0899_state *state = fe->demodulator_priv; dprintk(state->verbose, FE_DEBUG, 1, "Release Frontend"); /* post process event */ stb0899_postproc(state, STB0899_POSTPROC_GPIO_POWER, 0); kfree(state); }
false
false
false
false
false
0
Reset() { m_nLastAllocatedBlock = -1; // Flush list of garbage blocks while (m_psGarbageBlocks != NULL) { TABBlockRef *psNext = m_psGarbageBlocks->psNext; CPLFree(m_psGarbageBlocks); m_psGarbageBlocks = psNext; } }
false
false
false
false
false
0
dupablchain(chain_list* ablchain) { chain_list* chain,*res=NULL; for (chain=ablchain;chain;chain=chain->NEXT) { res=addchain(res,dupablexpr(chain->DATA)); } return res; }
false
false
false
false
false
0
nocustom (void) { if (picasso_on && currprefs.picasso96_nocustom) return true; return false; }
false
false
false
false
false
0
AddFormInfo(char *value, char *contenttype, FormInfo *parent_form_info) { FormInfo *form_info; form_info = (FormInfo *)malloc(sizeof(FormInfo)); if(form_info) { memset(form_info, 0, sizeof(FormInfo)); if (value) form_info->value = value; ...
false
false
false
false
false
0
_Pickler_GetString(PicklerObject *self) { PyObject *output_buffer = self->output_buffer; assert(self->output_buffer != NULL); self->output_buffer = NULL; /* Resize down to exact size */ if (_PyBytes_Resize(&output_buffer, self->output_len) < 0) return NULL; return output_buffer; }
false
false
false
false
false
0
_vala_string_array_contains (gchar** stack, int stack_length, gchar* needle) { int i; for (i = 0; i < stack_length; i++) { if (g_strcmp0 (stack[i], needle) == 0) { return TRUE; } } return FALSE; }
false
false
false
false
false
0
write_phy_reg(struct brcms_phy *pi, u16 addr, u16 val) { #ifdef CONFIG_BCM47XX bcma_wflush16(pi->d11core, D11REGOFFS(phyregaddr), addr); bcma_write16(pi->d11core, D11REGOFFS(phyregdata), val); if (addr == 0x72) (void)bcma_read16(pi->d11core, D11REGOFFS(phyregdata)); #else bcma_write32(pi->d11core, D11REGOFFS(phyr...
false
false
false
false
false
0
table_values(register tableobject *self) { PyObject *v; const apr_array_header_t *ah; apr_table_entry_t *elts; int i, j; ah = apr_table_elts(self->table); elts = (apr_table_entry_t *) ah->elts; /* PYTHON 2.5: 'PyList_New' uses Py_ssize_t for input parameters */ v = PyList_New(ah->nelt...
false
false
false
false
false
0
ff_snow_vertical_compose97i(IDWTELEM *b0, IDWTELEM *b1, IDWTELEM *b2, IDWTELEM *b3, IDWTELEM *b4, IDWTELEM *b5, int width){ int i; for(i=0; i<width; i++){ b4[i] -= (W_DM*(b3[i] + b5[i])+W_DO)>>W_DS; b3[i] -= (W_CM*(b2[i] + b4[i])+W_CO)>>W_CS; #ifdef liftS b2[i] += (W_BM*(b1[i] + b3[i])+...
false
false
false
false
false
0
gda_tree_node_get_parent (GdaTreeNode *node) { GdaTreeNode *parent; g_return_val_if_fail (GDA_IS_TREE_NODE (node), NULL); parent = node->priv->parent; if (parent && !parent->priv->parent) return NULL; /* avoid returning the private GdaTree's ROOT node */ else return parent; }
false
false
false
false
false
0
ai_is_troop_need_new_camp() { //--- check whether the current military force is already big enough ---// if( ai_has_too_many_camp() ) return 0; //----- expand if it has enough cash -----// if( !ai_should_spend(50+pref_military_development/2) ) return 0; //----- if existing camps can already host all units ...
false
false
false
false
false
0
lo_read_simple(struct loop_device *lo, struct request *rq, loff_t pos) { struct bio_vec bvec; struct req_iterator iter; struct iov_iter i; ssize_t len; rq_for_each_segment(bvec, rq, iter) { iov_iter_bvec(&i, ITER_BVEC, &bvec, 1, bvec.bv_len); len = vfs_iter_read(lo->lo_backing_file, &i, &pos); if (len < 0...
false
false
false
false
false
0
work_area_style_free(void *that) { work_area_style_ty *this_thing; this_thing = (work_area_style_ty *)that; if (!this_thing) return; this_thing->reference_count--; assert(this_thing->reference_count >= 0); if (this_thing->reference_count > 0) return; trace(("work_area_style_free(this_thin...
false
false
false
false
false
0
non_ecm_put_bit(void *user_data, int bit) { t31_state_t *s; s = (t31_state_t *) user_data; if (bit < 0) { /* Special conditions */ switch (bit) { case PUTBIT_TRAINING_IN_PROGRESS: break; case PUTBIT_TRAINING_FAILED: s->at_state.rx_trained ...
false
false
false
false
false
0
hostap_set_string(struct net_device *dev, int rid, const char *val) { struct hostap_interface *iface; char buf[MAX_SSID_LEN + 2]; int len; iface = netdev_priv(dev); len = strlen(val); if (len > MAX_SSID_LEN) return -1; memset(buf, 0, sizeof(buf)); buf[0] = len; /* little endian 16 bit word */ memcpy(buf + 2...
false
false
false
false
false
0
printTransformations() { llvm::outs() << "Registered Transformations:\n"; std::map<std::string, Transformation *>::iterator I, E; for (I = TransformationsMap.begin(), E = TransformationsMap.end(); I != E; ++I) { llvm::outs() << " [" << (*I).first << "]: "; llvm::outs() << (*I).second->ge...
false
false
false
false
false
0
parse_timezone(const char *tz) { const char *rfc822_timezones[][4] = { { "M", NULL }, /* UTC-12 */ { "L", NULL }, { "K", NULL }, { "I", NULL }, { "H", "PST", NULL }, /* UTC-8 */ { "G", "MST", "PDT", NULL }, /* UTC-7 */ { "F", "CST", "MDT", NULL }, /* UTC-6 */ { "E", "EST", "CDT", NULL }, /* UTC-5 *...
false
false
false
false
false
0
ptnd_probe_delete_all_but(PT_pdc *pdc, int count) { PT_tprobes *tprobe; int i; for (i=0,tprobe = pdc->tprobes; tprobe && i< count; i++,tprobe = tprobe->next ) ; if (tprobe) { while(tprobe->next) { destroy_PT_tprobes( tprobe->next ); } } }
false
false
false
false
false
0
trans_createMessage(const QByteArray &transactionId) { // ChannelBind StunMessage message; message.setMethod(StunTypes::ChannelBind); message.setId((const quint8 *)transactionId.data()); QList<StunMessage::Attribute> list; { StunMessage::Attribute a; a.type = StunTypes::CHANNEL_NUMBER; a.value =...
false
false
false
false
false
0
cmath_rect(PyObject *self, PyObject *args) { Py_complex z; double r, phi; if (!PyArg_ParseTuple(args, "dd:rect", &r, &phi)) return NULL; errno = 0; PyFPE_START_PROTECT("rect function", return 0) /* deal with special values */ if (!Py_IS_FINITE(r) || !Py_IS_FINITE(phi)) { /* ...
false
false
false
false
false
0
toggleDrugSelector() { if (m_CurrentView && m_CurrentView->drugSelector()) { bool setToVisible = !m_CurrentView->drugSelector()->isVisible(); m_CurrentView->setMinimumHeight(setToVisible ? 600 : 200); m_CurrentView->drugSelector()->setVisible(setToVisible); aToggleDrugSelector->setCh...
false
false
false
false
false
0
get_discard_block(Stasche_lm_dt *sld, const int pgno) { int i; Block *ret = NULL; for (i = 0; i < sld->mt_num * 2; i++) { if (sld->seclock[i].pp == PRE) { Block *b = sld->seclock[i].b; int mtno = b->no; if (in_IntSet(sld->startf, mtno) && sld->tas...
false
false
false
false
false
0
camel_folder_change_info_add_update_list (CamelFolderChangeInfo *info, const GPtrArray *list) { gint i; g_return_if_fail (info != NULL); g_return_if_fail (list != NULL); for (i = 0; i < list->len; i++) camel_folder_change_info_add_update (info, list->pdata[i]); }
false
false
false
false
false
0
folks_debug_print_heading (FolksDebug* self, const gchar* domain, GLogLevelFlags level, const gchar* format, ...) { static const gint heading_colours[] = {31, 32, 34}; gchar* wrapper_format = NULL; gchar* _tmp0_ = NULL; gboolean _tmp1_ = FALSE; gboolean _tmp2_ = FALSE; va_list valist = {0}; gchar* output = NULL;...
false
false
false
false
false
0