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
RECSIZE(const char *ptr) { int ret = 0; switch (TYPE(ptr)) { case DUMMY: case INORDER: case ADD: ret += 4; /* tag */ ret += 4; /* keylen */ ret += ROUNDUP(KEYLEN(ptr)); /* key */ ret += 4; /* datalen */ ret += ROUNDUP(DATALEN(ptr)); /* data */ ret += 4 * LEVEL(ptr); /* point...
false
false
false
false
false
0
nfs_fs_mount_common(struct nfs_server *server, int flags, const char *dev_name, struct nfs_mount_info *mount_info, struct nfs_subversion *nfs_mod) { struct super_block *s; struct dentry *mntroot = ERR_PTR(-ENOMEM); int (*compare_super)(struct super_block *, void *) = nfs_compare_super; struct n...
false
false
false
false
false
0
refreshRenderer() { if ( modelInfo->dimension == ECIF_ND ) { return; } Renderer* renderer = theControlCenter->getRenderer(); if ( renderer != NULL && renderer->isVisible() ) renderer->refresh(); }
false
false
false
false
false
0
vpow(double e1,double e2) { if (e2==2) return(e1*e1); if (e1<=0) return(0.0); return(exp(e2*log(e1))); }
false
false
false
false
false
0
gen_inlined_subroutine_die (stmt, context_die, depth) tree stmt; dw_die_ref context_die; int depth; { tree decl = block_ultimate_origin (stmt); /* Emit info for the abstract instance first, if we haven't yet. We must emit this even if the block is abstract, otherwise when we emit the bloc...
false
false
false
false
false
0
ir_process_read_urb(struct urb *urb) { struct usb_serial_port *port = urb->context; unsigned char *data = urb->transfer_buffer; if (!urb->actual_length) return; /* * The first byte of the packet we get from the device * contains a busy indicator and baud rate change. * See section 5.4.1.2 of the USB IrDA s...
false
false
false
false
false
0
lt_redundant_db_new(void) { lt_redundant_db_t *retval = lt_mem_alloc_object(sizeof (lt_redundant_db_t)); if (retval) { lt_error_t *err = NULL; LT_ITER_TMPL_INIT (&retval->parent, _lt_redundant_db); retval->redundant_entries = lt_trie_new(); lt_mem_add_ref((lt_mem_t *)retval, retval->redundant_entries, ...
false
false
false
false
false
0
art_affine_rectilinear (const double src[6]) { return ((fabs (src[1]) < EPSILON && fabs (src[2]) < EPSILON) || (fabs (src[0]) < EPSILON && fabs (src[3]) < EPSILON)); }
false
false
false
false
false
0
print_bufinfo(struct v4l2_buffer *buf) { static char *type[] = { [V4L2_BUF_TYPE_VIDEO_CAPTURE] = "video-cap", [V4L2_BUF_TYPE_VIDEO_OVERLAY] = "video-over", [V4L2_BUF_TYPE_VIDEO_OUTPUT] = "video-out", [V4L2_BUF_TYPE_VBI_CAPTURE] = "vbi-cap", [V4L2_BUF_TYPE_VBI_OUTPUT] = "vbi-out", }; fprintf(stde...
false
false
false
false
false
0
g_vfs_write_channel_finalize (GObject *object) { if (G_OBJECT_CLASS (g_vfs_write_channel_parent_class)->finalize) (*G_OBJECT_CLASS (g_vfs_write_channel_parent_class)->finalize) (object); }
false
false
false
false
false
0
selectNextPlayer (void) { if ( !isRegularMenuSelected () ) { if ( 0 == getSelectedPlayer () ) { setSelectedPlayer (getSelectedPlayer () + 1); } } }
false
false
false
false
false
0
gth_window_attach (GthWindow *window, GtkWidget *child, GthWindowArea area) { int position; g_return_if_fail (window != NULL); g_return_if_fail (GTH_IS_WINDOW (window)); g_return_if_fail (child != NULL); g_return_if_fail (GTK_IS_WIDGET (child)); switch (area) { case GTH_WINDOW_MENUBAR: win...
false
false
false
false
false
0
filter_merge(apr_pool_t *pool, void *BASE, void *ADD) { mod_filter_cfg *base = BASE; mod_filter_cfg *add = ADD; mod_filter_chain *savelink = 0; mod_filter_chain *newlink; mod_filter_chain *p; mod_filter_cfg *conf = apr_palloc(pool, sizeof(mod_filter_cfg)); conf->live_filters = apr_hash_over...
false
false
false
false
false
0
gar_free_graph(struct gar_graph *g) { int i; struct node *n, *ns; for (i = 0; i < NODE_HASH_TAB_SIZE; i++) { list_for_entry_safe(n, ns,&g->lnodes[i],l) { gar_free_node(n); } } if (!list_empty(&g->lqueue)) { log(1, "NOD error read queue not empty\n"); } if (!list_empty(&g->lcpoints)) { log(1, "NOD erro...
false
false
false
false
false
0
schedule_init_vector(vvp_net_ptr_t ptr, vvp_vector4_t bit) { struct assign_vector4_event_s*cur = new struct assign_vector4_event_s(bit); cur->ptr = ptr; cur->base = 0; cur->vwid = 0; cur->next = schedule_init_list; schedule_init_list = cur; }
false
false
false
false
false
0
kfd_gtt_sa_free(struct kfd_dev *kfd, struct kfd_mem_obj *mem_obj) { unsigned int bit; BUG_ON(!kfd); /* Act like kfree when trying to free a NULL object */ if (!mem_obj) return 0; pr_debug("kfd: free mem_obj = %p, range_start = %d, range_end = %d\n", mem_obj, mem_obj->range_start, mem_obj->range_end); mut...
false
false
false
false
false
0
ql_display_dev_info(struct net_device *ndev) { struct ql3_adapter *qdev = netdev_priv(ndev); struct pci_dev *pdev = qdev->pdev; netdev_info(ndev, "%s Adapter %d RevisionID %d found %s on PCI slot %d\n", DRV_NAME, qdev->index, qdev->chip_rev_id, qdev->device_id == QL3032_DEVICE_ID ? "QLA3032" : "QL...
false
false
false
false
false
0
dev_c7200_pa_bri_set_nio(vm_instance_t *vm,struct cisco_card *card, u_int port_id,netio_desc_t *nio) { struct pa_4b_data *d = card->drv_info; if (!d || (port_id > 0)) return(-1); if (d->nio != NULL) return(-1); d->nio = nio; /* TEST */ d->m32_data.tx_tid = ...
false
false
false
false
false
0
vGet6FootnotesText(FILE *pFile, ULONG ulStartBlock, const ULONG *aulBBD, size_t tBBDLen, const UCHAR *aucHeader) { footnote_local_type *pCurr; UCHAR *aucBuffer; ULONG ulCharPos, ulBeginOfFootnotes, ulOffset, ulBeginFootnoteText; size_t tFootnoteTextLen; size_t tIndex; TRACE_MSG("vGet6FootnotesText"); fail(pF...
false
false
false
false
false
0
bpchar_input(const char *s, size_t len, int32 atttypmod) { BpChar *result; char *r; size_t maxlen; /* If typmod is -1 (or invalid), use the actual string length */ if (atttypmod < (int32) VARHDRSZ) maxlen = len; else { size_t charlen; /* number of CHARACTERS in the input */ maxlen = atttypmod - V...
false
false
false
false
false
0
nocase_streq(register char const*a, register char const *with) { while (*with!='\0' && *a!='\0') if ((USGE('Z'-'A',*a-'A') ? *a+++'a'-'A' : *a++) !=(USGE('Z'-'A',*with-'A') ? *with+++'a'-'A' : *with++) ) return FALSE; return *with==*a; /* BUGFIX at Sun Dec 8 19:38:05 CET 2002 */ }
false
false
false
false
false
0
toCBuffer(OutBuffer *buf, HdrGenState *hgs) { buf->writestring("typedef "); basetype->toCBuffer(buf, ident, hgs); if (init) { buf->writestring(" = "); init->toCBuffer(buf, hgs); } buf->writeByte(';'); buf->writenl(); }
false
false
false
false
false
0
GetUsername() { #if defined (_WIN32) && !defined(__CYGWIN__) static char buf[1024]; DWORD size = sizeof(buf); buf[0] = '\0'; GetUserName( buf, &size); return buf; #else // not _WIN32 struct passwd *pw = getpwuid(getuid()); if ( pw == NULL ) { METAIO_STREAM::cout << "getpwuid()...
false
false
false
true
false
1
sec_pkcs12_append_shrouded_key(SEC_PKCS12BaggageItem *bag, SEC_PKCS12ESPVKItem *espvk) { int size; void *mark = NULL, *dummy = NULL; if((bag == NULL) || (espvk == NULL)) return SECFailure; mark = PORT_ArenaMark(bag->poolp); /* grow the list */ size = (bag->nEspvks + 1) * sizeof(SEC_PKCS1...
false
false
false
false
false
0
static_raw_x1y1z1 (int cell_x, int cell_y, int cell_z, int shell, static_polytope *polytope) { int n, n_x, n_y, n_z; n = polytope->n_cells; /************************************************** * find neighbours in cells along x1y1z1 vertices * **************************************************/ n_x = shell + cell_x...
false
false
false
false
false
0
GetMaxCellSize() { int result; switch(this->Dimension) { case 3: result=8; // hexahedron=8 points break; case 2: result=4; // quad=4 points break; case 1: result=2; // line=2 points break; default: result=0; // useless, just to avoid a warning asse...
false
false
false
false
false
0
fso_framework_base_transport_actionCallback (FsoFrameworkBaseTransport* self, GIOChannel* source, GIOCondition condition) { gboolean result = FALSE; gboolean _tmp0_ = FALSE; GIOCondition _tmp2_ = 0; GIOCondition _tmp6_ = 0; FsoFrameworkLogger* _tmp9_ = NULL; GIOCondition _tmp10_ = 0; gchar* _tmp11_ = NULL; gcha...
false
false
false
false
false
0
decode_header( ByteStream &inp, int &width, int &height, int &invert) { unsigned long int magic = inp.read32(); if((magic&0xfffffffc) != 0x4d4d5200) G_THROW( ERR_MSG("MMRDecoder.unrecog_header") ); invert = ((magic & 0x1) ? 1 : 0); const bool strip = ((magic & 0x2) ? 1 : 0); width = inp.read16(); he...
false
false
false
false
false
0
rinoo_dns_destroy(t_dns *dns) { if (dns->answer != NULL) { free(dns->answer); } if (dns->authority != NULL) { free(dns->authority); } if (dns->additional != NULL) { free(dns->additional); } rinoo_socket_destroy(dns->socket); }
false
false
false
false
false
0
pg_parse_and_rewrite(const char *query_string, /* string to execute */ Oid *paramTypes, /* parameter types */ int numParams) /* number of parameters */ { List *raw_parsetree_list; List *querytree_list; ListCell *list_item; /* * (1) parse the request string into a list of raw parse trees. *...
false
false
false
false
false
0
SetModeNumber(EMode *mode, int what, int number) { int j = what; if (j == BFI_LeftMargin || j == BFI_RightMargin) number--; mode->Flags.num[j] = number; return 0; }
false
false
false
false
false
0
mime_entity_remove_part(MIMEEntity *e, int i) { MIMEEntity *m; gw_assert(e != NULL); gw_assert(i >= 0); gw_assert(i < gwlist_len(e->multiparts)); m = gwlist_get(e->multiparts, i); gwlist_delete(e->multiparts, i, 1); if (m == e->start) e->start = NULL; mime_entity_de...
false
false
false
true
false
1
totem_playlist_file_changed (GFileMonitor *monitor, GFile *file, GFile *other_file, GFileMonitorEvent event_type, TotemPlaylist *playlist) { if (event_type == G_FILE_MONITOR_EVENT_PRE_UNMOUNT || event_type == G_FILE_MONITOR_EVENT_UNMOUNTED) { totem_playlist_clear_with_compare (pl...
false
false
false
false
false
0
mapvue_read_group3(const guchar *p, gsize size, gpointer grpdata, GError **error) { enum { SIZE = 4*4 }; MapVueGroup3 *group = (MapVueGroup3*)grpdata; if (err_TAG_SIZE(error, group->reftag, SIZE, size)) return 0; if (!(size = mapvue_group_size(&p, size, group->reftag, error)...
false
false
false
false
false
0
kmo_combine_pars_create(cpl_parameterlist *pl, const char* recipe_name, const char* default_method, int no_cmethod) { cpl_parameter *p; char *tmpstr = NULL; if ((pl == NULL) || (recipe_name == NULL)){ r...
false
false
false
false
false
0
fz_keep_buffer(fz_context *ctx, fz_buffer *buf) { if (buf) { if (buf->refs == 1 && buf->cap > buf->len+1) fz_resize_buffer(ctx, buf, buf->len); buf->refs ++; } return buf; }
false
false
false
false
false
0
operator-=( difference_type n ) { if ( n < 0 ) _seekRev( -n ); else _seekFwd( n ); return *this; }
false
false
false
false
false
0
Get3DcBlock(ILubyte *Block, ILubyte *Data, ILimage *Image, ILuint XPos, ILuint YPos, int channel) { ILuint x, y, i = 0, Offset = 2*(YPos * Image->Width + XPos) + channel; for (y = 0; y < 4; y++) { for (x = 0; x < 4; x++) { if (x < Image->Width && y < Image->Height) Block[i++] = Data[Offset + 2*x...
false
false
false
false
false
0
pkey_cmac_copy(EVP_PKEY_CTX *dst, EVP_PKEY_CTX *src) { if (!pkey_cmac_init(dst)) return 0; if (!CMAC_CTX_copy(dst->data, src->data)) return 0; return 1; }
false
false
false
false
false
0
free_smartphone_time_wakeup_alarm_init (FreeSmartphoneTimeWakeupAlarm *self, const gchar* busname, gint timestamp) { const gchar* _tmp0_ = NULL; gchar* _tmp1_ = NULL; gint _tmp2_ = 0; g_return_if_fail (busname != NULL); memset (self, 0, sizeof (FreeSmartphoneTimeWakeupAlarm)); _tmp0_ = busname; _tmp1_ = g_strdup...
false
false
false
false
false
0
gt_rdb_stmt_sqlite_exec(GtRDBStmt *st, GtError *err) { GtRDBStmtSqlite *sts; int rval, had_err = 0; gt_assert(st); gt_error_check(err); sts = gt_rdb_stmt_sqlite_cast(st); switch ((rval = sqlite3_step(sts->stmt))) { case SQLITE_ROW: break; case SQLITE_DONE: had_err = 1; /* last row read ...
false
false
false
false
false
0
common_button_do(int i) { if ( i == COMMON_COMMIT_BUTTON ) { Commit_pressed = 1; return; } if ( Background_playing ) return; switch ( i ) { case COMMON_BRIEFING_BUTTON: if ( Current_screen != ON_BRIEFING_SELECT ) { gamesnd_play_iface(SND_SCREEN_MODE_PRESSED); Next_screen = ON_BRIEFING_SELECT; } ...
false
false
false
false
false
0
pp_ping(unsigned long ctx) { struct pp_ctx *pp = (void *)ctx; unsigned long irqflags; u64 db_bits, db_mask; u32 spad_rd, spad_wr; spin_lock_irqsave(&pp->db_lock, irqflags); { db_mask = ntb_db_valid_mask(pp->ntb); db_bits = ntb_db_read(pp->ntb); if (db_bits) { dev_dbg(&pp->ntb->dev, "Masked pongs %#...
false
false
false
false
false
0
setGenericTag( const ExifTagEntry& tag, uint16 marker, const std::string& appSegId, const ExifIFDPath& ifdPath ) { ExifStatus returnValue = EXIF_OK ; ExifTiffAppSeg* appSeg = dynamic_cast<ExifTiffAppSeg*>( mAppSegManager->getAppSeg( marker, appSegId.c_str() ) ) ; if ( appSeg == NULL ) ...
false
false
false
false
false
0
print_instructions(fc_type fc) { char *buffer; uchar *s; writeln("INSTRUCTIONS:"); if (open_ins_file(fc,1)) { /* Instruction file exists */ while ( NULL!=(buffer=read_ins_line()) ) { for(s=(uchar*)buffer;*s!=0;s++) *s=trans_ascii[*s]; writeln(buffer); } } writeln(""); }
false
false
false
false
false
0
be_cleanup(struct be_adapter *adapter) { struct net_device *netdev = adapter->netdev; rtnl_lock(); netif_device_detach(netdev); if (netif_running(netdev)) be_close(netdev); rtnl_unlock(); be_clear(adapter); }
false
false
false
false
false
0
StartPool(Pool *poolPtr, void *ignored) { int i; poolPtr->threads.current = 0; poolPtr->threads.starting = 0; poolPtr->threads.waiting = 0; poolPtr->threads.idle = 0; for (i = 0; i < poolPtr->threads.min; ++i) { poolPtr->threads.current ++; NsCreateConnThread(poolPtr, 1); }...
false
false
false
false
false
0
gather_cb(const void *dst_buf, size_t dst_buf_bytes_used, void *_gather_info) { gather_info_t *gather_info = (gather_info_t *)_gather_info; size_t nelmts; /* Number of elements in src_buf */ int i; /* Local index variable */ HDassert(dst_buf_bytes_used > 0); /* Calculate numb...
false
false
false
false
false
0
gwy_math_nlfit_get_correlations(GwyNLFitter *nlfit, gint par1, gint par2) { gdouble Pom; g_return_val_if_fail(nlfit->covar, G_MAXDOUBLE); if (par1 == par2) return 1.0; if (par1 < par2) GWY_SWAP(gint, par1, par2); Pom = SLi(nlfit->covar, par1, par1) * SLi(nlfit->covar, par2, par2);...
false
false
false
false
false
0
rtl_pci_init(struct ieee80211_hw *hw, struct pci_dev *pdev) { struct rtl_priv *rtlpriv = rtl_priv(hw); int err; _rtl_pci_init_struct(hw, pdev); err = _rtl_pci_init_trx_ring(hw); if (err) { RT_TRACE(rtlpriv, COMP_ERR, DBG_EMERG, "tx ring initialization failed\n"); return err; } return 0; }
false
false
false
false
false
0
adm_user_kick(cnu user, cnu target, char *reason) { cnr room; xmlnode data; xmlnode pres; const char *status; if(user == NULL || target == NULL || reason == NULL) { log_warn(NAME, "[%s] Aborting: NULL attribute found", FZONE); return; } room = target->room; data = xmlnode_new_tag("reason");...
false
false
false
false
false
0
clutter_stage_set_key_focus (ClutterStage *stage, ClutterActor *actor) { ClutterStagePrivate *priv; g_return_if_fail (CLUTTER_IS_STAGE (stage)); g_return_if_fail (actor == NULL || CLUTTER_IS_ACTOR (actor)); priv = stage->priv; /* normalize the key focus. NULL == stage */ if (actor == CLUTTER_ACTO...
false
false
false
false
false
0
ParseAnswerA(QueryArg *arg, unsigned char* abuf, int alen) { HandleScope scope; hostent* host; int status = ares_parse_a_reply(abuf, alen, &host, NULL, NULL); if (status != ARES_SUCCESS) { ResolveError(arg->js_cb, status); return; } Local<Array> addresses = HostEntToAddresses(host); ares_free_h...
false
false
false
false
false
0
generate_outer_join_implications(PlannerInfo *root, List *equi_key_set, Relids *relids) { ListCell *l; int i = 0; /* Process each non-constant element of equi_key_set */ foreach(l, equi_key_set) { PathKeyItem *item1 = (PathKeyItem *) lfirst(l); if (!bms_is_empty(relids[i])) { sub_g...
false
false
false
false
false
0
IsAlpha(unsigned int c) {//======================== // Replacement for iswalph() which also checks for some in-word symbols const unsigned short extra_indic_alphas[] = { 0xa70,0xa71, // Gurmukhi: tippi, addak 0 }; if(iswalpha(c)) return(1); if((c >= 0x901) && (c <= 0xdf7)) { // Indic scripts: Devanagari, T...
false
false
false
false
false
0
sizeof_datatype(int datatype) { switch (datatype) { case TSTRING: return sizeof(char *); case TLOGICAL: return sizeof(logical); case TSBYTE: return sizeof(sbyte); case TBYTE: return sizeof(byte); case TUSHORT: return sizeof(unsigned short); case TSHORT: return sizeof(short); case...
false
false
false
false
false
0
socketModifBaseName() { int row = _socket->readInt(); int col = _socket->readInt(); uint length = _socket->readInt(); QString name; for( uint i = 0; i < length; i++ ) { name[i] = _socket->readChar(); } GenericBase * base = _map->at( row, col )->getBase(); base->setName( name ); }
false
false
false
false
false
0
paintEvent(QPaintEvent *) { if (!root) return; // labels QFont font; // Init paint settings QPainter painter(this); QColor color = Qt::white; QPen pen(Qt::white); pen.setWidth(10); // root QBrush brush(Qt::white); painter.setBrush(brush); painter.setPen(pen); // draw b...
false
false
false
false
false
0
draw_sprites_1 (struct sprite_entry *e, int dualpf, int has_attach) { uae_u16 *buf = spixels + e->first_pixel; uae_u8 *stbuf = spixstate.bytes + e->first_pixel; int spr_pos, pos; buf -= e->pos; stbuf -= e->pos; spr_pos = e->pos + ((DIW_DDF_OFFSET - DISPLAY_LEFT_SHIFT) << sprite_buffer_res); if (spr_pos < spri...
false
false
false
false
false
0
gog_axis_populate_polar_unit_combo (GogAxis *axis, GtkComboBoxText *combo) { unsigned i, id = 0; g_return_if_fail (GOG_IS_AXIS (axis)); for (i = 0; i < G_N_ELEMENTS (polar_units); i++) { gtk_combo_box_text_append_text (combo, _(polar_units[i].name)); if (polar_units[i].unit == axis->polar_unit) id = i; } ...
false
false
false
false
false
0
check_activity_log_stripe_size(struct drbd_device *device, struct meta_data_on_disk *on_disk, struct drbd_md *in_core) { u32 al_stripes = be32_to_cpu(on_disk->al_stripes); u32 al_stripe_size_4k = be32_to_cpu(on_disk->al_stripe_size_4k); u64 al_size_4k; /* both not set: default to old fixed size activity log */...
false
false
false
false
false
0
decode_hex(char *in, int in_len, unsigned char *out, int out_len) { int i, l; unsigned char v, odd; bzero(out, out_len); l = strlen(in); odd = 0; out += out_len-1; if (l > in_len) return -1; in += l-1; for (i = 0; i < l; ++i) { if (*in >= '0' && *in <= '9') v = *in - '0'; else...
false
false
false
false
false
0
atspi_match_rule_new (AtspiStateSet *states, AtspiCollectionMatchType statematchtype, GHashTable *attributes, AtspiCollectionMatchType attributematchtype, GArray *roles, AtspiCollectionMatchType rolematchtype, ...
false
false
false
false
false
0
commonInit(CK_ATTRIBUTE *attr_match, int attr_match_len, const CK_MECHANISM_TYPE *mechs, int mechs_len, const CK_MECHANISM_PTR pMechanism, CK_OBJECT_HANDLE hKey, struct st_object **o) { CK_RV ret; int i; *o = NULL; if ((ret = object_handle_to_object(hKey, o)) != CKR_OK) return ret; re...
false
false
false
false
false
0
WriteTargetBuildRules() { // write the custom commands for this target // Look for files registered for cleaning in this directory. if(const char* additional_clean_files = this->Makefile->GetProperty ("ADDITIONAL_MAKE_CLEAN_FILES")) { cmSystemTools::ExpandListArgument(additional_clean_files, ...
false
false
false
false
false
0
dbxgcg_ParsePir(AjPFile infr, AjPStr *id) { ajlong rpos; if(!dbxgcg_pir_wrdexp) dbxgcg_pir_wrdexp = ajRegCompC("([A-Za-z0-9_]+)"); if(!dbxgcg_pir_idexp) dbxgcg_pir_idexp = ajRegCompC("^>..;([^;.\n\r]+)"); if(!dbxgcg_pir_phrexp) /* allow . for "sp." */ dbxgcg_pir_phrexp = ajRegCompC(" ...
false
false
false
false
false
0
cfm_mgmt_addr_print(register const u_char *tptr) { u_int mgmt_addr_type; u_int hexdump = FALSE; /* * Altough AFIs are tpically 2 octects wide, * 802.1ab specifies that this field width * is only once octet */ mgmt_addr_type = *tptr; printf("\n\t Management Address Type %s (%u...
true
true
false
false
false
1
operator==(const Node &other) const { if(this==&other) { return TRUE; } if(!ValueNode::operator==(other)) { return FALSE; } const IntermediateValueNode &o=(const IntermediateValueNode &)other; return next==o.next; }
false
false
false
false
false
0
c2_qp_set_read_limits(struct c2_dev *c2dev, struct c2_qp *qp, int ord, int ird) { struct c2wr_qp_modify_req wr; struct c2wr_qp_modify_rep *reply; struct c2_vq_req *vq_req; int err; vq_req = vq_req_alloc(c2dev); if (!vq_req) return -ENOMEM; c2_wr_set_id(&wr, CCWR_QP_MODIFY); wr.hdr.context = (unsigned l...
false
false
false
false
false
0
vPrintSpecialChar(diagram_type *pDiag, USHORT usChar) { ULONG ulChar; size_t tLen, tIndex; char szResult[4]; fail(pDiag == NULL); fail(pDiag->pOutFile == NULL); fail(iWordVersion < 0); fail(eEncoding == encoding_neutral); ulChar = ulTranslateCharacters(usChar, 0, iWordVersion, conversion_xml, eEncod...
false
false
false
false
false
0
gigaset_free_channels(struct cardstate *cs) { unsigned long flags; int i; gig_dbg(DEBUG_CHANNEL, "unblocking all channels"); spin_lock_irqsave(&cs->lock, flags); for (i = 0; i < cs->channels; ++i) --cs->bcs[i].use_count; spin_unlock_irqrestore(&cs->lock, flags); }
false
false
false
false
false
0
elf_identify(const void *memory, uint64_t size) { const uint8_t *p = memory; int class = 0; if (size <= EI_NIDENT || memcmp(p, ELFMAG, SELFMAG) != 0) return -ENOEXEC; switch (p[EI_CLASS]) { case ELFCLASS32: if (size <= sizeof(Elf32_Ehdr)) return -EINVAL; class |= KMOD_ELF_32; break; case ELFCLASS64: ...
false
false
false
false
false
0
gfs_client_replication_request_request(void *closure) { struct gfs_client_replication_request_arg *arg = closure; char *srchost = arg->srchost; gfarm_int32_t srcport = arg->srcport; struct host *dst = arg->dst; gfarm_ino_t ino = arg->ino; gfarm_int64_t gen = arg->gen; struct file_replicating *fr = arg->fr; stru...
false
false
false
false
false
0
pool_remove(void *arg) { pool_cell_t *p; p = memory_pool.head; if (!p) return; while (p) { if (p->value == arg) { if (p->prev) p->prev->next = p->next; if (p->next) p->next->prev = p->prev; if (p == memory_pool.head) memory_pool.head = p->next; if (...
false
false
false
false
false
0
nv_disable_hw_interrupts ( struct forcedeth_private *priv ) { void *ioaddr = priv->mmio_addr; writel ( 0, ioaddr + NvRegIrqMask ); pci_push ( ioaddr ); }
false
false
false
false
false
0
rtl_pci_check_buddy_priv(struct ieee80211_hw *hw, struct rtl_priv **buddy_priv) { struct rtl_priv *rtlpriv = rtl_priv(hw); struct rtl_pci_priv *pcipriv = rtl_pcipriv(hw); bool find_buddy_priv = false; struct rtl_priv *tpriv = NULL; struct rtl_pci_priv *tpcipriv = NULL; if (!list_empty(&rtlpriv->glb_var-...
false
false
false
true
false
1
CL_WriteDemoMessageFull( sizebuf_t *msg ) { int len, swlen; // the first eight bytes are just packet sequencing stuff len = msg->cursize - 8; swlen = LittleLong( len ); if(swlen > 0) // skip bad packets { FS_Write( &swlen, 4, cls.demofile); FS_Write( msg->data + 8, len, cls.demofile); } }
false
false
false
false
false
0
isSVD(struct iso9660 *iso9660, const unsigned char *h) { const unsigned char *p; ssize_t logical_block_size; int32_t volume_block; int32_t location; int i; (void)iso9660; /* UNUSED */ /* Type 2 means it's a SVD. */ if (h[SVD_type_offset] != 2) return (0); /* Reserved field must be 0. */ for (i = 0; i < S...
false
false
false
false
false
0
qpdf_force_pdf_version_and_extension( qpdf_data qpdf, char const* version, int extension_level) { QTC::TC("qpdf", "qpdf-c called qpdf_force_pdf_version"); qpdf->qpdf_writer->forcePDFVersion(version, extension_level); }
false
false
false
false
false
0
gsb_data_partial_balance_get_current_amount ( gint partial_balance_number ) { struct_partial_balance *partial_balance; gsb_real solde = null_real; gchar **tab; gint i; partial_balance = gsb_data_partial_balance_get_structure ( partial_balance_number ); if ( !partial_balance ) return nu...
false
false
false
false
false
0
reset (void) { if (!_table) return 1; inp_count = 0; out_count = 0; inp_data = 0; out_data = 0; _index = 0; _nread = 0; _nzero = 0; _phase = 0; if (_table) { _nread = 2 * _table->_hl; return 0; } return 1; }
false
false
false
false
false
0
closedown(uint32 err) { LOG(LS_INFO) << "State: TCP_CLOSED"; m_state = TCP_CLOSED; if (m_notify) { m_notify->OnTcpClosed(this, err); } //notify(evClose, err); }
false
false
false
false
false
0
vsl_IX_arg(const struct VSM_data *vd, const char *opt, int arg) { vre_t **rp; const char *error; int erroroffset; CHECK_OBJ_NOTNULL(vd, VSM_MAGIC); if (arg == 'I') rp = &vd->vsl->regincl; else rp = &vd->vsl->regexcl; if (*rp != NULL) { fprintf(stderr, "Option %c can only be given once", arg); return (-1...
false
false
false
false
false
0
fetch_opt_first(struct conf_sec *s, char *dfl, char *name) { struct conf_opt *o; if(!name) return opt_type_null; else if(s) { SLIST_FOREACH(o, &s->optlist, entry) if(!strcmp(o->name, name)) { o->used = true; ...
false
false
false
false
false
0
nextKeyFrame(framepos_t kf) const { if (kf >= size() || kf == ERR) return ERR; for (unsigned i = kf + 1; i < size(); ++i) if (operator[](i).IsKeyFrame()) return i; return ERR; }
false
false
false
false
false
0
lola_pcm_trigger(struct snd_pcm_substream *substream, int cmd) { struct lola *chip = snd_pcm_substream_chip(substream); struct lola_stream *str; struct snd_pcm_substream *s; unsigned int start; unsigned int tstamp; bool sync_streams; switch (cmd) { case SNDRV_PCM_TRIGGER_START: case SNDRV_PCM_TRIGGER_PAUSE_RE...
false
false
false
false
false
0
GetScriptLineNumberSafe(Handle<Script> script, int code_pos) { AssertNoAllocation no_allocation; if (!script->line_ends()->IsUndefined()) { return GetScriptLineNumber(script, code_pos); } // Slow mode: we do not have line_ends. We have to iterate through source. if (!script->source()->IsString()) { re...
false
false
false
false
false
0
Lookup_In_Dico_Var(char *name) { int i; Bool named; if (name[0] != '_' || name[1] != '\0') { named = TRUE; for (i = 0; i < parse_nb_var && strcmp(name, parse_dico_var[i].name) != 0; i++) ; } else { named = FALSE; i = parse_nb_var; } if (i == parse_nb_var) ...
false
false
false
false
false
0
vmw_cmd_begin_query(struct vmw_private *dev_priv, struct vmw_sw_context *sw_context, SVGA3dCmdHeader *header) { struct vmw_begin_query_cmd { SVGA3dCmdHeader header; SVGA3dCmdBeginQuery q; } *cmd; cmd = container_of(header, struct vmw_begin_query_cmd, header); if (unlikely(dev_priv->h...
false
false
false
false
false
0
reiserfs_cache_default_acl(struct inode *inode) { struct posix_acl *acl; int nblocks = 0; if (IS_PRIVATE(inode)) return 0; acl = reiserfs_get_acl(inode, ACL_TYPE_DEFAULT); if (acl && !IS_ERR(acl)) { int size = reiserfs_acl_size(acl->a_count); /* Other xattrs can be created during inode creation. We don't...
false
false
false
false
false
0
check_expand_timer (NautilusTreeViewDragDest *dest, GtkTreePath *drop_path, GtkTreePath *old_drop_path) { GtkTreeModel *model; GtkTreeIter drop_iter; model = gtk_tree_view_get_model (dest->details->tree_view); if (drop_path == NULL || (old_drop_path != NULL && gtk_tree_path_compare (old_drop_path...
false
false
false
false
false
0
mpfr_mulhigh_n (mpfr_limb_ptr rp, mpfr_limb_srcptr np, mpfr_limb_srcptr mp, mp_size_t n) { mp_size_t k; MPFR_ASSERTN (MPFR_MULHIGH_TAB_SIZE >= 8); /* so that 3*(n/4) > n/2 */ k = MPFR_LIKELY (n < MPFR_MULHIGH_TAB_SIZE) ? mulhigh_ktab[n] : 3*(n/4); /* Algorithm ShortMul from [1] requires k >= (n...
false
false
false
false
false
0
_glfwKeySym2Unicode(unsigned int keysym) { int min = 0; int max = sizeof(keysymtab) / sizeof(struct codepair) - 1; int mid; // First check for Latin-1 characters (1:1 mapping) if ((keysym >= 0x0020 && keysym <= 0x007e) || (keysym >= 0x00a0 && keysym <= 0x00ff)) { return keysym; ...
false
false
false
false
false
0
Highlight(int highlight) { this->Actor->SetProperty(highlight ? this->SelectedProperty : this->Property); }
false
false
false
false
false
0
GGadgetGetList(GGadget *g,int32 *len) { if ( g->funcs->get_list!=NULL ) return((g->funcs->get_list)(g,len)); if ( len!=NULL ) *len = 0; return( NULL ); }
false
false
false
false
false
0
compute_sa_collection(GthSACollection *sa_collection, GthCallInfo *call_info, GthInput *input, GthStat *stat, const GthPlugins *plugins) { GthChainCollection *chain_collection; GthMatc...
false
false
false
false
false
0
gg_svg_clone_path (struct gg_svg_path *in) { /* cloning an empty SVG Path */ struct gg_svg_path_move *move; struct gg_svg_path_bezier *bezier; struct gg_svg_path_ellipt_arc *arc; struct gg_svg_path_item *pp; struct gg_svg_path *p = malloc (sizeof (struct gg_svg_path)); p->first = NULL; p->la...
false
false
false
false
false
0
pca9532_gpio_request_pin(struct gpio_chip *gc, unsigned offset) { struct pca9532_data *data = container_of(gc, struct pca9532_data, gpio); struct pca9532_led *led = &data->leds[offset]; if (led->type == PCA9532_TYPE_GPIO) return 0; return -EBUSY; }
false
false
false
false
false
0
bufferevent_disable(struct bufferevent *bufev, short event) { int r = 0; BEV_LOCK(bufev); bufev->enabled &= ~event; if (bufev->be_ops->disable(bufev, event) < 0) r = -1; BEV_UNLOCK(bufev); return r; }
false
false
false
false
false
0
e_soap_message_reset (ESoapMessage *msg) { g_return_if_fail (E_IS_SOAP_MESSAGE (msg)); xmlFreeDoc (msg->priv->doc); msg->priv->doc = xmlNewDoc ((const xmlChar *) "1.0"); msg->priv->last_node = NULL; g_free (msg->priv->action); msg->priv->action = NULL; msg->priv->body_started = FALSE; if (msg->priv->env_uri ...
false
false
false
false
false
0