idx int64 | func string | target int64 |
|---|---|---|
83,816 | ssize_t xdr_stream_decode_opaque(struct xdr_stream *xdr, void *ptr, size_t size)
{
ssize_t ret;
void *p;
ret = xdr_stream_decode_opaque_inline(xdr, &p, size);
if (ret <= 0)
return ret;
memcpy(ptr, p, ret);
return ret;
} | 0 |
353,344 | dtls1_get_message_fragment(SSL *s, int st1, int stn, long max, int *ok)
{
unsigned char wire[DTLS1_HM_HEADER_LENGTH];
unsigned long len, frag_off, frag_len;
int i,al;
struct hm_header_st msg_hdr;
/* see if we have the required fragment already */
if ((frag_len = dtls1_retrieve_buffered_fragment(s,max,ok)) || *o... | 1 |
80,531 | int is_logbook(char *logbook) {
char str[256];
if (strieq(logbook, "global"))
return 0;
/* check for 'global group' or 'global_xxx' */
strlcpy(str, logbook, sizeof(str));
str[7] = 0;
return !strieq(str, "global ");
} | 0 |
157,316 | void OSDService::shutdown()
{
{
Mutex::Locker l(watch_lock);
watch_timer.shutdown();
}
objecter->shutdown();
objecter_finisher.wait_for_empty();
objecter_finisher.stop();
{
Mutex::Locker l(recovery_request_lock);
recovery_request_timer.shutdown();
}
{
Mutex::Locker l(snap_sleep_lo... | 0 |
319,474 | static int v9fs_synth_utimensat(FsContext *fs_ctx, V9fsPath *path,
const struct timespec *buf)
{
errno = EPERM;
return 0;
}
| 0 |
161,395 | cockpit_auth_check_cookie (CockpitAuth *self,
const gchar *path,
GHashTable *in_headers)
{
CockpitSession *session;
CockpitCreds *creds;
session = session_for_headers (self, path, in_headers);
if (session)
{
creds = cockpit_web_service_get_creds (... | 0 |
49,432 | static int vma_has_reserves(struct vm_area_struct *vma)
{
if (vma->vm_flags & VM_MAYSHARE)
return 1;
if (is_vma_resv_set(vma, HPAGE_RESV_OWNER))
return 1;
return 0;
} | 0 |
168,955 | static MagickBooleanType ReadPSDChannel(Image *image,
const ImageInfo *image_info,const PSDInfo *psd_info,LayerInfo* layer_info,
const size_t channel,const PSDCompressionType compression,
ExceptionInfo *exception)
{
Image
*channel_image,
*mask;
MagickOffsetType
offset;
MagickBooleanType
st... | 0 |
137,820 | static int mov_metadata_int8_bypass_padding(MOVContext *c, AVIOContext *pb,
unsigned len, const char *key)
{
/* bypass padding bytes */
avio_r8(pb);
avio_r8(pb);
avio_r8(pb);
c->fc->event_flags |= AVFMT_EVENT_FLAG_METADATA_UPDATED;
av_dict_set_int(&c-... | 0 |
25,552 | IN_PROC_BROWSER_TEST_F ( UnloadTest , BrowserListDoubleCloseBeforeUnloadCancel ) {
NavigateToDataURL ( BEFORE_UNLOAD_HTML , "beforeunload" ) ;
UnloadResults unload_results ;
BrowserList : : CloseAllBrowsersWithProfile ( browser ( ) -> profile ( ) , base : : Bind ( & UnloadResults : : AddSuccess , base : : Unretained... | 0 |
108,934 | CModule::EModRet CModule::OnChanBufferPlayLine(CChan& Chan, CClient& Client,
CString& sLine) {
return CONTINUE;
} | 0 |
201,247 | void StartAnimation() {
animation_timer_.Start(FROM_HERE,
base::TimeDelta::FromMilliseconds(
base::TimeTicks::kMillisecondsPerSecond /
gfx::LinearAnimation::kDefaultFrameRate),
this, &VoiceInteract... | 0 |
393,955 | static inline void check_class_changed(struct rq *rq, struct task_struct *p,
const struct sched_class *prev_class,
int oldprio)
{
if (prev_class != p->sched_class) {
if (prev_class->switched_from)
prev_class->switched_from(rq, p);
p->sched_class->switched_to(rq, p);
} else if (oldprio !=... | 0 |
698 | unsigned long # define BN_LONG long # define BN_BITS 128 # define BN_BYTES 8 # define BN_BITS2 64 # define BN_BITS4 32 # define BN_MASK ( 0xffffffffffffffffffffffffffffffffLL ) # define BN_MASK2 ( 0xffffffffffffffffL ) # define BN_MASK2l ( 0xffffffffL ) # define BN_MASK2h ( 0xffffffff00000000L ) # define BN_MASK2h1 ( 0... | 1 |
302,618 | QInt16() : value(0) {} | 0 |
395,303 | int TC_LOG_BINLOG::open(const char *opt_name)
{
LOG_INFO log_info;
int error= 1;
DBUG_ASSERT(total_ha_2pc > 1);
DBUG_ASSERT(opt_name && opt_name[0]);
mysql_mutex_init(key_BINLOG_LOCK_prep_xids,
&LOCK_prep_xids, MY_MUTEX_INIT_FAST);
mysql_cond_init(key_BINLOG_COND_prep_xids, &COND_p... | 0 |
226,698 | static String capitalizeRFC822HeaderFieldName(const String& name)
{
bool capitalizeCharacter = true;
String result;
for (unsigned i = 0; i < name.length(); i++) {
UChar c;
if (capitalizeCharacter && name[i] >= 'a' && name[i] <= 'z')
c = toASCIIUpper(name[i]);
else if (!... | 0 |
90,960 | static int double_lock_balance(struct rq *this_rq, struct rq *busiest)
{
if (unlikely(!irqs_disabled())) {
/* printk() doesn't work good under rq->lock */
raw_spin_unlock(&this_rq->lock);
BUG_ON(1);
}
return _double_lock_balance(this_rq, busiest);
} | 0 |
367,309 | update_pal_halt_status(int status)
{
can_do_pal_halt = pal_halt && status;
} | 0 |
506,451 | static int sk_comp_cmp(const SSL_COMP * const *a,
const SSL_COMP * const *b)
{
return((*a)->id-(*b)->id);
} | 0 |
71,740 | void KaxInternalBlock::ReleaseFrames()
{
// free the allocated Frames
int i;
for (i=myBuffers.size()-1; i>=0; i--) {
if (myBuffers[i] != NULL) {
myBuffers[i]->FreeBuffer(*myBuffers[i]);
delete myBuffers[i];
myBuffers[i] = NULL;
}
}
} | 0 |
52,423 | R_API void r_bin_java_print_constant_value_attr_summary(RBinJavaAttrInfo *attr) {
if (!attr) {
eprintf ("Attempting to print an invalid RBinJavaAttrInfo *ConstantValue.\n");
return;
}
printf ("Constant Value Attribute Information:\n");
printf (" Attribute Offset: 0x%08"PFMT64x "\n", attr->file_offset);
printf... | 0 |
296,853 | int Jsi_Remove(Jsi_Interp *interp, Jsi_Value* path, int flags) {
void *data;
Jsi_Filesystem *fsPtr = Jsi_FilesystemForPath(interp, path, &data);
if (fsPtr == NULL || !fsPtr->removeProc) return -1;
return fsPtr->removeProc(interp, path, flags);
} | 0 |
248,029 | static int rgbbasecolor(i_ctx_t * i_ctx_p, ref *space, int base, int *stage, int *cont, int *stack_depth)
{
os_ptr op = osp;
float RGB[3], CMYK[4], Gray, UCR, BG;
int i;
const gs_color_space * pcs = gs_currentcolorspace(igs);
if (pcs->id == cs_DeviceGray_id) {
/* UGLY hack. Its possible fo... | 0 |
470,468 | copyin_file (struct cpio_file_stat *file_hdr, int in_file_des)
{
bool existing_dir = false;
if (!to_stdout_option
&& try_existing_file (file_hdr, in_file_des, &existing_dir) < 0)
return;
/* Do the real copy or link. */
switch (file_hdr->c_mode & CP_IFMT)
{
case CP_IFREG:
copyin_regula... | 0 |
140,579 | TEST_P(JSITest, ArrayTest) {
eval("x = {1:2, '3':4, 5:'six', 'seven':['eight', 'nine']}");
Object x = rt.global().getPropertyAsObject(rt, "x");
Array names = x.getPropertyNames(rt);
EXPECT_EQ(names.size(rt), 4);
std::unordered_set<std::string> strNames;
for (size_t i = 0; i < names.size(rt); ++i) {
Val... | 0 |
25,165 | static void pk_proxy_appeared_cb ( GObject * source , GAsyncResult * res , gpointer user_data ) {
ActivateParametersInstall * parameters_install = user_data ;
char * mime_type , * name_owner ;
char * error_message ;
GtkWidget * dialog ;
GDBusProxy * proxy ;
GError * error = NULL ;
proxy = g_dbus_proxy_new_for_bu... | 0 |
305,845 | GF_Err gf_isom_end_hint_sample(GF_ISOFile *the_file, u32 trackNumber, u8 IsRandomAccessPoint)
{
GF_TrackBox *trak;
GF_HintSampleEntryBox *entry;
u32 dataRefIndex;
GF_Err e;
GF_BitStream *bs;
GF_ISOSample *samp;
trak = gf_isom_get_track_from_file(the_file, trackNumber);
if (!trak || !IsHintTrack(trak)) return G... | 0 |
504,788 | _rsvg_node_text_length_tref (RsvgNodeTref * self, RsvgDrawingCtx * ctx, gdouble * x,
gboolean * lastwasspace)
{
if (self->link)
return _rsvg_node_text_length_children (self->link, ctx, x, lastwasspace);
return FALSE;
} | 0 |
490,103 | static coolkey_private_data_t *coolkey_new_private_data(void)
{
coolkey_private_data_t *priv;
/* allocate priv and zero all the fields */
priv = calloc(1, sizeof(coolkey_private_data_t));
if (!priv)
return NULL;
/* set other fields as appropriate */
priv->key_id = COOLKEY_INVALID_KEY;
list_init(&priv->objects_... | 0 |
147,388 | static int xts_aesni_setkey(struct crypto_tfm *tfm, const u8 *key,
unsigned int keylen)
{
struct aesni_xts_ctx *ctx = crypto_tfm_ctx(tfm);
u32 *flags = &tfm->crt_flags;
int err;
/* key consists of keys of equal size concatenated, therefore
* the length must be even
*/
if (keylen % 2) {
*flags |= CRYP... | 0 |
507,242 | static void s_server_init(void)
{
accept_socket=-1;
cipher=NULL;
s_server_verify=SSL_VERIFY_NONE;
s_dcert_file=NULL;
s_dkey_file=NULL;
s_dchain_file=NULL;
s_cert_file=TEST_CERT;
s_key_file=NULL;
s_chain_file=NULL;
#ifndef OPENSSL_NO_TLSEXT
curves=NULL;
s_cert_file2=TEST_CERT2;
s_key_file2=NULL;
ctx2=NULL;... | 0 |
219,602 | void AudioSource::trackMaxAmplitude(int16_t *data, int nSamples) {
for (int i = nSamples; i > 0; --i) {
int16_t value = *data++;
if (value < 0) {
value = -value;
}
if (mMaxAmplitude < value) {
mMaxAmplitude = value;
}
}
}
| 0 |
175,022 | void MimeHandlerViewContainer::DidReceiveData(const char* data,
int data_length) {
view_id_ += std::string(data, data_length);
}
| 0 |
140,271 | static int udf_read_extent_cache(struct inode *inode, loff_t bcount,
loff_t *lbcount, struct extent_position *pos)
{
struct udf_inode_info *iinfo = UDF_I(inode);
int ret = 0;
spin_lock(&iinfo->i_extent_cache_lock);
if ((iinfo->cached_extent.lstart <= bcount) &&
(iinfo->cached_extent.lstart != -1)) {
/*... | 0 |
104,517 | static const char *columnTypeImpl(
NameContext *pNC,
#ifndef SQLITE_ENABLE_COLUMN_METADATA
Expr *pExpr
#else
Expr *pExpr,
const char **pzOrigDb,
const char **pzOrigTab,
const char **pzOrigCol
#endif
){
char const *zType = 0;
int j;
#ifdef SQLITE_ENABLE_COLUMN_METADATA
char const *zOrigDb = 0;
char ... | 0 |
483,557 | bool kill_device(struct device *dev)
{
/*
* Require the device lock and set the "dead" flag to guarantee that
* the update behavior is consistent with the other bitfields near
* it and that we cannot have an asynchronous probe routine trying
* to run while we are tearing out the bus/class/sysfs from
* undern... | 0 |
353,414 | dtls1_process_out_of_seq_message(SSL *s, struct hm_header_st* msg_hdr, int *ok)
{
int i=-1;
hm_fragment *frag = NULL;
pitem *item = NULL;
unsigned char seq64be[8];
unsigned long frag_len = msg_hdr->frag_len;
if ((msg_hdr->frag_off+frag_len) > msg_hdr->msg_len)
goto err;
/* Try to find item in queue, to preve... | 1 |
122,109 | static int mov_open_dref(MOVContext *c, AVIOContext **pb, const char *src, MOVDref *ref,
AVIOInterruptCB *int_cb)
{
AVOpenCallback open_func = c->fc->open_cb;
if (!open_func)
open_func = ffio_open2_wrapper;
/* try relative path, we do not try the absolute because i... | 0 |
200,673 | ModuleExport size_t RegisterPSImage(void)
{
MagickInfo
*entry;
entry=AcquireMagickInfo("PS","EPI",
"Encapsulated PostScript Interchange format");
entry->decoder=(DecodeImageHandler *) ReadPSImage;
entry->encoder=(EncodeImageHandler *) WritePSImage;
entry->magick=(IsImageFormatHandler *) IsPS;
entry... | 0 |
485,216 | DEFUN (clear_ip_bgp_all_ipv4_soft,
clear_ip_bgp_all_ipv4_soft_cmd,
"clear ip bgp * ipv4 (unicast|multicast) soft",
CLEAR_STR
IP_STR
BGP_STR
"Clear all peers\n"
"Address family\n"
"Address Family Modifier\n"
"Address Family Modifier\n"
"Soft reconfig\... | 0 |
76,477 | DNSRecordContent* DNSRecordContent::mastermake(uint16_t qtype, uint16_t qclass,
const string& content)
{
zmakermap_t::const_iterator i=getZmakermap().find(make_pair(qclass, qtype));
if(i==getZmakermap().end()) {
return new UnknownRecordContent(content);
}
retu... | 0 |
431,645 | BSONArray roleSetToBSONArray(const unordered_set<RoleName>& roles) {
BSONArrayBuilder rolesArrayBuilder;
for (unordered_set<RoleName>::const_iterator it = roles.begin(); it != roles.end(); ++it) {
const RoleName& role = *it;
rolesArrayBuilder.append(BSON(AuthorizationManager::ROLE_NAME_FIELD_NAM... | 0 |
503,121 | connection_handle_read_body_unknown (request_st * const r, chunkqueue * const cq, chunkqueue * const dst_cq)
{
/* r->conf.max_request_size is in kBytes */
const off_t max_request_size = (off_t)r->conf.max_request_size << 10;
chunkqueue_append_chunkqueue(dst_cq, cq);
if (0 != max_request_size && dst_cq->... | 0 |
94,026 | static void hci_req_clear_event_filter(struct hci_request *req)
{
struct hci_cp_set_event_filter f;
memset(&f, 0, sizeof(f));
f.flt_type = HCI_FLT_CLEAR_ALL;
hci_req_add(req, HCI_OP_SET_EVENT_FLT, 1, &f);
/* Update page scan state (since we may have modified it when setting
* the event filter).
*/
__hci_req... | 0 |
510,604 | my_decimal *Item_copy_string::val_decimal(my_decimal *decimal_value)
{
// Item_copy_string is used without fix_fields call
if (null_value)
return (my_decimal *) 0;
string2my_decimal(E_DEC_FATAL_ERROR, &str_value, decimal_value);
return (decimal_value);
} | 0 |
78,247 | setSanMatchers(std::vector<envoy::extensions::transport_sockets::tls::v3::SubjectAltNameMatcher>
san_matchers) {
san_matchers_ = san_matchers;
return *this;
} | 0 |
168,204 | static void limitedWithMissingDefaultAttributeAttributeGetter(const v8::PropertyCallbackInfo<v8::Value>& info)
{
TestObject* imp = V8TestObject::toNative(info.Holder());
String resultValue = imp->fastGetAttribute(HTMLNames::limitedwithmissingdefaultattributeAttr);
if (resultValue.isEmpty()) {
result... | 0 |
467,479 | j2k_error(const char *msg, void *client_data) {
JPEG2KDECODESTATE *state = (JPEG2KDECODESTATE *)client_data;
free((void *)state->error_msg);
state->error_msg = strdup(msg);
} | 0 |
387,972 | png_inflate_read(png_structrp png_ptr, png_bytep read_buffer, uInt read_size,
png_uint_32p chunk_bytes, png_bytep next_out, png_alloc_size_t *out_size,
int finish)
{
if (png_ptr->zowner == png_ptr->chunk_name)
{
int ret;
/* next_in and avail_in must have been initialized by the caller. */
... | 0 |
341,943 | static void ppc_hash64_set_isi(CPUState *cs, CPUPPCState *env,
uint64_t error_code)
{
bool vpm;
if (msr_ir) {
vpm = !!(env->spr[SPR_LPCR] & LPCR_VPM1);
} else {
vpm = !!(env->spr[SPR_LPCR] & LPCR_VPM0);
}
if (vpm && !msr_hv) {
cs->ex... | 0 |
14,415 | z2grestore(i_ctx_t *i_ctx_p)
{
if (!restore_page_device(igs, gs_gstate_saved(igs)))
return gs_grestore(igs);
return push_callout(i_ctx_p, "%grestorepagedevice");
}
| 1 |
61,147 | static int spawn_next_command_in_evd(struct analyze_event_data *evd)
{
evd->env_list = export_event_config(evd->event_name);
int r = spawn_next_command(evd->run_state, g_dump_dir_name, evd->event_name, EXECFLG_SETPGID);
if (r >= 0)
{
g_event_child_pid = evd->run_state->command_pid;
}
els... | 0 |
343,403 | static void cirrus_do_copy(CirrusVGAState *s, int dst, int src, int w, int h)
{
int sx, sy;
int dx, dy;
int width, height;
int depth;
int notify = 0;
depth = s->get_bpp((VGAState *)s) / 8;
s->get_resolution((VGAState *)s, &width, &height);
/* extra x, y */
sx = (src % (width * dept... | 1 |
275,291 | RenderViewZoomer(const GURL& url, double zoom_level)
: zoom_level_(zoom_level) {
host_ = net::GetHostOrSpecFromURL(url);
}
| 0 |
412,213 | static int ext4_xattr_inode_write(handle_t *handle, struct inode *ea_inode,
const void *buf, int bufsize)
{
struct buffer_head *bh = NULL;
unsigned long block = 0;
int blocksize = ea_inode->i_sb->s_blocksize;
int max_blocks = (bufsize + blocksize - 1) >> ea_inode->i_blkbits;
int csize, wsize = 0;
int ret = ... | 0 |
186,678 | void RenderFrameHostImpl::DidReceiveFirstUserActivation() {
delegate_->DidReceiveFirstUserActivation(this);
}
| 0 |
496,073 | is_nfs4_flags_w(const wchar_t *start, const wchar_t *end, int *permset)
{
const wchar_t *p = start;
while (p < end) {
switch(*p++) {
case L'f':
*permset |= ARCHIVE_ENTRY_ACL_ENTRY_FILE_INHERIT;
break;
case L'd':
*permset |= ARCHIVE_ENTRY_ACL_ENTRY_DIRECTORY_INHERIT;
break;
case L'i':
*permset ... | 0 |
257,832 | void vp9_init_dsmotion_compensation ( search_site_config * cfg , int stride ) {
int len , ss_count = 1 ;
cfg -> ss [ 0 ] . mv . col = cfg -> ss [ 0 ] . mv . row = 0 ;
cfg -> ss [ 0 ] . offset = 0 ;
for ( len = MAX_FIRST_STEP ;
len > 0 ;
len /= 2 ) {
const MV ss_mvs [ ] = {
{
- len , 0 }
, {
len , 0 }
, {
0... | 0 |
370,462 | int apply_filters_to_request(struct session *s, struct channel *req, struct proxy *px)
{
struct http_txn *txn = &s->txn;
struct hdr_exp *exp;
for (exp = px->req_exp; exp; exp = exp->next) {
int ret;
/*
* The interleaving of transformations and verdicts
* makes it difficult to decide to continue or stop
... | 0 |
252,058 | void PrintPreviewDialogController::RemoveInitiator(
WebContents* initiator) {
WebContents* preview_dialog = GetPrintPreviewForContents(initiator);
DCHECK(preview_dialog);
preview_dialog_map_[preview_dialog] = nullptr;
RemoveObservers(initiator);
PrintViewManager::FromWebContents(initiator)->PrintPreviewD... | 0 |
199,421 | static void GrowCapacityAndConvertImpl(Handle<JSObject> object,
uint32_t capacity) {
Handle<FixedArray> parameter_map(FixedArray::cast(object->elements()));
Handle<FixedArray> old_elements(FixedArray::cast(parameter_map->get(1)));
ElementsKind from_kind = object->GetElementsKind();
DCHECK(from_kind == SLOW_SLO... | 0 |
265,191 | int tcp_filter(struct sock *sk, struct sk_buff *skb)
{
struct tcphdr *th = (struct tcphdr *)skb->data;
unsigned int eaten = skb->len;
int err;
err = sk_filter_trim_cap(sk, skb, th->doff * 4);
if (!err) {
eaten -= skb->len;
TCP_SKB_CB(skb)->end_seq -= eaten;
}
return err;
} | 0 |
383,530 | void precompute_partition_info_escapes_(
const FLAC__int32 residual[],
unsigned raw_bits_per_partition[],
unsigned residual_samples,
unsigned predictor_order,
unsigned min_partition_order,
unsigned max_partition_order
)
{
int partition_order;
unsigned from_partition, to_partition = 0;
const unsigned blocksize ... | 0 |
481,120 | static bool kvm_zap_rmapp(struct kvm *kvm, struct kvm_rmap_head *rmap_head,
const struct kvm_memory_slot *slot)
{
return pte_list_destroy(kvm, rmap_head);
} | 0 |
2,282 | process_open(u_int32_t id)
{
u_int32_t pflags;
Attrib a;
char *name;
int r, handle, fd, flags, mode, status = SSH2_FX_FAILURE;
if ((r = sshbuf_get_cstring(iqueue, &name, NULL)) != 0 ||
(r = sshbuf_get_u32(iqueue, &pflags)) != 0 || /* portable flags */
(r = decode_attrib(iqueue, &a)) != 0)
fatal("%s: b... | 1 |
23,012 | static const char * hfinfo_number_value_format64 ( const header_field_info * hfinfo , char buf [ 64 ] , guint64 value ) {
int display = hfinfo -> display ;
if ( hfinfo -> type == FT_FRAMENUM ) {
display = BASE_DEC ;
}
return hfinfo_number_value_format_display64 ( hfinfo , display , buf , value ) ;
} | 0 |
393,460 | parse_list(xmlChar *str) {
xmlChar **buffer;
xmlChar **out = NULL;
int buffer_size = 0;
int len;
if(str == NULL) {
return(NULL);
}
len = xmlStrlen(str);
if((str[0] == '\'') && (str[len - 1] == '\'')) {
str[len - 1] = '\0';
str++;
}
/*
* allocate an translation buffer.
... | 0 |
339,539 | static int mov_read_stsc(MOVContext *c, AVIOContext *pb, MOVAtom atom)
{
AVStream *st;
MOVStreamContext *sc;
unsigned int i, entries;
if (c->fc->nb_streams < 1)
return 0;
st = c->fc->streams[c->fc->nb_streams-1];
sc = st->priv_data;
avio_r8(pb); /* version */
avio_r... | 0 |
40,386 | make_etype_info2_entry(ETYPE_INFO2_ENTRY *ent, Key *key)
{
krb5_error_code ret;
ent->etype = key->key.keytype;
if(key->salt) {
ALLOC(ent->salt);
if (ent->salt == NULL)
return ENOMEM;
*ent->salt = malloc(key->salt->salt.length + 1);
if (*ent->salt == NULL) {
free(ent->salt);
ent->salt = N... | 0 |
430,548 | static struct istream *quoted_string_istream_create
(struct managesieve_parser *parser)
{
struct quoted_string_istream *qsstream;
qsstream = i_new(struct quoted_string_istream, 1);
qsstream->istream.max_buffer_size =
parser->input->real_stream->max_buffer_size;
qsstream->istream.read = quoted_string_istream_read... | 0 |
56,057 | filepos_t EbmlElement::MakeRenderHead(IOCallback & output, bool bKeepPosition)
{
binary FinalHead[4+8]; // Class D + 64 bits coded size
unsigned int FinalHeadSize;
FinalHeadSize = EBML_ID_LENGTH((const EbmlId&)*this);
EbmlId(*this).Fill(FinalHead);
int CodedSize = CodedSizeLength(Size, SizeLength, bSizeIsFi... | 0 |
81,548 | static inline void SetPixelGray(const Image *restrict image,const Quantum gray,
Quantum *restrict pixel)
{
pixel[image->channel_map[GrayPixelChannel].offset]=gray;
} | 0 |
84,233 | static void *cgm_init(const char *name)
{
struct cgm_data *d;
if (!cgm_dbus_connect()) {
ERROR("Error connecting to cgroup manager");
return NULL;
}
check_supports_multiple_controllers(-1);
d = malloc(sizeof(*d));
if (!d) {
cgm_dbus_disconnect();
return NULL;
}
memset(d, 0, sizeof(*d));
d->name = s... | 0 |
468,263 | llsec_dev_find_long(struct mac802154_llsec *sec, __le64 hwaddr)
{
struct mac802154_llsec_device *dev;
u64 key = llsec_dev_hash_long(hwaddr);
hash_for_each_possible_rcu(sec->devices_hw, dev, bucket_hw, key) {
if (dev->dev.hwaddr == hwaddr)
return dev;
}
return NULL;
} | 0 |
103,369 | static int sctp_connect(struct sock *sk, struct sockaddr *addr,
int addr_len)
{
int err = 0;
struct sctp_af *af;
lock_sock(sk);
pr_debug("%s: sk:%p, sockaddr:%p, addr_len:%d\n", __func__, sk,
addr, addr_len);
/* Validate addr_len before calling common connect/connectx routine. */
af = sctp_get_af_specifi... | 0 |
490,809 | read_2007_section_appinfohistory (Bit_Chain *restrict dat, Dwg_Data *restrict dwg,
r2007_section *restrict sections_map,
r2007_page *restrict pages_map)
{
Bit_Chain old_dat, sec_dat = { 0 };
//Bit_Chain *str_dat;
Dwg_AppInfoHistory *_obj = &dwg->... | 0 |
349,922 | absl::string_view hostAndPort() const { return host_and_port_; } | 1 |
329,882 | static int ast_read_packet(AVFormatContext *s, AVPacket *pkt)
{
uint32_t type, size;
int64_t pos;
int ret;
if (avio_feof(s->pb))
return AVERROR_EOF;
pos = avio_tell(s->pb);
type = avio_rl32(s->pb);
size = avio_rb32(s->pb);
if (size > INT_MAX / s->streams[0]->codecp... | 1 |
181,808 | RenderWidgetHostImpl::RenderWidgetHostImpl(RenderWidgetHostDelegate* delegate,
RenderProcessHost* process,
int routing_id)
: view_(NULL),
renderer_initialized_(false),
hung_renderer_delay_ms_(kHungRendererDelayMs),
... | 0 |
63,319 | void testCompareRangeHelper(const char * a, const char * b, int expected, bool avoidNullRange = true) {
UriTextRangeA ra;
UriTextRangeA rb;
if (a) {
ra.first = a;
ra.afterLast = a + strlen(a);
} else {
ra.first = NULL;
ra.afterLast = NULL;
}
if (b) {
rb.first = b;
rb.afterLast = b + str... | 0 |
53,437 | GF_Err iinf_box_size(GF_Box *s)
{
u32 pos=0;
GF_ItemInfoBox *ptr = (GF_ItemInfoBox *)s;
if (!s) return GF_BAD_PARAM;
ptr->size += (ptr->version == 0) ? 2 : 4;
gf_isom_check_position_list(s, ptr->item_infos, &pos);
return GF_OK;
} | 0 |
240,496 | inline bool SearchBuffer::isBadMatch(const UChar* match, size_t matchLength) const
{
if (!m_targetRequiresKanaWorkaround)
return false;
normalizeCharacters(match, matchLength, m_normalizedMatch);
const UChar* a = m_normalizedTarget.begin();
const UChar* aEnd = m_normalizedTarget.end();
co... | 0 |
32,078 | static int opdec(RAsm *a, ut8 *data, const Opcode *op) {
if (op->operands[1].type) {
eprintf ("Error: Invalid operands\n");
return -1;
}
int l = 0;
int size = op->operands[0].type & ALL_SIZE;
if (op->operands[0].explicit_size) {
size = op->operands[0].dest_size;
}
if (size & OT_WORD) {
data[l++] = 0x66;... | 0 |
463,599 |
static int io_poll_cancel(struct io_ring_ctx *ctx, __u64 sqe_addr)
{
struct hlist_head *list;
struct io_kiocb *req;
list = &ctx->cancel_hash[hash_long(sqe_addr, ctx->cancel_hash_bits)];
hlist_for_each_entry(req, list, hash_node) {
if (sqe_addr != req->user_data)
continue;
if (io_poll_remove_one(req))
re... | 0 |
42,823 | XMLReader::XMLReader() : m_ptr(nullptr), m_input(nullptr), m_schema(nullptr) {
} | 0 |
443,748 | static unsigned int selinux_ip_postroute(struct sk_buff *skb,
const struct net_device *outdev,
u16 family)
{
u32 secmark_perm;
u32 peer_sid;
int ifindex = outdev->ifindex;
struct sock *sk;
struct common_audit_data ad;
struct lsm_network_audit net = {0,};
char *addrp;
u8 secmark_active;
u8 peerlbl_a... | 0 |
111,695 | TEST(CombineHashes, TestHashOutputsDifferent) {
size_t output1 = CombineHashes({1, 2, 3, 4});
size_t output2 = CombineHashes({1, 2, 2, 4});
EXPECT_NE(output1, output2);
} | 0 |
268,166 | ex_scriptencoding(exarg_T *eap)
{
source_cookie_T *sp;
char_u *name;
if (!sourcing_a_script(eap))
{
emsg(_(e_scriptencoding_used_outside_of_sourced_file));
return;
}
if (*eap->arg != NUL)
{
name = enc_canonize(eap->arg);
if (name == NULL) // out of memory
return;
}
else
... | 0 |
288,424 | void TSMimeParserClear ( TSMimeParser parser ) {
sdk_assert ( sdk_sanity_check_mime_parser ( parser ) == TS_SUCCESS ) ;
mime_parser_clear ( ( MIMEParser * ) parser ) ;
} | 0 |
387,997 | xmlDictCreate(void) {
xmlDictPtr dict;
if (!xmlDictInitialized)
if (!__xmlInitializeDict())
return(NULL);
#ifdef DICT_DEBUG_PATTERNS
fprintf(stderr, "C");
#endif
dict = xmlMalloc(sizeof(xmlDict));
if (dict) {
dict->ref_counter = 1;
dict->limit = 0;
dic... | 0 |
128,110 | IMAP_DATA* imap_conn_find (const ACCOUNT* account, int flags)
{
CONNECTION* conn = NULL;
ACCOUNT* creds = NULL;
IMAP_DATA* idata = NULL;
int new = 0;
while ((conn = mutt_conn_find (conn, account)))
{
if (!creds)
creds = &conn->account;
else
memcpy (&conn->account, creds, sizeof (ACCOUNT... | 0 |
523,558 | void SELECT_LEX::mark_const_derived(bool empty)
{
TABLE_LIST *derived= master_unit()->derived;
/* join == NULL in DELETE ... RETURNING */
if (!(join && join->thd->lex->describe) && derived)
{
if (!empty)
increase_derived_records(1);
if (!master_unit()->is_unit_op() && !derived->is_merged_derived(... | 0 |
100,943 | static void gluster_cache_refresh(glfs_t *fs, const char *cfgstring)
{
struct gluster_cacheconn **entry;
char** config;
size_t i = 0;
size_t j = 0;
if (!fs)
return;
darray_foreach(entry, cache) {
if ((*entry)->fs == fs) {
if (cfgstring) {
darray_foreach(config, (*entry)->cfgstring) {
if (!strcmp... | 0 |
500,670 | static int cfg_print_pff_indent(cfg_t *cfg, FILE *fp,
cfg_print_filter_func_t fb_pff, int indent)
{
int i, result = CFG_SUCCESS;
for (i = 0; cfg->opts[i].name; i++) {
cfg_print_filter_func_t pff = cfg->pff ? cfg->pff : fb_pff;
if (pff && pff(cfg, &cfg->opts[i]))
continue;
result += cfg_opt_print_pff_ind... | 0 |
89,702 | qemuProcessHandleNicRxFilterChanged(qemuMonitorPtr mon G_GNUC_UNUSED,
virDomainObjPtr vm,
const char *devAlias,
void *opaque)
{
virQEMUDriverPtr driver = opaque;
struct qemuProcessEvent *processEvent = NU... | 0 |
331,896 | static int assigned_device_pci_cap_init(PCIDevice *pci_dev, Error **errp)
{
AssignedDevice *dev = PCI_ASSIGN(pci_dev);
PCIRegion *pci_region = dev->real_device.regions;
int ret, pos;
/* Clear initial capabilities pointer and status copied from hw */
pci_set_byte(pci_dev->config + PCI_CAPABIL... | 0 |
240,405 | void OnIceCandidateImpl(const std::string& sdp, const std::string& sdp_mid,
int sdp_mline_index, int component, int address_family) {
DCHECK(main_thread_->BelongsToCurrentThread());
if (handler_) {
handler_->OnIceCandidate(sdp, sdp_mid, sdp_mline_index, component,
address_family);
}
... | 0 |
161,866 | gboolean
mono_verifier_is_enabled_for_class (MonoClass *klass)
{
return verify_all || (verifier_mode > MONO_VERIFIER_MODE_OFF && !klass->image->assembly->in_gac && klass->image != mono_defaults.corlib); | 0 |
105,689 | XML_SetBase(XML_Parser parser, const XML_Char *p) {
if (parser == NULL)
return XML_STATUS_ERROR;
if (p) {
p = poolCopyString(&parser->m_dtd->pool, p);
if (! p)
return XML_STATUS_ERROR;
parser->m_curBase = p;
} else
parser->m_curBase = NULL;
return XML_STATUS_OK;
} | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.