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
vrf_dellink(struct net_device *dev, struct list_head *head) { struct net_vrf *vrf = netdev_priv(dev); struct slave_queue *queue = &vrf->queue; struct list_head *all_slaves = &queue->all_slaves; struct slave *slave, *next; list_for_each_entry_safe(slave, next, all_slaves, list) vrf_del_slave(dev, slave->dev); ...
false
false
false
false
false
0
nautilus_window_disable_chrome_mapping (GValue *value, GVariant *variant, gpointer user_data) { NautilusWindow *window = user_data; g_value_set_boolean (value, g_variant_get_boolean (variant) && !window->details->disable_chrome); return TRUE; }
false
false
false
false
false
0
previousSibling( void*& filterException ) { NodePtr n = getPreviousSibling( m_currentNode, filterException ); if( n ) m_currentNode = n; return n.get(); }
false
false
false
false
false
0
f300_send_byte(struct cx23885_dev *dev, u8 dta) { u8 i; for (i = 0; i < 8; i++) { f300_set_line(dev, F300_CLK, 0); udelay(30); f300_set_line(dev, F300_DATA, (dta & 0x80) >> 7);/* msb first */ udelay(30); dta <<= 1; f300_set_line(dev, F300_CLK, 1); udelay(30); } }
false
false
false
false
false
0
setState(int leaf, State state) { if(leaf < m_leafCount) { m_leafs[leaf]->m_state = state; if(m_leafs[leaf]->m_parent) { m_state = update(m_leafs[leaf]->m_parent); } else { m_state = m_leafs[leaf]->m_state; } } return m_sta...
false
false
false
false
false
0
PlayMatch(BYTE a, BYTE b) { if(controllo[a]>=0 || controllo[b]>=0) return StartMatch(a, b); else return ComputerMatch(a, b); final=FALSE; }
false
false
false
false
false
0
setShapeGesture(const KShapeGesture &gst) { if (!m_oldShapeGesture) { m_oldShapeGesture = new KShapeGesture(gst); } m_action->setShapeGesture(gst); updateModified(); }
false
false
false
false
false
0
item_factory_new (GtkType container_type, const char *path, GtkAccelGroup *accel_group, const char *strip_prefix) { GtkItemFactory *result = gtk_item_factory_new (container_type, path, accel_group); gchar *strip_prefix_dup = g_strdup (strip_prefix); gtk_item_factory_set_translate_func (result, gftp_item_fa...
false
false
false
false
false
0
find_file(unsigned char *buf, unsigned len, unsigned *gfx_file_start, unsigned *file_len, unsigned *code_size) { unsigned i, fname_len, code_start = 0; *gfx_file_start = 0; *code_size = 0; if((code_start = magic_ok(buf, code_size))) return code_start; for(i = 0; i < len;) { if((len - i) >= 0x1a && (buf...
false
false
false
false
false
0
e_container_move_resize(E_Container *con, int x, int y, int w, int h) { E_OBJECT_CHECK(con); E_OBJECT_TYPE_CHECK(con, E_CONTAINER_TYPE); con->x = x; con->y = y; con->w = w; con->h = h; if (con->win != con->manager->win) ecore_x_window_move_resize(con->win, con->x, con->y, con->w, con->h); e...
false
false
false
false
false
0
penChanged(const QPen &/*pen*/) { pathItem->setPen(route->pen()); updateItem(); }
false
false
false
false
false
0
begin_handling(void) { struct sockaddr_storage sfrom; socklen_t sfromsiz = sizeof(sfrom); int r; char buf[MAXLOGNAME + MAXDOMNAME + MAX_MAILBOX_BUFFER]; char username[MAXLOGNAME + MAXDOMNAME + 1]; char mbox[MAX_MAILBOX_BUFFER]; char *q; int ...
true
true
false
false
false
1
gdata_media_content_get_property (GObject *object, guint property_id, GValue *value, GParamSpec *pspec) { GDataMediaContentPrivate *priv = GDATA_MEDIA_CONTENT (object)->priv; switch (property_id) { case PROP_URI: g_value_set_string (value, priv->uri); break; case PROP_FILESIZE: g_value_set_ulong (value,...
false
false
false
false
false
0
printValue() { int i; printf("Dimensions (%d) Dim Sizes (", this->dimensions); for (i=0 ; i<this->dimensions ; i++) printf("%d ",this->dim_sizes[i]); printf(")\n Value : '%s'\n",this->getValueString()); }
false
false
false
false
false
0
makeStatusPixmaps (const int width) { qreal d, p; QImage status (width, width, QImage::Format_ARGB32_Premultiplied); QPainter s (&status); sWidth = width; d = width/4.0; p = width/2.0; status.fill (0); svg.render (&s, "player_1"); colorImage (status, color1, width); svg.render (&s, "light...
false
false
false
false
false
0
checkout_count_callback( git_checkout_notify_t why, const char *path, const git_diff_file *baseline, const git_diff_file *target, const git_diff_file *workdir, void *payload) { checkout_counts *ct = payload; GIT_UNUSED(baseline); GIT_UNUSED(target); GIT_UNUSED(workdir); if (why & GIT_CHECKOUT_NOTIFY_CONFLICT...
false
false
false
true
false
1
ReadNodeProperty(xmlNode* node, const char* property) { if (node != NULL && property != NULL) { xmlChar* data = xmlGetProp(node, xmlT(property)); if (data != NULL) { // Process the string for special characters fm::string ret = XmlToString((const char*) data); xmlFree(data); retu...
false
false
false
false
false
0
increment() { this->ob_ = boost::python::handle<>( boost::python::allow_null(PyIter_Next(this->it_.ptr()))); if (PyErr_Occurred()) throw boost::python::error_already_set(); }
false
false
false
false
false
0
cq_clock(cqueue_t *cq, int elapsed) { int bucket; int last_bucket, old_last_bucket; struct chash *ch, *old_current; cevent_t *ev; cq_time_t now; int processed = 0; cqueue_check(cq); g_assert(elapsed >= 0); g_assert(mutex_is_owned(&cq->cq_lock)); /* * Recursive calls are possible: in the middle of an event...
false
false
false
false
false
0
mca_base_pvar_find (const char *project, const char *framework, const char *component, const char *name) { char *full_name; int ret, index; ret = mca_base_var_generate_full_name4 (NULL, framework, component, name, &full_name); if (OPAL_SUCCESS != ret) { return OPAL_ERROR; } ret = mca_b...
false
false
false
false
false
0
xmlSchemaPValAttrFormDefault(const xmlChar *value, int *flags, int flagQualified) { if (xmlStrEqual(value, BAD_CAST "qualified")) { if ((*flags & flagQualified) == 0) *flags |= flagQualified; } else if (!xmlStrEqual(value, BAD_CAST "...
false
false
false
false
false
0
updatePivot(ClpSimplex * model, double oldInValue, double ) { if (rhsOffset_) { // update effective rhs int sequenceIn = model->sequenceIn(); int sequenceOut = model->sequenceOut(); double * solution = model->solutionRegion(); int numberColumns = model->numberColum...
false
false
false
false
false
0
radio_release(struct file *file) { struct bttv_fh *fh = file->private_data; struct bttv *btv = fh->btv; struct saa6588_command cmd; file->private_data = NULL; v4l2_fh_del(&fh->fh); v4l2_fh_exit(&fh->fh); kfree(fh); btv->radio_user--; bttv_call_all(btv, core, ioctl, SAA6588_CMD_CLOSE, &cmd); if (btv->radio...
false
false
false
false
false
0
readLayout( Playlist::LayoutItemConfig config ) { DEBUG_BLOCK int rowCount = config.rows(); disconnect ( m_showCoverCheckBox, SIGNAL(stateChanged(int)), this, SIGNAL(changed()) ); m_showCoverCheckBox->setChecked( config.showCover() ); connect ( m_showCoverCheckBox, SIGNAL(stateChanged(int)), this, ...
false
false
false
false
false
0
AddEvent(EventProcessor* events, int funcRef, uint32 delay, uint32 calls, Object* obj) { if (!events || funcRef <= 0) // If funcRef <= 0, function reference failed return 0; // on fail always return 0. funcRef can be negative. events->AddEvent(new LuaEvent(E, events, funcRef, delay, calls, obj), events-...
false
false
false
false
false
0
_updateRenderQueue(RenderQueue* queue) { // If we're driving this from our own data, update geometry if need to. if (!mExternalData && (mAutoUpdate || mBillboardDataChanged || !mBuffersCreated)) { if (mSortingEnabled) { _sortBillboards(mCurrentCamera);...
false
false
false
false
false
0
fftnul(fitsfile *fptr, /* I - FITS file pointer */ int colnum, /* I - column number to apply nulvalue to */ LONGLONG nulvalue, /* I - null pixel value: value of TNULLn */ int *status) /* IO - error status */ /* Define the ...
false
false
false
false
false
0
radeon_dp_needs_link_train(struct radeon_connector *radeon_connector) { u8 link_status[DP_LINK_STATUS_SIZE]; struct radeon_connector_atom_dig *dig = radeon_connector->con_priv; if (drm_dp_dpcd_read_link_status(&radeon_connector->ddc_bus->aux, link_status) <= 0) return false; if (drm_dp_channel_eq_ok(link_st...
false
false
false
false
false
0
async_connected (GObject *client, GAsyncResult *result, gpointer data) { SoupSocketAsyncConnectData *sacd = data; SoupSocketPrivate *priv = SOUP_SOCKET_GET_PRIVATE (sacd->sock); GError *error = NULL; GSocketConnection *conn; guint status; if (priv->async_context && !priv->use_thread_context) g_main_context_pop...
false
false
false
false
false
0
put_externals(FILE *fp) { symbol_ident_list list; symtab_entry *e; int i; int tag; int count; /* number of units explicitly imported from */ put_1(fp, 0x00); /* TODO */ /* List of unit names (TODO) */ /* 16-bit count followed by name list */ symtab_list_type(ANY_SYMBOL, &lis...
false
false
false
false
false
0
nemo_query_editor_changed_force (NemoQueryEditor *editor, gboolean force_reload) { NemoQuery *query; if (editor->details->change_frozen) { return; } if (query_is_valid (editor)) { query = nemo_query_editor_get_query (editor); g_signal_emit (editor, signals[CHANGED], 0, query, force_reload); g_o...
false
false
false
false
false
0
InsertLine(const char *line, size_t len, Strip strip, const MarkerDelimiters& delim, char* buffer) { bool add_newline = (len > 0 && line[len-1] == '\n'); if (add_newline) len--; // so we ignore the newline from now on if (strip >= STRIP_WHITESPACE) { StripTempl...
false
false
false
false
false
0
pop_back( ) { // check if( m_size == 0 ) return 0; // if obj if( m_is_obj ) { Chuck_Object * v = (Chuck_Object *)m_vector[m_size-1]; if( v ) v->release(); } // zero m_vector[m_size-1] = 0; // add to vector m_vector.pop_back(); // track size ...
false
false
false
false
false
0
calendar_type(int ncid, int varid) { int ctype; int stat; ncatt_t catt; static struct { char* attname; int type; } calmap[] = { {"gregorian", cdMixed}, {"standard", cdMixed}, /* synonym */ {"proleptic_gregorian", cdStandard}, {"noleap", cdNoLeap}, {"no_leap", cdNoLeap}, {"365_day", cdNoLeap}...
false
false
false
false
false
0
gda_sql_statement_normalize (GdaSqlStatement *stmt, GdaConnection *cnc, GError **error) { gboolean retval; g_return_val_if_fail (stmt, FALSE); if (!stmt->validity_meta_struct && !gda_sql_statement_check_validity (stmt, cnc, error)) return FALSE; retval = gda_sql_any_part_foreach (GDA_SQL_ANY_PART (stmt->content...
false
false
false
false
false
0
parse_date( const char *str ) { char *end; time_t date; int hours, mins; struct tm datetime; memset( &datetime, 0, sizeof(datetime) ); if (!(end = strptime( str, "%d-%b-%Y %H:%M:%S ", &datetime ))) return -1; if ((date = mktime( &datetime )) == -1) return -1; if (sscanf( end, "%3d%2d", &hours, &mins ) != 2...
false
false
false
false
false
0
config_get(struct config *config, int argc, char **argv) { const char *home; char path[4096]; int ret; memset(config, 0, sizeof(*config)); config->autoreconnect = true; home = getenv("HOME"); if (home == NULL) { ret = 1; } else { snprintf(path, sizeof(path), "%s/.uoprox...
false
false
false
false
false
0
gst_mulawdec_chain (GstPad * pad, GstBuffer * buffer) { GstMuLawDec *mulawdec; gint16 *linear_data; guint8 *mulaw_data; guint mulaw_size; GstBuffer *outbuf; GstFlowReturn ret; mulawdec = GST_MULAWDEC (GST_PAD_PARENT (pad)); if (G_UNLIKELY (mulawdec->rate == 0)) goto not_negotiated; mulaw_data =...
false
false
false
false
false
0
write_rb(struct ringbuf* rb, void* buf, unsigned int size) { int ret = -1; int endfree; _ENTER; _RB_LOCK(rb->lock); ASSERT_RB(rb); if (rb->free < size) { ret = -1; goto out; } endfree = (rb->end - rb->wp)+1; if (endfree < size) { /* * There is e...
false
true
false
false
false
1
gui_to_overview_pos(const struct tileset *t, int *ovr_x, int *ovr_y, int gui_x, int gui_y) { double ntl_x, ntl_y; gui_to_natural_pos(t, &ntl_x, &ntl_y, gui_x, gui_y); /* Now convert straight to overview coordinates. */ *ovr_x = floor((ntl_x - (double)overview.map_x0) * OVERVIEW_TILE_SIZE); *ovr_y = ...
false
false
false
false
false
0
mboxname_to_userid(const char *mboxname) { static char userid[MAX_MAILBOX_BUFFER]; const char *domain = NULL, *cp; char *rp; int domainlen = 0; if (config_virtdomains && (cp = strchr(mboxname, '!'))) { /* locate, save, and skip domain */ domain = mboxname; domainlen = cp++ - mboxname; } else...
false
false
false
false
false
0
Scm_RaiseCondition(ScmObj condition_type, ...) { ScmObj argh = SCM_NIL, argt = SCM_NIL; va_list ap; if (!SCM_CLASSP(condition_type) || !Scm_SubtypeP(SCM_CLASS(condition_type), SCM_CLASS_CONDITION)) { /* If we don't get a condition type, fallback to a normal error. */ condition_type ...
false
false
false
false
false
0
ec_GFp_nistp256_points_mul_vartime( const mp_int *n1, const mp_int *n2, const mp_int *in_x, const mp_int *in_y, mp_int *out_x, mp_int *out_y, const ECGroup *group) { u8 scalar1[32], scalar2[32]; felem x1, y1, z1, x2, y2, z2, x_affine, y_affine, px, py; mp_err res = MP_OKAY; /* If n2 == NULL, this i...
false
true
false
false
false
1
_e2_fs_charset_is_utf (gchar *filecoding) { return (!strcmp (filecoding, "UTF-8") || strstr (filecoding, "ASCII") != NULL || !strcmp (filecoding, "ANSI_X3.4-1968") || !strcmp (filecoding, "646") || !strcmp (filecoding, "ISO646") || !strcmp (filecoding, "ISO_646.IRV")); }
false
false
false
false
false
0
arizona_set_sysclk(struct snd_soc_codec *codec, int clk_id, int source, unsigned int freq, int dir) { struct arizona_priv *priv = snd_soc_codec_get_drvdata(codec); struct arizona *arizona = priv->arizona; char *name; unsigned int reg; unsigned int mask = ARIZONA_SYSCLK_FREQ_MASK | ARIZONA_SYSCLK_SRC_MASK;...
false
false
false
false
false
0
test_properties (IndicatorModelTestFixture *fixture, gconstpointer user_data) { UnityWebappsIndicatorModel *model; UnityWebappsInterestManager *manager; g_object_get (fixture->controller, "model", &model, "interest-manager", &manager, NULL); g_assert (model == fixture->indicator_model); g_assert (...
false
false
false
false
false
0
stk_vidioc_qbuf(struct file *filp, void *priv, struct v4l2_buffer *buf) { struct stk_camera *dev = video_drvdata(filp); struct stk_sio_buffer *sbuf; unsigned long flags; if (buf->memory != V4L2_MEMORY_MMAP) return -EINVAL; if (buf->index >= dev->n_sbufs) return -EINVAL; sbuf = dev->sio_bufs + buf->index; ...
false
false
false
false
false
0
baytech_reset_req(StonithPlugin * s, int request, const char * host) { int rc = S_OK; int lorc = 0; struct pluginDevice* bt; ERRIFNOTCONFIGED(s,S_OOPS); bt = (struct pluginDevice*) s; if ((rc = RPCRobustLogin(bt)) != S_OK) { LOG(PIL_CRIT, "Cannot log into %s." , bt->idinfo ? bt->idinfo : DEVICE); }else{ ...
false
false
false
false
false
0
set_acpi_trip(struct acpi_power_meter_resource *resource) { union acpi_object arg_objs[] = { {ACPI_TYPE_INTEGER}, {ACPI_TYPE_INTEGER} }; struct acpi_object_list args = { 2, arg_objs }; unsigned long long data; acpi_status status; /* Both trip levels must be set */ if (resource->trip[0] < 0 || resource->trip...
false
false
false
false
false
0
jme_alloc_rx_resources(struct jme_adapter *jme) { unsigned int i; struct jme_ring *rxring = &jme->rxring; struct io_buffer **bufinf; rxring->desc = malloc_dma(jme->rx_ring_size * RX_DESC_SIZE, RING_DESC_ALIGN); if (!rxring->desc) { DBG("Can not allocate receive ring descriptors.\n"); goto err_out; } /* ...
false
false
false
false
false
0
getRecordOffset(int num, uint32_t nodeNum, BTree* tree) { uint16_t offset; off_t nodeOffset; nodeOffset = nodeNum * tree->headerRec->nodeSize; if(!READ(tree->io, nodeOffset + tree->headerRec->nodeSize - (sizeof(uint16_t) * (num + 1)), sizeof(uint16_t), &offset)) { hfs_panic("cannot get record offset!"...
false
false
false
false
false
0
sharedobject_clear(const fn_call& fn) { SharedObject_as* obj = ensure<ThisIsNative<SharedObject_as> >(fn); UNUSED(obj); LOG_ONCE(log_unimpl(__FUNCTION__)); return as_value(); }
false
false
false
false
false
0
_validate_stripesize(struct cmd_context *cmd, const struct volume_group *vg, struct lvresize_params *lp) { if (arg_sign_value(cmd, stripesize_ARG, SIGN_NONE) == SIGN_MINUS) { log_error("Stripesize may not be negative."); return 0; } if (arg_uint64_value(cmd, stripesize_ARG, 0) > STRIPE_SIZE_LIMIT * 2) {...
false
false
false
false
false
0
get_secrets_cb (DBusGProxy *proxy, DBusGProxyCall *proxy_call, gpointer user_data) { RemoteCall *call = user_data; NMRemoteConnectionGetSecretsFunc func = (NMRemoteConnectionGetSecretsFunc) call->callback; GHashTable *secrets; GError *error = NULL; dbus_g_proxy_end_call (proxy, proxy_call, &error, ...
false
false
false
false
false
0
gwy_plain_tool_get_z_average(GwyDataField *data_field, const gdouble *point, gint radius) { gint col, row, n, i; gdouble *values; gdouble avg; g_return_val_if_fail(GWY_IS_DATA_FIELD(data_field), 0.0); g_return_val_if_fail(point, 0.0); g_...
false
false
false
false
false
0
on_shooting_chooseword_ok_clicked () { if (g_pReciteWord->shooting->start_pause_button_status==0) { g_pReciteWord->shooting->pause_button.set_enable(true); } else if (g_pReciteWord->shooting->start_pause_button_status==1) { g_pReciteWord->shooting->pause_button.set_enable(true); } else if (g_pReciteWord->sho...
false
false
false
false
false
0
updateFont() { PangoFontDescription *desc = NULL; gFont *fnt; fnt = parent->textFont(); if (!fnt) fnt = parent->font(); if (fnt) desc = fnt->desc(); gtk_widget_modify_font(widget, desc); gtk_widget_modify_font(label, desc); }
false
false
false
false
false
0
getTrackFilename(FXint id){ FXString filename; FXString path; FXint pathid; try { query_track_filename.setParameter(0,id); query_track_filename.execute(); query_track_filename.getResult(0,filename); query_track_filename.getResult(1,pathid); query_track_filename.reset(); query_path.se...
false
false
false
false
false
0
get_fg_tile_info(int tile_index) { int tile = lastduel_scroll1[tile_index] & 0x1fff; int color = lastduel_scroll1[tile_index+0x0800]; SET_TILE_INFO( 3, tile, color & 0xf, TILE_FLIPYX((color & 0x60) >> 5) | TILE_SPLIT((color & 0x10) >> 4)) }
false
false
false
false
false
0
dispatch_event (saver_info *si, XEvent *event) { /* If this is for the splash dialog, pass it along. Note that the password dialog is handled with its own event loop, so events for that window will never come through here. */ if (si->splash_dialog && event->xany.window == si->splash_dialog) handle_...
false
false
false
false
false
0
transport_cmd_check_stop(struct se_cmd *cmd, bool remove_from_lists, bool write_pending) { unsigned long flags; if (remove_from_lists) { target_remove_from_state_list(cmd); /* * Clear struct se_cmd->se_lun before the handoff to FE. */ cmd->se_lun = NULL; } spin_lock_irqsave(&cmd->t_state_lock...
false
false
false
false
false
0
gts_colored_vertex_read (GtsObject ** o, GtsFile * fp) { if (GTS_OBJECT_CLASS (gts_colored_vertex_class ())->parent_class->read) (* GTS_OBJECT_CLASS (gts_colored_vertex_class ())->parent_class->read) (o, fp); if (fp->type == GTS_ERROR) return; if (fp->type != GTS_INT && fp->type != GTS_FLOAT) { ...
false
false
false
false
false
0
lock_initialization (saver_info *si, int *argc, char **argv) { #ifdef NO_LOCKING si->locking_disabled_p = True; si->nolock_reason = "not compiled with locking support"; #else /* !NO_LOCKING */ /* Finish initializing locking, now that we're out of privileged code. */ if (! lock_init (*argc, argv, si->prefs.verb...
false
false
false
false
false
0
is_same_str(char *x, char *y) { int i = 0; /* * Using strcmp() == 0 is probably ok, but just to be sure, * since we got UTF-8 strings, we do it ourselves. * * We assume null-terminated correctly encoded UTF-8. */ while (x[i] == y[i]) { if (x[i] == '\0') return 1; i++; } ...
false
false
false
false
false
0
ShiftWiggleIterator(WiggleIterator * i, double s) { ScaleWiggleIteratorData * data = (ScaleWiggleIteratorData *) calloc(1, sizeof(ScaleWiggleIteratorData)); data->iter = NonOverlappingWiggleIterator(i); data->scalar = s; float default_value; if (isnan(i->default_value)) default_value = NAN; else default_value...
false
false
false
false
false
0
evaluate(string_ty *path_unres, string_ty *path, string_ty *path_res, struct stat *st) const { rpt_value::pointer v1 = get_left()->evaluate(path_unres, path, path_res, st); if (v1->is_an_error()) return v1; rpt_value::pointer v1i = rpt_value::integerize(v1); rpt_value_integer *v1ip = dynami...
false
false
false
false
false
0
addEarlyCSEOrGVNPass() { if (getOptLevel() == CodeGenOpt::Aggressive) addPass(createGVNPass()); else addPass(createEarlyCSEPass()); }
false
false
false
false
false
0
skipOptnoneFunction(const Loop *L) const { const Function *F = L->getHeader()->getParent(); if (F && F->hasFnAttribute(Attribute::OptimizeNone)) { // FIXME: Report this to dbgs() only once per function. DEBUG(dbgs() << "Skipping pass '" << getPassName() << "' in function " << F->getName() << "\n")...
false
false
false
false
false
0
isert_free_np(struct iscsi_np *np) { struct isert_np *isert_np = np->np_context; struct isert_conn *isert_conn, *n; if (isert_np->cm_id) rdma_destroy_id(isert_np->cm_id); /* * FIXME: At this point we don't have a good way to insure * that at this point we don't have hanging connections that * completed RD...
false
false
false
false
false
0
remove_backslash_escapes(char *src) { char *ans = NULL, *q, *p; int done = 0; if(src){ p = q = (char *)fs_get(strlen(src) + 1); while(!done){ switch(*src){ case '\\': src++; if(*src){ if(isdigit((unsigned char)*src)) *p++ = (char)read_octal(&src); else if((*src == 'x'...
false
false
false
false
false
0
bbufferDestroyAndSaveData(BBUFFER **pbb, size_t *pnbytes) { l_uint8 *array; size_t nbytes; BBUFFER *bb; PROCNAME("bbufferDestroyAndSaveData"); if (pbb == NULL) { L_WARNING("ptr address is NULL\n", procName); return NULL; } if (pnbytes == NULL) { ...
false
false
false
false
false
0
get_type_name (gpointer object) { const char *type_name; char *ret; type_name = g_type_name (G_TYPE_FROM_INSTANCE (object)); if (strcmp ("GProxyDrive", type_name) == 0) { ret = g_strdup_printf ("%s (%s)", type_name, (const char *) g_object_get...
false
false
false
false
false
0
getAssumptionsRef() const { DebugAssert(!isNull(), "CVC3::Theorem::getAssumptionsRef: we are Null"); if (!isRefl()) { return thm()->getAssumptionsRef(); } else return Assumptions::emptyAssump(); }
false
false
false
false
false
0
LoadArticulations() { // prefer articulation level 2 RIFF::List* lart = pParentList->GetSubList(LIST_TYPE_LAR2); if (!lart) lart = pParentList->GetSubList(LIST_TYPE_LART); if (lart) { uint32_t artCkType = (lart->GetListType() == LIST_TYPE_LAR2) ? CHUNK_ID_ART2 ...
false
false
false
false
false
0
destroy_most_c_obj(struct most_c_obj *c) { if (c->aim0.ptr) c->aim0.ptr->disconnect_channel(c->iface, c->channel_id); if (c->aim1.ptr) c->aim1.ptr->disconnect_channel(c->iface, c->channel_id); c->aim0.ptr = NULL; c->aim1.ptr = NULL; mutex_lock(&deregister_mutex); flush_trash_fifo(c); flush_channel_fifos(c);...
false
false
false
false
false
0
async_context_free (AsyncContext *async_context) { if (async_context->ipart != NULL) g_object_unref (async_context->ipart); if (async_context->opart != NULL) g_object_unref (async_context->opart); if (async_context->stream != NULL) g_object_unref (async_context->stream); if (async_context->strings != NULL)...
false
false
false
false
false
0
pdf_load_xref(pdf_document *xref, pdf_lexbuf *buf) { int size; int i; fz_context *ctx = xref->ctx; pdf_load_version(xref); pdf_read_start_xref(xref); pdf_read_trailer(xref, buf); size = pdf_to_int(pdf_dict_gets(xref->trailer, "Size")); if (!size) fz_throw(ctx, "trailer missing Size entry"); if (size > x...
false
false
false
false
false
0
console_set(struct userrec *u, struct user_entry *e, void *buf) { struct console_info *ci = (struct console_info *) e->u.extra; if (!ci && !buf) return 1; if (ci != buf) { if (ci) { nfree(ci->channel); nfree(ci); } ci = e->u.extra = buf; } /* Note: Do not share console info */ ...
false
false
false
false
false
0
RSA_padding_add_none(unsigned char *to, int tlen, const unsigned char *from, int flen) { if (flen > tlen) { RSAerr(RSA_F_RSA_PADDING_ADD_NONE,RSA_R_DATA_TOO_LARGE_FOR_KEY_SIZE); return(0); } if (flen < tlen) { RSAerr(RSA_F_RSA_PADDING_ADD_NONE,RSA_R_DATA_TOO_SMALL_FOR_KEY_SIZE); return(0); } mem...
false
false
false
false
false
0
ResetMidiBuffer(JackMidiBuffer *buffer) { event_count = 0; index = 0; if (! buffer) { jack_error("JackMidiBufferReadQueue::ResetMidiBuffer - buffer reset " "to NULL"); } else if (! buffer->IsValid()) { jack_error("JackMidiBufferReadQueue::ResetMidiBuffer - buffer reset...
false
false
false
false
false
0
gst_play_sink_convert_bin_getcaps (GstPad * pad, GstCaps * filter) { GstPlaySinkConvertBin *self = GST_PLAY_SINK_CONVERT_BIN (gst_pad_get_parent (pad)); GstCaps *ret; GstPad *otherpad, *peer; GST_PLAY_SINK_CONVERT_BIN_LOCK (self); if (pad == self->srcpad) { otherpad = self->sinkpad; } else if (pa...
false
false
false
false
false
0
checkVM(const unsigned long vmNum, const OFString &vmStr) { OFCondition result = EC_Normal; // only check non-empty values if (vmNum > 0) { if (vmStr == "1") { if (vmNum != 1) result = EC_ValueMultiplicityViolated; } else if (vmStr == "1-2") { if (...
false
false
false
false
false
0
logfs_segment_write_compress(struct inode *inode, void *buf, struct logfs_shadow *shadow, int type, int len) { struct super_block *sb = inode->i_sb; void *compressor_buf = logfs_super(sb)->s_compressed_je; ssize_t compr_len; int ret; mutex_lock(&logfs_super(sb)->s_journal_mutex); compr_len = logfs_compress(buf...
false
false
false
false
false
0
get_cell_and_realm (krb5_context context, struct akf_data *d) { FILE *f; char buf[BUFSIZ], *cp; int ret; f = fopen (AFS_SERVERTHISCELL, "r"); if (f == NULL) { ret = errno; krb5_set_error_message (context, ret, N_("Open ThisCell %s: %s", ""), AFS_SERVERTHISCELL, strerror(ret)); return...
true
true
true
false
true
1
mx_icon_theme_copy_data_list (GList *data) { GList *d, *new_data = g_list_copy (data); for (d = new_data; d; d = d->next) { MxIconData *icon_data; d->data = g_memdup (d->data, sizeof (MxIconData)); icon_data = d->data; icon_data->path = g_strdup (icon_data->path); } return new_dat...
false
false
false
false
false
0
populate_defaults(struct ast_vm_user *vmu) { ast_copy_flags(vmu, (&globalflags), AST_FLAGS_ALL); vmu->passwordlocation = passwordlocation; if (saydurationminfo) { vmu->saydurationm = saydurationminfo; } ast_copy_string(vmu->callback, callcontext, sizeof(vmu->callback)); ast_copy_string(vmu->dialout, dialcontext...
false
false
false
false
false
0
hfs_free_extents(struct super_block *sb, struct hfs_extent *extent, u16 offset, u16 block_nr) { u16 count, start; int i; hfs_dump_extent(extent); for (i = 0; i < 3; extent++, i++) { count = be16_to_cpu(extent->count); if (offset == count) goto found; else if (offset < count) break; offset -= c...
false
false
false
false
false
0
enic_log_q_error(struct enic *enic) { unsigned int i; u32 error_status; bool err = false; for (i = 0; i < enic->wq_count; i++) { error_status = vnic_wq_error_status(&enic->wq[i]); err |= error_status; if (error_status) netdev_err(enic->netdev, "WQ[%d] error_status %d\n", i, error_status); } for (i ...
false
false
false
false
false
0
vpip_scope(__vpiRealVar*sig) { if (sig->is_netarray) return (struct __vpiScope*) vpi_handle(vpiScope, sig->within.parent); else return sig->within.scope; }
false
false
false
false
false
0
cmu_has_vowel_in_list(const cst_val *v) { const cst_val *t; for (t=v; t; t=val_cdr(t)) if (cmu_is_vowel(val_string(val_car(t)))) return TRUE; return FALSE; }
false
false
false
false
false
0
tree_request(struct view *view, enum request request, struct line *line) { enum open_flags flags; switch (request) { case REQ_VIEW_BLAME: if (line->type != LINE_TREE_FILE) { report("Blame only supported for files"); return REQ_NONE; } string_copy(opt_ref, view->vid); return request; case REQ_EDIT: ...
false
false
false
false
false
0
population_append_ind(Population *pop, Individual *ind) { if (pop->actual_size == pop->max_size - 1) return NULL; pop->individuals[pop->actual_size] = ind; pop->actual_size++; return pop; }
false
false
false
false
false
0
modem_check_nocarrier(char c) { if (c == nocarriertxt[nocarrierpos]) { nocarrierpos++; if (nocarrierpos >= strlen(nocarriertxt)) { log(L_JUNK, "*** NO CARRIER ***\n"); nocarrier = TRUE; nocarrierpos = 0; } } else { nocarrierpos = 0; if (c == nocarriertxt[0]) nocarrierpos++; } }
false
false
false
false
false
0
inf_text_session_segment_from_xml(GIConv* cd, xmlNodePtr xml, guint* length, gsize* bytes, guint* author, GError** error) { gsize bytes_read; gcha...
false
false
false
false
false
0
gtk_clutter_actor_hide (ClutterActor *self) { GtkClutterActorPrivate *priv = GTK_CLUTTER_ACTOR (self)->priv; GtkWidget *widget; CLUTTER_ACTOR_CLASS (gtk_clutter_actor_parent_class)->hide (self); /* proxy this call through to GTK+ */ widget = gtk_bin_get_child (GTK_BIN (priv->widget)); if (widget != NULL) ...
false
false
false
false
false
0
cb_toolbar_button_press (GtkToolbar *tb, GdkEventButton *event, WBCGtk *gtk) { if (event->type == GDK_BUTTON_PRESS && event->button == 3) { toolbar_context_menu (tb, gtk, event); return TRUE; } return FALSE; }
false
false
false
false
false
0
getRegisterByName(const char* RegName, EVT VT, SelectionDAG &DAG) const { // Named registers is expected to be fairly rare. For now, just support $28 // since the linux kernel uses it. if (Subtarget.isGP64bit()) { unsigned Reg = StringSwitch<unsigned>(RegName) ...
false
false
false
false
false
0
outline() { //bounds.draw(); if(!items.empty()) { bounds.draw(); /*glBegin(GL_LINES); glVertex2fv(bounds.min); glVertex2fv(bounds.max); glEnd();*/ } if(children.empty()) return; for(int i=0;i<4;i++) { QuadNode* c = children[i]; if(c!...
false
false
false
false
false
0
show_ce_type_list(lList *cel, const char *indent, const char *separator, bool display_resource_contribution, lList *centry_list, int slots) { bool first = true; const lListElem *ce, *centry; const char *s, *name; double uc = -1; DENTER(TOP_LAYER, "show_ce_typ...
false
false
false
false
false
0
mosquitto_username_pw_set(struct mosquitto *mosq, const char *username, const char *password) { if(!mosq) return MOSQ_ERR_INVAL; if(mosq->username){ _mosquitto_free(mosq->username); mosq->username = NULL; } if(mosq->password){ _mosquitto_free(mosq->password); mosq->password = NULL; } if(username){ mos...
false
false
false
false
false
0