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
Fwrbyte() { struct stream *strm; int ch; int flg; flg = *FLAGPTR(argStkPtr-1); if(flg != fSTREAM || !isoutfile(argStkPtr-1,BINARY)) { error(wrbytesym,err_bout,voidsym); return(brkerr()); } flg = *FLAGPTR(argStkPtr); if(flg == fFIXNUM) { ch = *WORD2PTR(argStkPtr);...
false
false
false
false
false
0
onFocusIn(FXObject* sender,FXSelector sel,void* ptr){ FXGLCanvas::onFocusIn(sender,sel,ptr); if(selection && selection->handle(this,FXSEL(SEL_FOCUSIN,0),ptr)){ update(); } return 1; }
false
false
false
false
false
0
tryAllocateResourcesForConstExt(MachineInstr* MI) { const HexagonInstrInfo *QII = (const HexagonInstrInfo *) TII; MachineInstr *PseudoMI = MF.CreateMachineInstr(QII->get(Hexagon::A4_ext), MI->getDebugLoc()); if (ResourceTracker->canReserveResources(PseudoMI)) { ...
false
false
false
false
false
0
stac92hd7x_proc_hook(struct snd_info_buffer *buffer, struct hda_codec *codec, hda_nid_t nid) { stac92hd_proc_hook(buffer, codec, nid); if (nid == codec->core.afg) analog_loop_proc_hook(buffer, codec, 0xfa0); }
false
false
false
false
false
0
tailp(c,k0,m,d,nu) double c, *k0, nu; INT m, d; { INT i; double p; p = 0; if (nu==0) { for (i=0; i<m; i++) if (k0[i]>0) p += k0[i]*exp(LGAMMA((d+1-i)/2.0)-(d+1-i)*LOGPI/2) *(1-pchisq(c*c,(double) d+1-i)); } else { for (i=0; i<m; i++) if (k0[i]>0) p += k0[i]*exp(LGAMMA((d+1-i)/2.0)-(d...
false
false
false
false
false
0
_client_reacquire_lock (xlator_t *this, clnt_fd_ctx_t *fdctx) { int32_t ret = -1; int32_t gf_cmd = 0; int32_t gf_type = 0; gfs3_lk_req req = {{0,},}; struct gf_flock flock = {0,}; fd_lk_ctx_t *lk_...
false
true
false
false
false
1
format_option_help(cliopts_entry *entry, char *buf) { char *bufp = buf; if (entry->kshort) { bufp += sprintf(bufp, " -%c ", entry->kshort); } #define _advance_margin(offset) \ while(bufp-buf < offset || *bufp) { \ if (!*bufp) { \ *bufp = ' '; \ } \ bufp++; \...
false
false
false
false
false
0
gnttab_request_free_callback(struct gnttab_free_callback *callback, void (*fn)(void *), void *arg, u16 count) { unsigned long flags; struct gnttab_free_callback *cb; spin_lock_irqsave(&gnttab_list_lock, flags); /* Check if the callback is already on the list */ cb = gnttab_free_callback_list; while (cb) {...
false
false
false
false
false
0
Stop() { if (fOverruns > 0) { jack_error("WARNING: %d message buffer overruns!", fOverruns); } else { jack_log("no message buffer overruns"); } if (fGuard.Lock()) { fRunning = false; fGuard.Signal(); fGuard.Unlock(); fThread.Stop(); } else { f...
false
false
false
false
false
0
tcp_peer_send_blocking(mca_oob_tcp_module_t *mod, int sd, void* data, size_t size) { unsigned char* ptr = (unsigned char*)data; size_t cnt = 0; int retval; opal_output_verbose(OOB_TCP_DEBUG_CONNECT, orte_oob_base_framework.framework_output, "%s...
false
false
false
false
false
0
findConstantWeightsEdges( InputData* pData, vector<AlphaReal>& halfWeightsPerClass, vector<AlphaReal>& halfEdges) { const int numClasses = pData->getNumClasses(); const int numExamples = pData->getNumExamples(); memset(&(halfWeightsPerClass[0]), 0, sizeof(AlphaReal) * halfWeightsPerClass.size...
false
false
false
false
false
0
yp_update_thread(void *arg) { INFO0("YP update thread started"); yp_running = 1; while (yp_running) { struct yp_server *server; thread_sleep (200000); /* do the YP communication */ thread_rwlock_rlock (&yp_lock); server = (struct yp_server *)active_yps; ...
false
false
false
false
false
0
qreigen(di_ml_matrix proba,long n) { /* QR eigenvector/eigenvalue method for symmetric matrix */ double accuracy; long i, j; accuracy = 1.0e-6; for (i = 0; i < n; i++) { for (j = 0; j < n; j++) eigvecs[i][j] = 0.0; eigvecs[i][i] = 1.0; } tridi...
false
false
false
false
false
0
stop_preview () { yield = true; PWaitAndSignal m(core_mutex); PTRACE(4, "AudioInputCore\tStopping Preview"); if (!preview_config.active || stream_config.active) { PTRACE(1, "AudioInputCore\tTrying to stop preview in wrong state"); } internal_close(); internal_set_manager(desired_device); preview_...
false
false
false
false
false
0
ga_record_browser_get_property(GObject * object, guint property_id, GValue * value, GParamSpec * pspec) { GaRecordBrowser *browser = GA_RECORD_BROWSER(object); GaRecordBrowserPrivate *priv = GA_RECORD_BROWSER_GET_PRIVATE(browser); switch (proper...
false
false
false
false
false
0
config_has_specials(const char *text) { g_return_val_if_fail(text != NULL, FALSE); while (*text != '\0') { if (!i_isalnum(*text) && *text != '_') return TRUE; text++; } return FALSE; }
false
false
false
false
false
0
tolua_px_ecl_Drawable_set_pixel00(lua_State* tolua_S) { #ifndef TOLUA_RELEASE tolua_Error tolua_err; if ( !tolua_isusertype(tolua_S,1,"Drawable",0,&tolua_err) || !tolua_isusertype(tolua_S,2,"const GS",0,&tolua_err) || !tolua_isnumber(tolua_S,3,0,&tolua_err) || !tolua_isnumber(tolua_S,4,0,&tolua_er...
false
false
false
false
false
0
log(void) const { size_t i; ArLog::log(ArLog::Terse, "Num arguments: %d", getArgc()); for (i = 0; i < getArgc(); ++i) ArLog::log(ArLog::Terse, "Arg %d: %s", i, getArgv()[i]); }
false
false
false
false
false
0
combination_does_multi_exp_need_ul( expression* exp /*!< Pointer to expression to check for multi-expression underlines */ ) { PROFILE(COMBINATION_DOES_MULTI_EXP_NEED_UL); bool ul = FALSE; /* Return value for this function */ bool and_op; /* Specifies if current expression is an AND or LAND operation */ ...
false
false
false
false
false
0
bfa_lps_login_comp(struct bfa_lps_s *lps) { if (!lps->bfa->fcs) { bfa_cb_queue(lps->bfa, &lps->hcb_qe, bfa_lps_login_comp_cb, lps); return; } if (lps->fdisc) bfa_cb_lps_fdisc_comp(lps->bfa->bfad, lps->uarg, lps->status); else bfa_cb_lps_flogi_comp(lps->bfa->bfad, lps->uarg, lps->status); }
false
false
false
false
false
0
make_pack_expansion (tree arg) { tree result; tree parameter_packs = NULL_TREE; bool for_types = false; struct find_parameter_pack_data ppd; if (!arg || arg == error_mark_node) return arg; if (TREE_CODE (arg) == TREE_LIST) { /* The only time we will see a TREE_LIST here is for a base ...
false
false
false
false
true
1
tp_intset_union_update (TpIntset *self, const TpIntset *other) { gpointer key, value; GHashTableIter iter; g_hash_table_iter_init (&iter, (GHashTable *) other->table); while (g_hash_table_iter_next (&iter, &key, &value)) { gsize v = GPOINTER_TO_SIZE (value); intset_update_largest_ever (se...
false
false
false
false
false
0
opj_lupSolve (OPJ_FLOAT32 * pResult, OPJ_FLOAT32 * pMatrix, OPJ_FLOAT32 * pVector, OPJ_UINT32* pPermutations, OPJ_UINT32 n,OPJ_FLOAT32 * p_intermediate_data) { OPJ_UINT32 i,j; OPJ_INT32 k; OPJ_FLOAT32 sum; OPJ_FLOAT32 u; OPJ_UINT32 lStride = n+1; OPJ_FLOAT32 * lCurrentPtr; OPJ_FLOAT32 * lIntermediatePtr...
false
false
false
false
false
0
fintek_suspend(struct pnp_dev *pdev, pm_message_t state) { struct fintek_dev *fintek = pnp_get_drvdata(pdev); unsigned long flags; fit_dbg("%s called", __func__); spin_lock_irqsave(&fintek->fintek_lock, flags); /* disable all CIR interrupts */ fintek_cir_reg_write(fintek, CIR_STATUS_IRQ_MASK, CIR_STATUS); sp...
false
false
false
false
false
0
_fetch_headers(OggVorbis_File *vf,vorbis_info *vi,vorbis_comment *vc, long *serialno,ogg_page *og_ptr){ ogg_page og; ogg_packet op; int i,ret; int allbos=0; if(!og_ptr){ ogg_int64_t llret=_get_next_page(vf,&og,CHUNKSIZE); if(llret==OV_EREAD)return(OV_EREAD); if(llret<0)return(OV_ENOTVORBIS);...
false
false
false
false
false
0
shiftLast(int32_t delta) { if (U_SUCCESS(status) && delta != 0) { int32_t i = vec->size(); if (i > 0) { --i; vec->setElementAt(delta + vec->elementAti(i), i); --i; vec->setElementAt(delta + vec->elementAti(i), i); } } }
false
false
false
false
false
0
chk_tran_gate(struct gate_t *gp) { int32 pnum; struct expr_t *px1, *px2; struct net_t *np1, *np2; np1 = np2 = NULL; /* first cannot have delay */ if (gp->g_du.pdels != NULL) { __sgferr(816, "%s cannot have delay", gp->gmsym->synam); __free_dellst(gp->g_du.pdels); gp->g_du.pdels = NULL; } /* must m...
false
false
false
false
false
0
acdQualToSeqbegin(const AcdPAcd thys, const char *qual, ajint defval, ajint *result, AjPStr* valstr) { AjBool ret; ret = acdGetValueAssoc(thys, qual, valstr); acdLog("acdQualToSeqpos item: %S qual: %s defval: %d str: '%S' ret: %B\n", thys->Name, qual, defval, *valstr, ret); if(ret) { acdV...
false
false
false
false
false
0
device_block(DBusConnection *conn, struct btd_device *device, gboolean update_only) { int err = 0; bdaddr_t src; if (device->blocked) return 0; if (device->connected) do_disconnect(device); g_slist_foreach(device->drivers, (GFunc) driver_remove, device); if (!update_only) err = btd_adapter_block_a...
false
false
false
false
false
0
nouveau_connector_detect_depth(struct drm_connector *connector) { struct nouveau_drm *drm = nouveau_drm(connector->dev); struct nouveau_connector *nv_connector = nouveau_connector(connector); struct nouveau_encoder *nv_encoder = nv_connector->detected_encoder; struct nvbios *bios = &drm->vbios; struct drm_display_...
false
false
false
false
false
0
DataProxy_signal_validate_row_changes_callback(GdaDataProxy* self, gint p0,gint p1,void* data) { using namespace Gnome::Gda; typedef sigc::slot< Glib::Error,int,int > SlotType; // Do not try to call a signal on a disassociated wrapper. if(Glib::ObjectBase::_get_current_wrapper((GObject*) self)) { #ifdef ...
false
false
false
false
false
0
PackRestrictionTypes( void *theEnv, RESTRICTION *rptr, EXPRESSION *types) { EXPRESSION *tmp; register unsigned i; rptr->tcnt = 0; for (tmp = types ; tmp != NULL ; tmp = tmp->nextArg) rptr->tcnt++; if (rptr->tcnt != 0) rptr->types = (void **) gm2(theEnv,(sizeof(void *) * rptr->tcnt)); ...
false
false
false
false
false
0
input_name2mask(const char *name, pmask_t *mask, pmask_t *value, char *imask, char *omask) { static char sigtab[10] = "EeSsPpAaBb"; char im, om; pmask_t m, v; om = 0ULL; im = 0ULL; m = 0ULL; v = 0ULL; while (*name) { int in, out, bit, neg; for (in = 0; (in < sizeof(sigtab)) && (sigtab[in] != *name);...
true
true
false
false
false
1
rewind(int subsong) { int i; // counter // rewind HSC player pattpos = 0; songpos = 0; pattbreak = 0; speed = 2; del = 1; songend = 0; mode6 = 0; bd = 0; fadein = 0; opl->init(); // reset OPL chip opl->write(1,32); opl->write(8,128); opl->write(0xbd,0); for(i=0;i<9;i++) setinstr((char) ...
false
false
false
false
false
0
thumb_app_set_duration (ThumbApp *app) { gint64 len = -1; if (gst_element_query_duration (app->play, GST_FORMAT_TIME, &len) && len != -1) { app->duration = len / GST_MSECOND; return TRUE; } app->duration = -1; return FALSE; }
false
false
false
false
false
0
search_evaluate(struct searchinfo *si) { int rc, rc2; switch (si->type) { case search_orderedsubj: /* DUMMIES for THREAD and SORT */ case search_references1: case search_references2: case search_references3: case search_references4: case search_arrival: case search_cc: case search_date: ...
false
false
false
false
false
0
AsStrlwr ( char *SrcString) { char *String; /* Walk entire string, lowercasing the letters */ if (SrcString) { for (String = SrcString; *String; String++) { *String = (char) ACPI_TOLOWER (*String); } } }
false
false
false
false
false
0
save_cont(ScmVM *vm) { ScmContFrame *c = vm->cont, *prev = NULL, *tmp; ScmCStack *cstk; ScmEscapePoint *ep; ScmObj *s, *d; int i; /* Save the environment chain first. */ vm->env = save_env(vm, vm->env); if (!IN_STACK_P((ScmObj*)c)) return; /* First pass */ do { int siz...
false
false
false
false
false
0
transliterate(Replaceable& text, UTransPosition& index, UChar32 insertion, UErrorCode& status) const { UnicodeString str(insertion); _transliterate(text, index, &str, status); }
false
false
false
false
false
0
handleUnmapNotify(const XUnmapEvent &unmap) { #if 1 if (unmap.send_event) { if (unmap.window != handle() && handle() != 0) { xapp->handleWindowEvent(unmap.window, *(XEvent *)&unmap); } else { MSG(("unhandled root window unmap: %lX %lX", (long)unmap.window, (long)handle())); ...
false
false
false
false
false
0
test_dialog (void) { const gchar buffer1[] = "<interface>" " <object class=\"GtkDialog\" id=\"dialog1\">" " <child internal-child=\"vbox\">" " <object class=\"GtkVBox\" id=\"dialog1-vbox\">" " <child internal-child=\"action_area\">" " <object class=\"GtkHButtonBox\...
false
false
false
false
false
0
x509_get_sig_alg( const x509_buf *sig_oid, int *sig_alg ) { if( sig_oid->len == 9 && memcmp( sig_oid->p, OID_PKCS1, 8 ) == 0 ) { if( sig_oid->p[8] >= 2 && sig_oid->p[8] <= 5 ) { *sig_alg = sig_oid->p[8]; return( 0 ); } if ( sig_oid->p[8] >= 11 && ...
false
false
false
false
false
0
options_free() { option_t *opt; int i; listitem_t *item; icc_mapping_entry_t *entry; for (i = 0; i < optionset_count; i++) free(optionsets[i]); free(optionsets); optionsets = NULL; optionset_alloc = 0; optionset_count = 0; if (qualifier_data) { for (item = quali...
false
false
false
false
false
0
get_unique_circ_id_by_conn(or_connection_t *conn) { circid_t test_circ_id; circid_t attempts=0; circid_t high_bit; tor_assert(conn); if (conn->circ_id_type == CIRC_ID_TYPE_NEITHER) { log_warn(LD_BUG, "Trying to pick a circuit ID for a connection from " "a client with no identity."); retu...
false
false
false
false
false
0
freerdp_chanman_data(freerdp* instance, int chan_id, char* data, int data_size, int flags, int total_size) { rdpChanMan* chan_man; struct rdp_chan* lrdp_chan; struct chan_data* lchan_data; int index; chan_man = freerdp_chanman_find_by_rdp_inst(instance); if (chan_man == 0) { DEBUG_CHANMAN("could not find cha...
false
false
false
false
false
0
IsAttr(const char* attribute) const { return (strcmp(GetName(), attribute) == 0 || strcmp(GetAbout(), attribute) == 0); }
false
false
false
false
false
0
vect_is_simple_use (tree operand, loop_vec_info loop_vinfo, bb_vec_info bb_vinfo, gimple *def_stmt, tree *def, enum vect_def_type *dt) { basic_block bb; stmt_vec_info stmt_vinfo; struct loop *loop = NULL; if (loop_vinfo) loop = LOOP_VINFO_LOOP (loop_vinfo); *def_stmt = NULL; ...
false
false
false
true
false
1
getOrInsertFunction(StringRef Name, Type *RetTy, ...) { va_list Args; va_start(Args, RetTy); // Build the list of argument types... std::vector<Type*> ArgTys; while (Type *ArgTy = va_arg(Args, Type*)) ArgTys.push_back(ArgTy); va_end(Args); // Build the function...
false
false
false
false
false
0
get_example_value(Field::glom_field_type field_type) { switch(field_type) { case(Field::TYPE_BOOLEAN): return Gnome::Gda::Value(true); case(Field::TYPE_DATE): { bool success = false; return parse_value(field_type, "01/02/03", success, true /* iso_format */); } case(Field::TYPE_...
false
false
false
false
false
0
open_fs (struct fs_node *node, uint8_t read, uint8_t write) { /* Has the node got an open callback ? */ if (node->open != 0) return node->open(node); }
false
false
false
false
false
0
Cbuf_AddText (char *text) { int l; l = strlen (text); if (cmd_text.cursize + l >= cmd_text.maxsize) { Com_Printf ("Cbuf_AddText: overflow! Discarding text: %s\n", text); return; } SZ_Write (&cmd_text, text, l); }
false
false
false
false
false
0
msg_screen_putchar(c, attr) int c; int attr; { msg_didout = TRUE; /* remember that line is not empty */ screen_putchar(c, msg_row, msg_col, attr); #ifdef FEAT_RIGHTLEFT if (cmdmsg_rl) { if (--msg_col == 0) { msg_col = Columns; ++msg_row; } } else #endif { if (++msg_c...
false
false
false
false
false
0
netvsc_process_raw_pkt(struct hv_device *device, struct vmbus_channel *channel, struct netvsc_device *net_device, struct net_device *ndev, u64 request_id, struct vmpacket_descriptor *desc) { struct nvsp_message *nvmsg; struct net_device_context *net_device_ctx = netdev_priv(ndev); ...
false
false
false
false
false
0
lock_recursive(void) { DENTER(TOP_LAYER, "lock_recursive"); SGE_LOCK(LOCK_GLOBAL, LOCK_WRITE); sleep(15); SGE_UNLOCK(LOCK_GLOBAL, LOCK_WRITE); DEXIT; return; }
false
false
false
false
false
0
ath10k_control_beaconing(struct ath10k_vif *arvif, struct ieee80211_bss_conf *info) { struct ath10k *ar = arvif->ar; int ret = 0; lockdep_assert_held(&arvif->ar->conf_mutex); if (!info->enable_beacon) { ret = ath10k_wmi_vdev_down(ar, arvif->vdev_id); if (ret) ath10k_warn(ar, "failed to down vdev_i...
false
false
false
false
false
0
get_delta(void **out, git_odb *odb, git_pobject *po) { git_odb_object *src = NULL, *trg = NULL; unsigned long delta_size; void *delta_buf; *out = NULL; if (git_odb_read(&src, odb, &po->delta->id) < 0 || git_odb_read(&trg, odb, &po->id) < 0) goto on_error; delta_buf = git_delta( git_odb_object_data(src...
false
false
false
false
false
0
PerformValidation( wxPGProperty* p, wxVariant& pendingValue ) { // // Runs all validation functionality. // Returns true if value passes all tests. // //wxLogDebug(wxT("wxPropertyGrid::PerformValidation(p=%s)"),p->GetName().c_str()); m_validationInfo.m_failureBehavior = m_permanentValidationFai...
false
false
false
false
false
0
R_PushDlights (void) { int i; dlight_t *l; old_dlightframecount = r_dlightframecount; new_dlight = false; num_dlight_surfaces = 0; r_dlightframecount = r_framecount + 1; // because the count hasn't // advanced yet for this frame l = r_newrefdef.dlights; for (i=0 ; i<r_newrefdef.num_...
false
false
false
false
false
0
update_wmhints (WnckWindow *window) { Display *display; XWMHints *hints; if (!window->priv->need_update_wmhints) return; display = _wnck_window_get_display (window); _wnck_error_trap_push (display); hints = XGetWMHints (display, window->priv->xwindow); _wnck_error_trap_pop (display); if (hints)...
false
false
false
false
false
0
synaptics_pt_write(struct serio *serio, unsigned char c) { struct psmouse *parent = serio_get_drvdata(serio->parent); char rate_param = SYN_PS_CLIENT_CMD; /* indicates that we want pass-through port */ if (psmouse_sliced_command(parent, c)) return -1; if (ps2_command(&parent->ps2dev, &rate_param, PSMOUSE_CMD_SET...
false
false
false
false
false
0
prepare_show_merge(struct rev_info *revs) { struct commit_list *bases; struct commit *head, *other; unsigned char sha1[20]; const char **prune = NULL; int i, prune_num = 1; /* counting terminating NULL */ if (get_sha1("HEAD", sha1) || !(head = lookup_commit(sha1))) die("--merge without HEAD?"); if (get_sha1("...
false
false
false
false
false
0
cmd_restart(struct sync_reserve_list **reserve_listp, int re_alloc) { struct sync_reserve *res; struct sync_reserve_list *l = *reserve_listp; struct sync_msgid *msg; const char *fname; int hash_size = l->hash_size; struct partition_list *p, *pl = NULL; for (res = l->head; res; res = res->ne...
true
true
false
false
false
1
archive_read_support_format_ar(struct archive *_a) { struct archive_read *a = (struct archive_read *)_a; struct ar *ar; int r; archive_check_magic(_a, ARCHIVE_READ_MAGIC, ARCHIVE_STATE_NEW, "archive_read_support_format_ar"); ar = (struct ar *)malloc(sizeof(*ar)); if (ar == NULL) { archive_set_error(&a->a...
false
false
false
false
false
0
kmc_get_random_mode(int fd) { int rmode; char mode_wbuff[1], out; mode_wbuff[0] = '\x88'; out = kmc_wr(fd, mode_wbuff); if(out == '\x00') rmode = 1; if(out == '\x01') rmode = 2; if(out == '\x02') rmode = 3; return(rmode); }
false
false
false
false
true
1
__normalize(URL req, char *location) { URL ret; char * url; size_t len = strlen(url_get_absolute(req)) + strlen(location) + 32; if (strchr(location, ':') != NULL) { // it's very likely normalized ret = new_url(location); // but we better test it... if (strchr(url_get_hostname(ret), '.') != NU...
false
false
false
false
false
0
phylip_check_sequential_known(ESL_BUFFER *bf, int namewidth) { esl_pos_t anchor = -1; char *p; esl_pos_t n; int32_t nseq, alen; int idx, nres, line, c; int status; anchor = esl_buffer_GetOffset(bf); if (esl_buffer_SetAnchor(bf, anchor) != eslOK) { status = ...
false
false
false
false
false
0
free_qr_and_stm(Quadruple *qr0) { Quadruple *qr, *qrp; Statement *stm; qr = qr0; stm=qr->stm; while (stm && qr) { if (!qr->prev) { for ( ; qr ; qr=qr->next) if (qr->ope==OPE_LABEL) { qr->prev=NULL; break; ...
false
false
false
false
false
0
utflen(FXwchar w){ return (w<0x80 ? 1 : (w<0x800 ? 2 : (w<0x10000 ? 3 : (w<0x200000 ? 4 : (w<0x4000000 ? 5 : 6))))); }
false
false
false
false
false
0
listFree(char** list) { int id = 0;; if (list) { while (list[id]) { memFreeString(__FILE__, __LINE__, list[id]); id++; } memFree(__FILE__, __LINE__, list, sizeof(char*) * (id + 1)); list = NULL; } return lis...
false
false
false
false
false
0
py_field_get_data(struct format_field *f, struct pevent_record *r) { if (!strncmp(f->type, "__data_loc ", 11)) { unsigned long long val; int len, offset; if (pevent_read_number_field(f, r->data, &val)) { PyErr_SetString(PyExc_TypeError, "Field is not a valid number"); return NULL; } /* * The ...
false
false
false
false
false
0
xmlSecKeyUseWithCopy(xmlSecKeyUseWithPtr dst, xmlSecKeyUseWithPtr src) { xmlSecAssert2(dst != NULL, -1); xmlSecAssert2(src != NULL, -1); return(xmlSecKeyUseWithSet(dst, src->application, src->identifier)); }
false
false
false
false
false
0
draw_mesh_grid_region (GSCHEM_TOPLEVEL *w_current, int x, int y, int width, int height) { int x_start, y_start, x_end, y_end; int incr; int screen_incr; incr = w_current->snap_size; screen_incr = SCREENabs (w_current, incr); SCREENtoWORLD (w_current, x - 1, y + height + ...
false
false
false
false
false
0
instrJumpHighLessThan(const TraceInstrJump* ij1, const TraceInstrJump* ij2) { Addr addr1Low, addr1High, addr2Low, addr2High; getInstrJumpAddresses(ij1, addr1Low, addr1High); getInstrJumpAddresses(ij2, addr2Low, addr2High); if (addr1High != addr2High) return (addr1High < addr...
false
false
false
false
false
0
parse_content_type_hdr( struct sip_msg *msg ) { char *end; char *ret; unsigned int mime; content_t * rez; /* is the header already found? */ if ( msg->content_type==0 ) { /* if not, found it */ if ( parse_headers(msg, HDR_CONTENTTYPE_F, 0)==-1) goto error; if ( msg->content_type==0 ) { LM_DBG("missi...
false
false
false
false
false
0
writeScanToFunctor(ArFunctor1<const char *> *functor, const char *endOfLineChars, const char *scanType) { ArMapScanInterface *mapScan = getScan(scanType); if (mapScan != NULL) { mapScan->writeScanToFunctor(functor, endOfLi...
false
false
false
false
false
0
aclDestroyTimeList(acl_time_data * data) { acl_time_data *next = NULL; for (; data; data = next) { next = data->next; memFree(data, MEM_ACL_TIME_DATA); } }
false
false
false
false
false
0
unregister_mem_sect_under_nodes(struct memory_block *mem_blk, unsigned long phys_index) { NODEMASK_ALLOC(nodemask_t, unlinked_nodes, GFP_KERNEL); unsigned long pfn, sect_start_pfn, sect_end_pfn; if (!mem_blk) { NODEMASK_FREE(unlinked_nodes); return -EFAULT; } if (!unlinked_nodes) return -ENOMEM; no...
false
false
false
false
false
0
vou_adjust_input(struct sh_vou_geometry *geo, v4l2_std_id std) { /* The compiler cannot know, that best and idx will indeed be set */ unsigned int best_err = UINT_MAX, best = 0, img_height_max; int i, idx = 0; if (std & V4L2_STD_525_60) img_height_max = 480; else img_height_max = 576; /* Image width must be...
false
false
false
false
false
0
yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep) #else static void yysymprint (yyoutput, yytype, yyvaluep) FILE *yyoutput; int yytype; YYSTYPE *yyvaluep; #endif { /* Pacify ``unused variable'' warnings. */ (void) yyvaluep; if (yytype < YYNTOKENS) YYFPRINTF (yyoutput, "token %s (", yytn...
false
false
false
false
false
0
printTimersToStderr() { fprintf(stderr,"Performance report -=-=-=-=-=-=-=-=-=-=-=-=-=-\n"); fprintf(stderr," FUNCTION TIME IN MICROSECONDS SAMPLES!!\n"); fprintf(stderr," min/avg/max last count \n"); unsigned int i=0; for (i=0; i<TOTAL_TIMERS; i++)...
false
false
false
false
false
0
parse_program_options (int argc, char **argv) { int opt = -1; while ((opt = getopt_long (argc, argv, "hVvdP:S:B:I:w:r:D", gengtype_long_options, NULL)) >= 0) { switch (opt) { case 'h': /* --help */ print_usage (); break; case 'V': /* --version */ print_version (); break; case 'd'...
false
false
false
false
false
0
insertSub(DcmDirectoryRecord *dirRec, unsigned long where, OFBool before) { if (dirRec != NULL) { if (checkHierarchy(DirRecordType, dirRec->DirRecordType).good()) errorFlag = lowerLevelList->insert(dirRec, wh...
false
false
false
false
false
0
checkinput(IPC_Channel* chan, const char * where, int* rdcount, int maxcount) { IPC_Message* rmsg = NULL; int errs = 0; int rc; while (chan->ops->is_message_pending(chan) && errs < 10 && *rdcount < maxcount) { if (chan->ch_status == IPC_DISCONNECT && *rdcount < maxcount){ cl_log(LOG_ERR , "checkinput1[...
false
false
false
false
false
0
dm04_read_ucblocks(struct dvb_frontend *fe, u32 *ucblocks) { struct lme2510_state *st = fe_to_priv(fe); if (st->fe_read_ucblocks && !st->stream_on) return st->fe_read_ucblocks(fe, ucblocks); *ucblocks = 0; return 0; }
false
false
false
false
false
0
print_branch(win, dnum, lower_bound, upper_bound, bymenu, lchoices) winid win; int dnum; int lower_bound; int upper_bound; boolean bymenu; struct lchoice *lchoices; { branch *br; char buf[BUFSZ]; anything any; /* This assumes that end1 is the "parent". */ for (br = bra...
false
false
false
false
false
0
nautilus_window_slot_set_content_view (NautilusWindowSlot *slot, const char *id) { char *uri; g_assert (slot != NULL); g_assert (id != NULL); uri = nautilus_window_slot_get_location_uri (slot); DEBUG ("Change view of window %s to %s", uri, id); g_free (uri); if (nautilus_window_slot_content_view_ma...
false
false
false
false
false
0
gnm_app_clipboard_invalidate_sheet (Sheet *sheet) { /* Clear the cliboard to avoid dangling references to the deleted sheet */ if (sheet == gnm_app_clipboard_sheet_get ()) gnm_app_clipboard_clear (TRUE); else if (app->clipboard_copied_contents) cellregion_invalidate_sheet (app->clipboard_copied_contents, sheet);...
false
false
false
false
false
0
soup_body_input_stream_read_chunked (SoupBodyInputStream *bistream, void *buffer, gsize count, gboolean blocking, GCancellable *cancellable, GError **error) { SoupFilterInputStream *fstream = SOUP_FILTER_INP...
true
true
false
false
false
1
display_loc_list_dwo (struct dwarf_section *section, unsigned char **start_ptr, int debug_info_entry, unsigned long offset, int has_frame_base) { unsigned char *start = *start_ptr; unsigned char *section_end = section->start + s...
false
false
false
false
false
0
proc_tgid_net_readdir(struct file *file, struct dir_context *ctx) { int ret; struct net *net; ret = -EINVAL; net = get_proc_task_net(file_inode(file)); if (net != NULL) { ret = proc_readdir_de(net->proc_net, file, ctx); put_net(net); } return ret; }
false
false
false
false
false
0
xmlRelaxNGFreeStates(xmlRelaxNGValidCtxtPtr ctxt, xmlRelaxNGStatesPtr states) { if (states == NULL) return; if ((ctxt != NULL) && (ctxt->freeStates == NULL)) { ctxt->freeStatesMax = 40; ctxt->freeStatesNr = 0; ctxt->freeStates = (xmlRelaxNGStatesPtr *) ...
false
false
false
false
false
0
main(int argc, char **argv) { PIX *pixs, *pixh, *pixv, *pix, *pixd; char *filein, *fileout; static char mainName[] = "runlengthtest"; if (argc != 3) exit(ERROR_INT(" Syntax: runlengthtest filein fileout", mainName, 1)); filein = argv[1]; fileout = argv[2]; if ((pixs = pixRea...
false
false
false
false
false
0
gda_connection_internal_transaction_rolledback (GdaConnection *cnc, const gchar *trans_name) { GdaTransactionStatus *st = NULL; GdaTransactionStatusEvent *ev = NULL; g_return_if_fail (GDA_IS_CONNECTION (cnc)); gda_connection_lock ((GdaLockable*) cnc); if (cnc->priv->trans_status) st = gda_transaction_status_f...
false
false
false
false
false
0
camlidl_abstract0_ap_abstract0_forget_array( value _v_man, value _v_a, value _v_v1, value _v_v3) { ap_manager_ptr man; /*in*/ ap_abstract0_ptr a; /*in*/ ap_dim_t *v1; /*in*/ int v2; /*in*/ int v3; /*in*/ ap_abstract0_ptr _res; mlsize_t _c1; mlsize_t _c2; value _v3; value _vres; struct camlidl...
false
false
false
false
false
0
dvb_recordings_store_remove (DVBRecordingsStore* self, DVBRecording* rec) { guint32 rec_id = 0U; DVBRecording* _tmp0_ = NULL; guint32 _tmp1_ = 0U; guint32 _tmp2_ = 0U; GeeHashMap* _tmp3_ = NULL; g_return_if_fail (self != NULL); g_return_if_fail (rec != NULL); _tmp0_ = rec; _tmp1_ = dvb_recording_get_Id (_tmp0_...
false
false
false
false
false
0
id_find(struct idlist **idl, long number) { struct idlist *idp; for (idp = *idl; idp; idp = idp->next) if (idp->val.status.num == number) return(idp); return(0); }
false
false
false
false
false
0
scsi_device_from_queue(struct request_queue *q) { struct scsi_device *sdev = NULL; if (q->mq_ops) { if (q->mq_ops == &scsi_mq_ops) sdev = q->queuedata; } else if (q->request_fn == scsi_request_fn) sdev = q->queuedata; if (!sdev || !get_device(&sdev->sdev_gendev)) sdev = NULL; return sdev; }
false
false
false
false
false
0
winsync_plugin_call_begin_update_cb(const Repl_Agmt *ra, const Slapi_DN *ds_subtree, const Slapi_DN *ad_subtree, int is_total) { WINSYNC_PLUGIN_CALL_PLUGINS_COOKIE_BEGIN(WINSYNC_PLUGIN_BEGIN_UPDATE_CB,winsync_plugin_update_cb,thefunc) (*thefunc)(cookie, ds_subtree, ad_sub...
false
false
false
false
false
0
init() { if (root != NULL) return; root = buildTree(); }
false
false
false
false
false
0
remove_invis_left(const CL_GlyphBuffer& gb) { verify(gb); while ( start < end && gb.get_font_for(start)->second.is_glyph(gb.get_glyphs()[start].character) == 0) ++start; }
false
false
false
false
false
0