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
move_to_col(char *p, int l) { int co; p = begin_line(p); co = 0; while (co < l && p < end) { if (*p == '\n') //vda || *p == '\0') break; if (*p == '\t') { co = next_tabstop(co); } else if (*p < ' ' || *p == 127) { co++; // display as ^X, use 2 columns } co++; p++; } return p; }
false
false
false
false
false
0
record_equivalences_from_incoming_edge (basic_block bb) { edge e; basic_block parent; struct edge_info *edge_info; /* If our parent block ended with a control statement, then we may be able to record some equivalences based on which outgoing edge from the parent was followed. */ parent = get_immed...
false
false
false
false
false
0
printDocStart( const char * pszTitle, FLMBOOL bPrintTitle, FLMBOOL bStdHeader, const char * pszBackground) { if (bStdHeader) { stdHdr(); } fnPrintf( m_pHRequest, HTML_DOCTYPE); fnPrintf( m_pHRequest, "<html>\n"); fnPrintf( m_pHRequest, "<head>\n"); printRecordStyle(); printStyle(); fnPrintf( m_pHReq...
false
false
false
false
false
0
nv_save_state_palette(struct drm_device *dev, int head, struct nv04_mode_state *state) { struct nvif_object *device = &nouveau_drm(dev)->device.object; int head_offset = head * NV_PRMDIO_SIZE, i; nvif_wr08(device, NV_PRMDIO_PIXEL_MASK + head_offset, NV_PRMDIO_PIXEL_MASK_MASK); nvif_wr08(device, NV_PRMD...
false
false
false
false
false
0
posix_onewrite_allread_interlaced(int numprocs, int rank, int write_size) { int ret; int i, fill, index; int offset = rank*write_size*sizeof(int); int* writebuf = (int*)malloc(write_size*sizeof(int)); int* readbuf = (int*)malloc (write_size*sizeof(int)); FILE* file = NULL; if(rank==...
false
false
false
false
true
1
ExpandAllTables(ParseState *pstate, int location) { List *target = NIL; ListCell *l; /* Check for SELECT *; */ if (!pstate->p_varnamespace) ereport(ERROR, (errcode(ERRCODE_SYNTAX_ERROR), errmsg("SELECT * with no tables specified is not valid"), parser_errposition(pstate, location))); foreach...
false
false
false
false
false
0
executeQuery(Query& query) { QVector <QPair <FilterSearch, int> > filterSearches; QVector <QPair <Search*, int> > searches; int filterSearchCount = 0; int searchCount = 0; QTime t; t.start(); m_gamesSearched = 0; m_triStateTree = TriStateTree(query); /* Make a list of all searches...
false
false
false
false
false
0
current_txn(DbEnv*env) { if (env_txns_.count(env) <= 0) return NULL; stack<DbTxn*> &pstk = env_txns_[env]; return pstk.size() != 0 ? pstk.top() : NULL; }
false
false
false
false
false
0
ekg2_bless_command(HV *hv, command_t *command) { char *temp; debug_bless("blessing command %s\n", command->name); (void) hv_store(hv, "name", 4, new_pv(command->name), 0); temp = array_join(command->params, " "); (void) hv_store(hv, "param", 5, new_pv(temp), 0); xfree(temp); temp = array_join(command->possibiliti...
false
false
false
false
false
0
makeAdjustTable (void) { e_int32 i; AR_ADJUST_TABLE[0] = (1 << EG_BITS); for (i = 1; i < 128; i++) AR_ADJUST_TABLE[i] = (e_uint16) ((double) (1 << EG_BITS) - 1 - (1 << EG_BITS) * log (i) / log (128)); }
false
false
false
false
false
0
sys_script_filename(node *state,node *self,node *obj,node *block,node *parameters) { node *base_class = get_base_class(state); node *script_filename = node_GetItemByKey(state,"script_filename"); node *value = create_class_instance(base_class); add_garbage(state,value); node *real_value = node_GetItemByK...
false
false
false
false
false
0
b_line_end(buffer, position) Buffer *buffer; long position; { const long bs = buffer -> blocksize; BufferBlock *i; char *c; if (position >= buffer -> size) return buffer -> size; if (!(i = find_block(buffer, position))) return -1; for (c = i -> data + position % bs; c < i -> data + bs; c++) if (*c ...
false
false
false
false
false
0
SetTimeType(SECItem* item, unsigned char tagtype) { switch (tagtype) { case SEC_ASN1_UTC_TIME: item->type = siUTCTime; break; case SEC_ASN1_GENERALIZED_TIME: item->type = siGeneralizedTime; break; default: PORT_Assert(0); ...
false
false
false
false
false
0
ev_getevent(event_t *ev) { if (eventpos == eventhead) { ev->type = EV_NONE; return 0; } *ev = eventqueue[eventpos]; eventpos = (eventpos+1)%MAX_EVENTS; if (ev->type == EV_PRESS) { keystates[ev->code] = 1; nkeysdown++; } if (ev->type == EV_RELEASE) { keystates[ev->code] = 0; nkeysdown--; if (nkey...
false
false
false
false
false
0
menu_undo (void) { if (is_drawing) { cancel_action (); return; } if (pos_undo >= NUM_UNDO - 1 || undo_list[pos_undo + 1] == NULL) bug_in ("menu_undo"); pos_undo++; if (bonds != NULL) free_bond_list (bonds); bonds = copy_bond_list (undo_list[pos_undo]); menu_undo_update (); R...
false
false
false
false
false
0
tick() { QTime newTime = QTime::currentTime(); int change = lastTime.msecsTo(newTime); lastTime = newTime; if (change < 1) change = 1; //Just in case someone changes the clock or something QVector<AnimProvider*> toHandle; for (QMap<AnimProvider*, int>::iterator iter = pending.begin...
false
false
false
false
false
0
ellipsis_list (const DATASET *dset, int v1, int v2, int *err) { int *list = NULL; int i, fd, n = 0; if (dset == NULL || dset->v == 0) { return NULL; } fd = gretl_function_depth(); for (i=v1; i<=v2; i++) { if (fd == 0 || fd == series_get_stack_level(dset, i)) { n++; } } if (n...
false
false
false
false
true
1
ec_append(CORD_ec& result, bool& optimize, bool& whitespace, CORD_pos pos, size_t size) { while(size--) { CORD_ec_append(result, CORD_pos_fetch(pos)); CORD_next(pos); } }
false
false
false
false
false
0
btc_dpm_debugfs_print_current_performance_level(struct radeon_device *rdev, struct seq_file *m) { struct evergreen_power_info *eg_pi = evergreen_get_pi(rdev); struct radeon_ps *rps = &eg_pi->current_rps; struct rv7xx_ps *ps = rv770_get_ps(rps); struct rv7xx_pl *pl; u32 current_index = (RREG32(TARGET_A...
false
false
false
false
false
0
ntfs_attr_reinit_search_ctx(ntfs_attr_search_ctx *ctx) { if (likely(!ctx->base_ntfs_ino)) { /* No attribute list. */ ctx->is_first = true; /* Sanity checks are performed elsewhere. */ ctx->attr = (ATTR_RECORD*)((u8*)ctx->mrec + le16_to_cpu(ctx->mrec->attrs_offset)); /* * This needs resetting due to nt...
false
false
false
false
false
0
stricmp( const char *s1, const char *s2 ) { while ( *s1 ) { if ( *s1 == *s2 || __MYTOLOWER( (int)*s1 ) == __MYTOLOWER( (int)*s2 )) { s1 ++; s2 ++; } else { return __MYTOLOWER( (int)*s1 ) - __MYTOLOWER( (int)*s2 ); } } if ( *s2 ) ...
false
false
false
false
false
0
ei_internal_get_atom(const char** bufp, char* p, erlang_char_encoding* was_encp) { int ix = 0; if (ei_decode_atom_as(*bufp, &ix, p, MAXATOMLEN_UTF8, ERLANG_UTF8, was_encp, NULL) < 0) return -1; *bufp += ix; return 0; }
false
false
false
false
false
0
handle_propfind(struct connection *conn, const char *path, file_stat_t *stp, int exists) { static const char header[] = "HTTP/1.1 207 Multi-Status\r\n" "Connection: close\r\n" "Content-Type: text/xml; charset=utf-8\r\n\r\n" "<?xml version=\"1.0\" encoding=\"utf-8\"?>" "<d:m...
true
true
false
false
false
1
IsWithinLOSInMap(const WorldObject* obj) const { if (!IsInMap(obj)) { return false; } float ox, oy, oz; obj->GetPosition(ox, oy, oz); return(IsWithinLOS(ox, oy, oz)); }
false
false
false
false
false
0
crtc_copy (const GnomeRRCrtc *from) { GnomeRROutput **p_output; GPtrArray *array; GnomeRRCrtc *to = g_slice_new0 (GnomeRRCrtc); to->info = from->info; to->id = from->id; to->current_mode = from->current_mode; to->x = from->x; to->y = from->y; to->current_rotation = from->current_rot...
false
false
false
false
false
0
brasero_image_type_chooser_set_VCD_type (BraseroImageTypeChooser *chooser, gboolean is_SVCD) { GtkTreeIter iter; GtkTreeModel *store; BraseroImageTypeChooserPrivate *priv; priv = BRASERO_IMAGE_TYPE_CHOOSER_PRIVATE (chooser); store = gtk_combo_box_get_model (GTK_COMBO_BOX ...
false
false
false
false
false
0
visit(ir_if *ir) { ralloc_asprintf_append (&buffer, "if ("); ir->condition->accept(this); ralloc_asprintf_append (&buffer, ") {\n"); indentation++; foreach_iter(exec_list_iterator, iter, ir->then_instructions) { ir_instruction *const inst = (ir_instruction *) iter.get(); indent(); in...
false
false
false
false
false
0
bgav_ape_tag_read(bgav_input_context_t * input, int tag_size) { int i; bgav_ape_tag_t *ret; uint32_t flags, item_value_size; uint8_t * buffer, *ptr; ret = calloc(1, sizeof(*ret)); buffer = malloc(tag_size); if(bgav_input_read_data(input, buffer, tag_size) < tag_size) return NULL; /* Go to ...
false
false
false
false
false
0
vidioc_g_audio(struct file *file, void *fh, struct v4l2_audio *vin) { struct vivid_dev *dev = video_drvdata(file); if (!vivid_is_sdtv_cap(dev)) return -EINVAL; *vin = vivid_audio_inputs[dev->tv_audio_input]; return 0; }
false
false
false
false
false
0
gf_isom_is_track_fragmented(GF_ISOFile *movie, u32 TrackID) { if (!movie || !movie->moov || !movie->moov->mvex) return 0; return (GetTrex(movie->moov, TrackID) != NULL) ? 1 : 0; }
false
false
false
false
false
0
unref_blacklist(struct Blacklist *blptr) { blptr->refcount--; if (blptr->status & CONF_ILLEGAL && blptr->refcount <= 0) { rb_dlinkFindDestroy(blptr, &blacklist_list); rb_free(blptr); } }
false
false
false
false
false
0
tm_source_file_buffer_parse(TMSourceFile *source_file, guchar* text_buf, gint buf_size) { const char *file_name; gboolean status = TRUE; if ((NULL == source_file) || (NULL == source_file->work_object.file_name)) { g_warning("Attempt to parse NULL file"); return FALSE; } if ((NULL == text_buf) || (0 == buf_s...
false
false
false
false
false
0
main_window_file_get_toolbar_open_button (MainWindowFile* self) { GtkToolItem* result = NULL; GtkRecentManager* recent_manager = NULL; GtkRecentManager* _tmp0_ = NULL; GtkRecentManager* _tmp1_ = NULL; GtkWidget* recent_menu = NULL; GtkRecentChooserMenu* _tmp2_ = NULL; GtkMenuToolButton* open_button = NULL; GtkM...
false
false
false
false
false
0
real_sqrt (REAL_VALUE_TYPE *r, enum machine_mode mode, const REAL_VALUE_TYPE *x) { static REAL_VALUE_TYPE halfthree; static bool init = false; REAL_VALUE_TYPE h, t, i; int iter, exp; /* sqrt(-0.0) is -0.0. */ if (real_isnegzero (x)) { *r = *x; return false; } /* Negative argumen...
false
false
false
false
false
0
InitializeMatrix(unsigned int matrixIndex) { // allocate if necessary if( m_Matrices == ITK_NULLPTR ) { m_Matrices = new MatrixHolder(m_NumberOfMatrices); if( m_Matrices == ITK_NULLPTR ) { itkGenericExceptionMacro(<< "LinearSystemWrapperVNL::InitializeMatrix(): m_Matrices allocation failed....
false
false
false
false
false
0
parse_netid_str (const char *s, uid_t *uidp, gid_t *gidp, int *gidlenp, gid_t *gidlist) { char *p, *ep; int gidlen; if (!s || !isdigit (*s)) { syslog (LOG_ERR, "netname2user: expecting uid '%s'", s); return NSS_STATUS_NOTFOUND; /* XXX need a better error */ } /* Fetch the uid */ *uidp...
false
false
false
false
false
0
new_type(char* name) { type_t* tipo = (type_t*) malloc (sizeof(type_t)); tipo->name = name; if (strcmp(name, "int") == 0){ tipo->node_type = type_int; } else if (strcmp(name, "double") == 0){ tipo->node_type = type_double; } else if (strcmp(name, "char") == 0) { tipo->node...
false
false
false
false
false
0
isl_mat_free(__isl_take isl_mat *mat) { if (!mat) return NULL; if (--mat->ref > 0) return NULL; if (!ISL_F_ISSET(mat, ISL_MAT_BORROWED)) isl_blk_free(mat->ctx, mat->block); isl_ctx_deref(mat->ctx); free(mat->row); free(mat); return NULL; }
false
false
false
false
false
0
Java_ncsa_hdf_hdf5lib_H5_H5Gget_1objname_1by_1idx (JNIEnv *env, jclass clss, jint group_id, jlong idx, jobjectArray name, jlong buf_size) { char *aName; jstring str; hssize_t size; long bs; bs = (long)buf_size; if (bs <= 0) { h5badArgument( env, "H5Gget_objname_by_idx: buf_...
false
false
false
false
false
0
nice_address_set_from_string (NiceAddress *addr, const gchar *str) { union { struct in_addr ipv4; struct in6_addr ipv6; } a; if (inet_pton (AF_INET, str, &a.ipv4) > 0) nice_address_set_ipv4 (addr, ntohl (a.ipv4.s_addr)); else if (inet_pton (AF_INET6, str, &a.ipv6) > 0) nice_address_set_i...
false
false
false
false
false
0
stb6100_write_reg(struct stb6100_state *state, u8 reg, u8 data) { if (unlikely(reg >= STB6100_NUMREGS)) { dprintk(verbose, FE_ERROR, 1, "Invalid register offset 0x%x", reg); return -EREMOTEIO; } data = (data & stb6100_template[reg].mask) | stb6100_template[reg].set; return stb6100_write_reg_range(state, &data, ...
false
false
false
false
false
0
gimp_ruler_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec) { GimpRuler *ruler = GIMP_RULER (object); GimpRulerPrivate *priv = GIMP_RULER_GET_PRIVATE (ruler); switch (prop_id) ...
false
false
false
false
false
0
mb_find_buddy(struct ext4_buddy *e4b, int order, int *max) { char *bb; BUG_ON(e4b->bd_bitmap == e4b->bd_buddy); BUG_ON(max == NULL); if (order > e4b->bd_blkbits + 1) { *max = 0; return NULL; } /* at order 0 we see each particular block */ if (order == 0) { *max = 1 << (e4b->bd_blkbits + 3); return e4b...
false
false
false
false
false
0
setup_pre_exchange() { // insure atoms are in current box & update box via shrink-wrap // no exchange() since doesn't matter if atoms are assigned to correct procs if (domain->triclinic) domain->x2lamda(atom->nlocal); domain->pbc(); domain->reset_box(); if (domain->triclinic) domain->lamda2x(atom->nlocal);...
false
false
false
false
false
0
fapi_copy_mono(gx_device *dev1, gs_fapi_raster *rast, int dx, int dy) { int line_step = bitmap_raster(rast->width), code; if (rast->line_step >= line_step) { return dev_proc(dev1, copy_mono) (dev1, rast->p, 0, rast->line_step, 0, dx, dy, rast->width, ...
false
false
false
false
false
0
unicode_center(PyUnicodeObject *self, PyObject *args) { Py_ssize_t marg, left; Py_ssize_t width; Py_UNICODE fillchar = ' '; if (!PyArg_ParseTuple(args, "n|O&:center", &width, convert_uc, &fillchar)) return NULL; if (self->length >= width && PyUnicode_CheckExact(self)) { Py_INCREF(s...
false
false
false
false
false
0
pci_pm_suspend(struct device *dev) { struct pci_dev *pci_dev = to_pci_dev(dev); const struct dev_pm_ops *pm = dev->driver ? dev->driver->pm : NULL; if (pci_has_legacy_pm_support(pci_dev)) return pci_legacy_suspend(dev, PMSG_SUSPEND); if (!pm) { pci_pm_default_suspend(pci_dev); goto Fixup; } /* * PCI de...
false
false
false
false
false
0
getarg(option, argc, argv) /* look for argument 'option' in command line */ char *option; char *argv[]; int argc; { int j, place; place = -1; for (j=0; j<argc; j++) { if (strcmp(option, argv[j]) == 0) { place = j + 1; }; }; return (place); }
false
false
false
false
false
0
get_cmap (GdkPixmap *pixmap) { GdkColormap *cmap; ENTER; cmap = gdk_drawable_get_colormap (pixmap); if (cmap) g_object_ref (G_OBJECT (cmap)); if (cmap == NULL) { if (gdk_drawable_get_depth (pixmap) == 1) { /* try null cmap */ cmap = NULL; } else ...
false
false
false
false
false
0
is_monomorphic_array (MonoClass *klass) { MonoClass *element_class; if (klass->rank != 1) return FALSE; element_class = klass->element_class; return (element_class->flags & TYPE_ATTRIBUTE_SEALED) || element_class->valuetype; }
false
false
false
false
false
0
test_remove_level2_3internal_merge(hid_t fapl, const H5B2_create_t *cparam, const bt2_test_param_t *tparam) { hid_t file = -1; /* File ID */ H5F_t *f = NULL; /* Internal file object pointer */ hid_t dxpl = H5P_DATASET_XFER_DEFAULT; /* DXPL to use */ H5B2_t ...
false
false
false
false
false
0
execQuery(const QString &untrimmedTerm, const QString &runnerName) { QString term = untrimmedTerm.trimmed(); if (term.isEmpty()) { reset(); return false; } if (d->runners.isEmpty()) { d->loadRunners(); } if (d->context.query() == term) { // we already are searc...
false
false
false
false
false
0
qgroup_update_refcnt(struct btrfs_fs_info *fs_info, struct ulist *roots, struct ulist *tmp, struct ulist *qgroups, u64 seq, int update_old) { struct ulist_node *unode; struct ulist_iterator uiter; struct ulist_node *tmp_unode; struct ulist_iterator tmp_uiter; struct btrfs_qgroup *qg; int ret = 0; if (!r...
false
false
false
false
false
0
test_revwalk_mergebase__single2(void) { git_oid result, one, two, expected; git_oid_fromstr(&one, "763d71aadf09a7951596c9746c024e7eece7c7af"); git_oid_fromstr(&two, "a65fedf39aefe402d3bb6e24df4d4f5fe4547750"); git_oid_fromstr(&expected, "c47800c7266a2be04c571c04d5a6614691ea99bd"); cl_git_pass(git_merge_base(&res...
false
false
false
false
false
0
alc298_fixup_speaker_volume(struct hda_codec *codec, const struct hda_fixup *fix, int action) { if (action == HDA_FIXUP_ACT_PRE_PROBE) { /* The speaker is routed to the Node 0x06 by a mistake, as a result we can't adjust the speaker's volume since this node does not has Amp-out capability. we change t...
false
false
false
false
false
0
dib8000_set_bandwidth(struct dvb_frontend *fe, u32 bw) { struct dib8000_state *state = fe->demodulator_priv; u32 timf; if (bw == 0) bw = 6000; if (state->timf == 0) { dprintk("using default timf"); timf = state->timf_default; } else { dprintk("using updated timf"); timf = state->timf; } dib8000_writ...
false
false
false
false
false
0
client_comm_bind(int sock, const char *local_host) { static const struct hostent *hp = NULL; static struct sockaddr_in from_addr; /* Set up the source socket address from which to send. */ if (hp == NULL) { from_addr.sin_family = AF_INET; if ((hp = gethostbyname(local_host)) == 0) { return (-1)...
false
false
false
false
false
0
DSDPSchurMatOpsInitialize(struct DSDPSchurMat_Ops* dops){ DSDPFunctionBegin; if (dops==NULL) return 0; dops->matzero=0; dops->matrownonzeros=0; dops->mataddrow=0; dops->mataddelement=0; dops->matadddiagonal=0; dops->matshiftdiagonal=0; dops->matassemble=0; dops->matscaledmultiply=0; dops->matmult...
false
false
false
false
false
0
monster_move_randomly(object *op) { int i; sstring talked; char value[2]; /* timeout before moving */ if (QUERY_FLAG(op, FLAG_UNAGGRESSIVE)) { talked = object_get_value(op, "talked_to"); if (talked && strlen(talked) > 0) { i = atoi(talked); i--; ...
false
false
false
false
false
0
operator=(XMLNode n) { id = (std::string)n["id"]; if (n["creamURL"]) { creamURL = URL((std::string)n["creamURL"]); } for (XMLNode property = n["property"]; property; ++property) { if ((std::string)property["name"] == "CREAMInputSandboxURI") { ISB = (std::string)property["value"]; ...
false
false
false
false
false
0
handle_burstlogin(user_t *u, char *login, time_t ts) { mynick_t *mn; myuser_t *mu; mowgli_node_t *n; if (login != NULL) /* don't allow alias nicks here -- jilles */ mu = myuser_find(login); else { mn = mynick_find(u->nick); mu = mn != NULL ? mn->owner : NULL; login = mu != NULL ? entity(mu)->name : u->...
false
false
false
false
false
0
solo_enum_ext_input(struct solo_dev *solo_dev, struct v4l2_input *input) { static const char * const dispnames_1[] = { "4UP" }; static const char * const dispnames_2[] = { "4UP-1", "4UP-2" }; static const char * const dispnames_5[] = { "4UP-1", "4UP-2", "4UP-3", "4UP-4", "16UP" }; const char * const *d...
false
false
false
false
false
0
gf_codec_set_capability(GF_Codec *codec, GF_CodecCapability cap) { if (!codec->decio) return GF_OK; return codec->decio->SetCapabilities(codec->decio, cap); }
false
false
false
false
false
0
dump_pools_to_trash() { struct pool_head *entry; unsigned long allocated, used; int nbpools; allocated = used = nbpools = 0; chunk_printf(&trash, "Dumping pools usage. Use SIGQUIT to flush them.\n"); list_for_each_entry(entry, &pools, list) { chunk_appendf(&trash, " - Pool %s (%d bytes) : %d allocated (%u byt...
false
false
false
false
false
0
m_tra2(matrix, m_result) const hmat2_t *matrix; hmat2_t *m_result; { m_result = gm_ALLOC(hmat2_t, m_result, "m_tra2()"); if(m_result != matrix) { int i,j; for(i=0; i<3; i++) for(j=0; j<3; j++) m_elem(*m_result, i, j) = m_elem(*matrix, j, i); } else { double buf[3]; ...
false
false
false
false
true
1
KillBlitToHigh(void) { if(palettetranslate) { free(palettetranslate); palettetranslate=NULL; } if(specbuf8bpp) { free(specbuf8bpp); specbuf8bpp = NULL; } if(specbuf32bpp) { free(specbuf32bpp); specbuf32bpp = NULL; } if(specbuf) { if(silt == 3) hq3x_Kill(); else h...
false
false
false
false
false
0
pit_task_list(POptions po, PProject pp) { if (!tasks) pit_db_load(); if (tasks->number_of_records > 0) { PFormat pf = pit_format_initialize(FORMAT_TASK, (pp ? 4 : 0), tasks->number_of_records); if (!pp) pp = (PProject)pit_table_current(projects); for_each_task(pt) { if ((pp...
false
false
false
false
false
0
menu(char *head, char *str_menu, char *label, char *opt, char dfl) { if (!head) head=""; if (!str_menu) str_menu = ""; set_tty_color_bg(COLOR_BLACK, COLOR_WHITE); printf("--- %s --- rcvpkt %u, free/alloc %d/%d ---", head, pkts_received, packet_count(), packets_allocated); print_rst_daemon(); print...
false
false
false
false
false
0
process_sqliterc( struct callback_data *p, /* Configuration data */ const char *sqliterc_override /* Name of config file. NULL to use default */ ){ char *home_dir = NULL; const char *sqliterc = sqliterc_override; char *zBuf = 0; FILE *in = NULL; int rc = 0; if (sqliterc == NULL) { home_dir...
false
false
true
false
true
1
__ecereMethod___ecereNameSpace__ecere__gfx3D__Object_SetTransformDirty(struct __ecereNameSpace__ecere__com__Instance * this) { struct __ecereNameSpace__ecere__gfx3D__Object * __ecerePointer___ecereNameSpace__ecere__gfx3D__Object = (struct __ecereNameSpace__ecere__gfx3D__Object *)(this ? (((char *)this) + __ecereClass__...
false
false
false
true
false
1
lookup_loc (s, identtab_loc) char *s; struct ident_tab_header *identtab_loc; { struct tab *ps; ps = identtab_loc->hastab_loc + hash_code (s, SIZE_HAS_LOC); if (0 == *(int *) ps) return NULL; while (ps->name != s && NULL != ps->next) ps = ps->next; if (NULL == ps->next && ps->name !...
false
false
false
false
false
0
tor_check_libevent_version(const char *m, int server, const char **badness_out) { int buggy = 0, iffy = 0, slow = 0, thread_unsafe = 0; le_version_t version; const char *v = NULL; const char *badness = NULL; const char *sad_os = ""; version = tor_get_libevent_version(&v); /* I...
false
false
false
false
false
0
unlinkTransform( bool notifyMaster ) { if( mSharedTransformEntity ) { //Tell our master we're no longer his slave if( notifyMaster ) mSharedTransformEntity->notifyUnlink( this ); mBatchOwner->_markTransformSharingDirty(); mSkeletonInst...
false
false
false
false
false
0
attempt_move_forward (BonoboDockBand *band, GList *child, guint requirement) { GList *lp; guint effective_amount; effective_amount = 0; for (lp = next_if_floating (band, child); lp != NULL && requirement > 0; lp = next_not_floating (band, lp)) { BonoboDockBandChild *c; c = lp->da...
false
false
false
false
false
0
tracker_sparql_expression_get_error (TrackerSparqlExpression* self, const gchar* msg) { GError* result = NULL; TrackerSparqlQuery* _tmp0_; const gchar* _tmp1_; GError* _tmp2_ = NULL; #line 59 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-expression.vala" g_return_val_if_fail (self != NULL, NULL);...
false
false
false
false
false
0
error_proc(HIME_client_handle *handle, char *msg) { if (!handle->fd) return; perror(msg); close(handle->fd); handle->fd = 0; usleep(100000); }
false
false
false
false
true
1
do_sync_tests_for_session (SoupSession *session, const char *uri_string) { SoupRequester *requester; SoupRequest *request; SoupURI *uri; requester = SOUP_REQUESTER (soup_session_get_feature (session, SOUP_TYPE_REQUESTER)); uri = soup_uri_new (uri_string); debug_printf (1, " basic test\n"); if (requester) ...
false
false
false
false
false
0
newsnntp_xover_single(newsnntp * f, uint32_t article, struct newsnntp_xover_resp_item ** result) { char command[NNTP_STRING_SIZE]; int r; clist * list; clistiter * cur; struct newsnntp_xover_resp_item * item; snprintf(command, NNTP_STRING_SIZE, "XOVER %i\r\n", article); r = send_command(f, command)...
true
true
false
false
false
1
ssl2_TriggerNextMessage(sslSocket *ss) { SECStatus rv; PORT_Assert( ss->opt.noLocks || ssl_Have1stHandshakeLock(ss) ); if ((ss->sec.ci.requiredElements & CIS_HAVE_CERTIFICATE) && !(ss->sec.ci.sentElements & CIS_HAVE_CERTIFICATE)) { ss->sec.ci.sentElements |= CIS_HAVE_CERTIFICATE; rv = ssl2_SendC...
false
false
false
false
false
0
GetAsUnsignedInteger(StringRef Str, unsigned Radix, unsigned long long &Result) { // Autosense radix if not specified. if (Radix == 0) Radix = GetAutoSenseRadix(Str); // Empty strings (after the radix autosense) are invalid. if (Str.empty()) return true; // Parse all...
false
false
false
false
false
0
getRandom(UINT64* val) { ASSERT(val!=NULL,"VAL should be not NULL"); if(RAND_bytes((UINT8*)val,sizeof(UINT64))!=1&& RAND_pseudo_bytes((UINT8*)val,sizeof(UINT64))<0) return E_UNKNOWN; return E_SUCCESS; }
false
false
false
false
false
0
Scm_RegMatchEnd(ScmRegMatch *rm, ScmObj obj) { struct ScmRegMatchSub *sub = regmatch_ref(rm, obj); if (sub == NULL) return SCM_FALSE; if (sub->after < 0) regmatch_count_after(rm, sub); return Scm_MakeInteger(rm->inputLen - sub->after); }
false
false
false
false
false
0
modify_access_pattern_one_dim_lower(Block *bpt, int dim, int entry) { int ret = 0, temp = 0, temp2 = 0; temp = modify_access_pattern_one_dim_lower_by_def_use_var_list(bpt->def_var_list, dim, ...
false
false
false
false
false
0
block_has_acc_block_in_inner(Block *block, int acc_id) { Block *bpt; if (block->kind != SB && block->inner == NULL) { return FALSE; } else if (block->kind == SB) { Module_table *mpt = search_module_for_sb(block); return block_has_acc_block_in_inner(mpt->block_head, acc_id); } el...
false
false
false
false
false
0
hfi1_lkey_ok(struct hfi1_lkey_table *rkt, struct hfi1_pd *pd, struct hfi1_sge *isge, struct ib_sge *sge, int acc) { struct hfi1_mregion *mr; unsigned n, m; size_t off; /* * We use LKEY == zero for kernel virtual addresses * (see hfi1_get_dma_mr and dma.c). */ rcu_read_lock(); if (sge->lkey == 0) { str...
false
false
false
false
false
0
gst_audio_invert_setup (GstAudioFilter * base, const GstAudioInfo * info) { GstAudioInvert *filter = GST_AUDIO_INVERT (base); gboolean ret = TRUE; switch (GST_AUDIO_INFO_FORMAT (info)) { case GST_AUDIO_FORMAT_S16: filter->process = (GstAudioInvertProcessFunc) gst_audio_invert_transform_int; ...
false
false
false
false
false
0
bstr_open(const void *arena, size_t len, uint32 flags) { bstr_t *bs; g_assert(arena); g_assert(0 == (flags & BSTR_F_PRIVATE)); WALLOC0(bs); bs->magic = BSTR_MAGIC; reset_stream(bs, arena, len, flags); if (len == 0) error_eos(bs, 0, "bstr_open"); return bs; }
false
false
false
false
false
0
InitPixMap(int width, int height, Surface *WXUNUSED(surface_), WindowID /*winid*/) #endif /* C::B end */ { Release(); hDC = new wxMemoryDC(); hDCOwned = true; if (width < 1) width = 1; if (height < 1) height = 1; /* C::B begin */ #if wxCHECK_VERSION(2,9,5) bitmap = new wxBitmap(); bitmap->Cr...
false
false
false
false
false
0
extract_ip_field(u_int32_t ip, unsigned long depth) { u_int8_t ip_node[4]; memcpy(ip_node, &ip, sizeof(ip)); if (depth > 3) return 0; return ip_node[depth]; }
false
true
false
false
false
1
gupnp_didl_lite_object_get_dlna_managed (GUPnPDIDLLiteObject *object) { const char *str; GUPnPOCMFlags dlna_managed; g_return_val_if_fail (object != NULL, GUPNP_OCM_FLAGS_NONE); g_return_val_if_fail (GUPNP_IS_DIDL_LITE_OBJECT (object), GUPNP_OCM_FLAGS_NONE)...
false
false
false
false
false
0
coproc_secondary_reload_class (enum machine_mode mode, rtx x, bool wb) { if (mode == HFmode) { if (!TARGET_NEON_FP16) return GENERAL_REGS; if (s_register_operand (x, mode) || neon_vector_mem_operand (x, 2)) return NO_REGS; return GENERAL_REGS; } /* The neon move patterns handle all legi...
false
false
false
false
false
0
snes_draw_tile_4x2( UINT8 screen, UINT8 layer, UINT16 tileaddr, INT16 x, UINT8 priority, UINT8 flip, UINT16 pal ) { if( flip ) { snes_draw_tile_4( screen, layer, tileaddr + 32, x, priority, flip, pal ); snes_draw_tile_4( screen, layer, tileaddr, x + 8, priority, flip, pal ); } else { snes_draw_tile_...
false
false
false
false
false
0
swap_header(hashp) HTAB *hashp; { HASHHDR *hdrp; int i; hdrp = &hashp->hdr; M_32_SWAP(hdrp->magic); M_32_SWAP(hdrp->version); M_32_SWAP(hdrp->lorder); M_32_SWAP(hdrp->bsize); M_32_SWAP(hdrp->bshift); M_32_SWAP(hdrp->dsize); M_32_SWAP(hdrp->ssize); M_32_SWAP(hdrp->sshift); M_32_SWAP(hdrp->ovfl_point); M_...
false
false
false
false
false
0
parseCSV(TupleValue** value, char start, char end) { std::auto_ptr<TupleValue> tuple(new TupleValue); if (!parseCSV(*tuple, start, end)) return false; *value = tuple.get(); tuple.release(); return true; }
false
false
false
false
false
0
Install(PkgIterator Pkg,string File) { if (File.empty() == true || Pkg.end() == true) return _error->Error("Internal Error, No file name for %s",Pkg.FullName().c_str()); // If the filename string begins with DPkg::Chroot-Directory, return the // substr that is within the chroot so dpkg can access it. ...
false
false
false
false
false
0
assertion_lookup (name, len, hash) U_CHAR *name; int len; int hash; { register ASSERTION_HASHNODE *bucket; bucket = assertion_hashtab[hash]; while (bucket) { if (bucket->length == len && bcmp (bucket->name, name, len) == 0) return bucket; bucket = bucket->next; } return NULL; }
false
false
false
false
false
0
normalize_request(char *lines) { char *c, *c1, *end; ssize_t len; end = &lines[strstr(lines, "\r\n\r\n") - lines]; // Convert \r\n to \0\n for (c = lines; c < end + 3; c++) { if (*c == '\r' && *(c + 1) == '\n') { *c = '\0'; } } // Concat multi-line headers ...
false
false
false
false
false
0
translate_incoming_seek (GnlObject * object, GstEvent * event) { GstEvent *event2; GstFormat format; gdouble rate; GstSeekFlags flags; GstSeekType curtype, stoptype; GstSeekType ncurtype; gint64 cur; guint64 ncur; gint64 stop; guint64 nstop; guint32 seqnum = GST_EVENT_SEQNUM (event); gst_event_...
false
false
false
false
false
0
ExtractConnectedComponent( inp_ATOM *at, int num_at, int component_number, inp_ATOM *component_at ) { int i, j, num_component_at; AT_NUMB *number; if ( NULL == (number = (AT_NUMB*)inchi_calloc(num_at, sizeof(AT_NUMB)))){ return CT_OUT_OF_RAM; /* out of memory */ /* <BRKPT> */ } /* copy a...
false
false
false
false
false
0
qof_instance_mark_clean (QofInstance *inst) { if (!inst) return; GET_PRIVATE(inst)->dirty = FALSE; }
false
false
false
false
false
0