idx int64 | func string | target int64 |
|---|---|---|
368,774 | _compare_pairs(const void **a, const void **b)
{
const fp_pair_t *fp1 = *a, *fp2 = *b;
int r;
if ((r = fast_memcmp(fp1->first, fp2->first, DIGEST_LEN)))
return r;
else
return fast_memcmp(fp1->second, fp2->second, DIGEST_LEN);
} | 0 |
493,887 | checkprotoprefix(struct Curl_easy *data, struct connectdata *conn,
const char *s, size_t len)
{
#ifndef CURL_DISABLE_RTSP
if(conn->handler->protocol & CURLPROTO_RTSP)
return checkrtspprefix(data, s, len);
#else
(void)conn;
#endif /* CURL_DISABLE_RTSP */
return checkhttpprefix(data, s, len);
... | 0 |
240,105 | void CompareDrawQuad(DrawQuad* quad,
DrawQuad* copy,
SharedQuadState* copy_shared_state) {
EXPECT_EQ(quad->material, copy->material);
EXPECT_EQ(quad->rect, copy->rect);
EXPECT_EQ(quad->visible_rect, copy->visible_rect);
EXPECT_EQ(quad->opaque_rect, copy->opaque_rect);
... | 0 |
429,203 | job_handler_callback (gpointer data,
gpointer user_data)
{
GVfsJob *job = G_VFS_JOB (data);
g_vfs_job_run (job);
} | 0 |
378,985 | static int local_LZ4_decompress_fast_withPrefix64k(const char* in, char* out, int inSize, int outSize)
{
(void)inSize;
LZ4_decompress_fast_withPrefix64k(in, out, outSize);
return outSize;
} | 0 |
262,230 | cherokee_validator_ldap_add_headers (cherokee_validator_ldap_t *ldap, cherokee_connection_t *conn, cherokee_buffer_t *buf)
{
UNUSED(ldap);
UNUSED(conn);
UNUSED(buf);
return ret_ok;
} | 0 |
168,590 | static int kvm_init_mmu_notifier(struct kvm *kvm)
{
return 0;
}
| 0 |
296,276 | static void nfs4_xdr_enc_close(struct rpc_rqst *req, struct xdr_stream *xdr,
struct nfs_closeargs *args)
{
struct compound_hdr hdr = {
.minorversion = nfs4_xdr_minorversion(&args->seq_args),
};
encode_compound_hdr(xdr, req, &hdr);
encode_sequence(xdr, &args->seq_args, &hdr);
encode_putfh(xdr, args->fh... | 0 |
156,504 | int dev_forward_skb(struct net_device *dev, struct sk_buff *skb)
{
skb_orphan(skb);
if (!(dev->flags & IFF_UP) ||
(skb->len > (dev->mtu + dev->hard_header_len))) {
kfree_skb(skb);
return NET_RX_DROP;
}
skb_set_dev(skb, dev);
skb->tstamp.tv64 = 0;
skb->pkt_type = PACKET_HOST;
skb->protocol = eth_type_tr... | 0 |
409,584 | static int bnx2x_configure_ptp(struct bnx2x *bp)
{
int rc, port = BP_PORT(bp);
u32 wb_data[2];
/* Reset PTP event detection rules - will be configured in the IOCTL */
REG_WR(bp, port ? NIG_REG_P1_LLH_PTP_PARAM_MASK :
NIG_REG_P0_LLH_PTP_PARAM_MASK, 0x7FF);
REG_WR(bp, port ? NIG_REG_P1_LLH_PTP_RULE_MASK :
... | 0 |
520,456 | Longlong_null to_longlong_null()
{
longlong nr= val_int();
/*
C++ does not guarantee the order of parameter evaluation,
so to make sure "null_value" is passed to the constructor
after the val_int() call, val_int() is caled on a separate line.
*/
return Longlong_null(nr, null_value)... | 0 |
226,651 | bool ExecuteBrowserCommandObserver::CreateAndRegisterObserver(
AutomationProvider* automation,
Browser* browser,
int command,
IPC::Message* reply_message,
bool use_json_interface) {
bool result = true;
switch (command) {
case IDC_NEW_TAB: {
new NewTabObserver(automation, reply_message,... | 0 |
312,928 | void RenderFrameHostImpl::SimulateBeforeUnloadAck() {
DCHECK(is_waiting_for_beforeunload_ack_);
base::TimeTicks approx_renderer_start_time = send_before_unload_start_time_;
OnBeforeUnloadACK(true, approx_renderer_start_time, base::TimeTicks::Now());
}
| 0 |
116,259 | static bool generic_pkt_to_tuple(const struct sk_buff *skb,
unsigned int dataoff,
struct nf_conntrack_tuple *tuple)
{
tuple->src.u.all = 0;
tuple->dst.u.all = 0;
return true;
} | 0 |
477,218 | static int virtbt_setup_zephyr(struct hci_dev *hdev)
{
struct sk_buff *skb;
/* Read Build Information */
skb = __hci_cmd_sync(hdev, 0xfc08, 0, NULL, HCI_INIT_TIMEOUT);
if (IS_ERR(skb))
return PTR_ERR(skb);
bt_dev_info(hdev, "%s", (char *)(skb->data + 1));
hci_set_fw_info(hdev, "%s", skb->data + 1);
kfree_s... | 0 |
289,366 | static void vb_decode_palette ( VBDecContext * c , int data_size ) {
int start , size , i ;
start = bytestream2_get_byte ( & c -> stream ) ;
size = ( bytestream2_get_byte ( & c -> stream ) - 1 ) & 0xFF ;
if ( start + size > 255 ) {
av_log ( c -> avctx , AV_LOG_ERROR , "Palette change runs beyond entry 256\n" ) ;
... | 0 |
201,239 | virtual ~MockFreeDiskSpaceGetter() {}
| 0 |
61,184 | ModuleExport size_t RegisterTIFFImage(void)
{
#define TIFFDescription "Tagged Image File Format"
char
version[MaxTextExtent];
MagickInfo
*entry;
#if defined(MAGICKCORE_TIFF_DELEGATE)
if (tiff_semaphore == (SemaphoreInfo *) NULL)
ActivateSemaphoreInfo(&tiff_semaphore);
LockSemaphoreInfo(tiff_sema... | 0 |
83,945 | static void init_slave_skip_errors()
{
DBUG_ENTER("init_slave_skip_errors");
DBUG_ASSERT(!use_slave_mask); // not already initialized
if (bitmap_init(&slave_error_mask,0,MAX_SLAVE_ERROR,0))
{
fprintf(stderr, "Badly out of memory, please check your system status\n");
exit(1);
}
use_slave_mask = 1;
... | 0 |
144,997 | template<typename T>
inline void sgels(char & TRANS, int &M, int &N, int &NRHS, T* lapA, int &LDA,
T* lapB, int &LDB, T* WORK, int &LWORK, int &INFO){
dgels_(&TRANS, &M, &N, &NRHS, lapA, &LDA, lapB, &LDB, WORK, &LWORK, &INFO); | 0 |
283,560 | pdf_init_csi(fz_context *ctx, pdf_csi *csi, pdf_document *doc, pdf_obj *rdb, pdf_lexbuf *buf, fz_cookie *cookie)
{
memset(csi, 0, sizeof *csi);
csi->doc = doc;
csi->rdb = rdb;
csi->buf = buf;
csi->cookie = cookie;
}
| 0 |
21,930 | static size_t qio_channel_websock_extract_headers ( QIOChannelWebsock * ioc , char * buffer , QIOChannelWebsockHTTPHeader * hdrs , size_t nhdrsalloc , Error * * errp ) {
char * nl , * sep , * tmp ;
size_t nhdrs = 0 ;
nl = strstr ( buffer , QIO_CHANNEL_WEBSOCK_HANDSHAKE_DELIM ) ;
if ( ! nl ) {
error_setg ( errp , "... | 0 |
327,711 | static int vhost_user_get_vring_base(struct vhost_dev *dev,
struct vhost_vring_state *ring)
{
VhostUserMsg msg = {
.request = VHOST_USER_GET_VRING_BASE,
.flags = VHOST_USER_VERSION,
.state = *ring,
.size = sizeof(*ring),
};
vhos... | 1 |
114,409 | deep_count_more_files_callback (GObject *source_object,
GAsyncResult *res,
gpointer user_data)
{
DeepCountState *state;
NautilusDirectory *directory;
GList *files, *l;
GFileInfo *info;
state = user_data;
if (state->direc... | 0 |
405,068 | static int racls_del_cb(void *rock,
const char *key, size_t keylen,
const char *data __attribute__((unused)),
size_t datalen __attribute__((unused)))
{
struct txn **txn = (struct txn **)rock;
return cyrusdb_delete(mbdb, key, keylen, txn, /*force*/0);
} | 0 |
170,887 | String UrlForFrame(LocalFrame* frame) {
KURL url = frame->GetDocument()->Url();
url.RemoveFragmentIdentifier();
return url.GetString();
}
| 0 |
374,430 | get_call_expr_arg_stable(Node *expr, int argnum)
{
List *args;
Node *arg;
if (expr == NULL)
return false;
if (IsA(expr, FuncExpr))
args = ((FuncExpr *) expr)->args;
else if (IsA(expr, OpExpr))
args = ((OpExpr *) expr)->args;
else if (IsA(expr, DistinctExpr))
args = ((DistinctExpr *) expr)->args;
... | 0 |
401,557 | GSList* menu_cache_list_all_apps(MenuCache* cache)
{
GSList* list;
MENU_CACHE_LOCK;
if (G_UNLIKELY(!cache->root_dir)) /* empty cache */
list = NULL;
else
list = list_app_in_dir(cache->root_dir, NULL);
MENU_CACHE_UNLOCK;
return list;
} | 0 |
58,623 | static int mnt_fs_get_flags(struct libmnt_fs *fs)
{
return fs ? fs->flags : 0;
} | 0 |
240,661 | void Browser::TogglePresentationMode() {
window_->SetPresentationMode(!window_->InPresentationMode());
WindowFullscreenStateChanged();
}
| 0 |
444,337 | TEST_F(HttpConnectionManagerImplTest, UpstreamWatermarkCallbacks) {
setup(false, "");
setUpEncoderAndDecoder(false, false);
sendRequestHeadersAndData();
// Mimic the upstream connection backing up. The router would call
// onDecoderFilterAboveWriteBufferHighWatermark which should readDisable the stream and i... | 0 |
66,554 | void f2fs_wait_on_block_writeback(struct f2fs_sb_info *sbi, block_t blkaddr)
{
struct page *cpage;
if (blkaddr == NEW_ADDR || blkaddr == NULL_ADDR)
return;
cpage = find_lock_page(META_MAPPING(sbi), blkaddr);
if (cpage) {
f2fs_wait_on_page_writeback(cpage, DATA, true);
f2fs_put_page(cpage, 1);
}
} | 0 |
505,449 | static int ssl3_handshake_mac(SSL *s, EVP_MD_CTX *in_ctx,
const char *sender, int len, unsigned char *p)
{
unsigned int ret;
int npad,n;
unsigned int i;
unsigned char md_buf[EVP_MAX_MD_SIZE];
EVP_MD_CTX ctx;
EVP_MD_CTX_init(&ctx);
EVP_MD_CTX_set_flags(&ctx, EVP_MD_CTX_FLAG_NON_FIPS_ALLOW);
EVP_MD_CTX_co... | 0 |
137,916 | static inline pte_t pte_mkglobal(pte_t pte)
{
return pte_set_flags(pte, _PAGE_GLOBAL);
} | 0 |
332,193 | static void qpci_pc_config_writeb(QPCIBus *bus, int devfn, uint8_t offset, uint8_t value)
{
outl(0xcf8, (1 << 31) | (devfn << 8) | offset);
outb(0xcfc, value);
}
| 1 |
399,412 | static void create_kthread(struct kthread_create_info *create)
{
int pid;
#ifdef CONFIG_NUMA
current->pref_node_fork = create->node;
#endif
/* We want our own signal handler (we take no signals by default). */
pid = kernel_thread(kthread, create, CLONE_FS | CLONE_FILES | SIGCHLD);
if (pid < 0) {
/* If user was ... | 0 |
28,172 | static void gs_heap_free_string ( gs_memory_t * mem , byte * data , uint nbytes , client_name_t cname ) {
gs_heap_free_object ( mem , data , cname ) ;
} | 0 |
200,654 | void LayerTreeHost::PaintLayerContents(
const RenderSurfaceLayerList& render_surface_layer_list,
ResourceUpdateQueue* queue,
bool* did_paint_content,
bool* need_more_updates) {
OcclusionTracker<Layer> occlusion_tracker(
root_layer_->render_surface()->content_rect());
occlusion_tracker.set_mini... | 0 |
236,658 | void PushMessagingServiceImpl::Observe(
int type,
const content::NotificationSource& source,
const content::NotificationDetails& details) {
DCHECK_EQ(chrome::NOTIFICATION_APP_TERMINATING, type);
shutdown_started_ = true;
#if BUILDFLAG(ENABLE_BACKGROUND)
in_flight_keep_alive_.reset();
#endif // BUILDF... | 0 |
320,030 | static int ac3_decode_frame(AVCodecContext * avctx, void *data, int *data_size,
AVPacket *avpkt)
{
const uint8_t *buf = avpkt->data;
int buf_size = avpkt->size;
AC3DecodeContext *s = avctx->priv_data;
int16_t *out_samples = (int16_t *)data;
int blk, ch, err;
c... | 1 |
26,220 | void TSVConnActiveTimeoutCancel ( TSVConn connp ) {
sdk_assert ( sdk_sanity_check_iocore_structure ( connp ) == TS_SUCCESS ) ;
NetVConnection * vc = ( NetVConnection * ) connp ;
vc -> cancel_active_timeout ( ) ;
} | 0 |
43,500 | ssize_t proc_projid_map_write(struct file *file, const char __user *buf,
size_t size, loff_t *ppos)
{
struct seq_file *seq = file->private_data;
struct user_namespace *ns = seq->private;
struct user_namespace *seq_ns = seq_user_ns(seq);
if (!ns->parent)
return -EPERM;
if ((seq_ns != ns) && (seq_ns != ... | 0 |
68,149 | TEST_P(Http2CodecImplTest, TrailingHeaders) {
initialize();
TestHeaderMapImpl request_headers;
HttpTestUtility::addDefaultHeaders(request_headers);
EXPECT_CALL(request_decoder_, decodeHeaders_(_, false));
request_encoder_->encodeHeaders(request_headers, false);
EXPECT_CALL(request_decoder_, decodeData(_, f... | 0 |
435,954 | void net_enable_timestamp(void)
{
#ifdef CONFIG_JUMP_LABEL
int wanted;
while (1) {
wanted = atomic_read(&netstamp_wanted);
if (wanted <= 0)
break;
if (atomic_cmpxchg(&netstamp_wanted, wanted, wanted + 1) == wanted)
return;
}
atomic_inc(&netstamp_needed_deferred);
schedule_work(&netstamp_work);
#else
... | 0 |
178,993 | bool RenderFrameHostImpl::CreateNetworkServiceDefaultFactory(
network::mojom::URLLoaderFactoryRequest default_factory_request) {
return CreateNetworkServiceDefaultFactoryInternal(
last_committed_origin_, std::move(default_factory_request));
}
| 0 |
10,244 | static void BooleanOrNullAttributeAttributeSetter(
v8::Local<v8::Value> v8_value, const v8::FunctionCallbackInfo<v8::Value>& info) {
v8::Isolate* isolate = info.GetIsolate();
ALLOW_UNUSED_LOCAL(isolate);
v8::Local<v8::Object> holder = info.Holder();
ALLOW_UNUSED_LOCAL(holder);
TestObject* impl = V8TestO... | 1 |
37,308 | static int orinoco_ioctl_setibssport(struct net_device *dev,
struct iw_request_info *info,
void *wrqu,
char *extra)
{
struct orinoco_private *priv = ndev_priv(dev);
int val = *((int *) extra);
unsigned long flags;
if (orinoco_lock(priv, &flags) != 0)
return -EBUSY;
priv->ibss_port =... | 0 |
404,905 | static struct sk_buff *l2cap_ertm_seq_in_queue(struct sk_buff_head *head,
u16 seq)
{
struct sk_buff *skb;
skb_queue_walk(head, skb) {
if (bt_cb(skb)->l2cap.txseq == seq)
return skb;
}
return NULL;
} | 0 |
490,475 | void gf_fs_print_all_connections(GF_FilterSession *session, char *filter_name, void (*print_fn)(FILE *output, GF_SysPrintArgFlags flags, const char *fmt, ...) )
{
Bool found = GF_FALSE;
GF_List *done;
u32 i, j, count;
u32 llev = gf_log_get_tool_level(GF_LOG_FILTER);
gf_log_set_tool_level(GF_LOG_FILTER, GF_LOG_INF... | 0 |
232,135 | PHP_FUNCTION(locale_lookup)
{
char* fallback_loc = NULL;
int fallback_loc_len = 0;
const char* loc_range = NULL;
int loc_range_len = 0;
zval* arr = NULL;
HashTable* hash_arr = NULL;
zend_bool boolCanonical = 0;
char* result =NULL;
intl_error_reset( NULL TSRML... | 0 |
81,701 | uint32_t writeI32(const int32_t i32) {
T_VIRTUAL_CALL();
return writeI32_virt(i32);
} | 0 |
241,240 | void RenderFrameHostImpl::OnBubbleLogicalScrollInParentFrame(
blink::WebScrollDirection direction,
blink::WebScrollGranularity granularity) {
if (!is_active())
return;
RenderFrameProxyHost* proxy =
frame_tree_node()->render_manager()->GetProxyToParent();
if (!proxy) {
bad_message::ReceivedB... | 0 |
475,113 | static struct vrend_linked_shader_program *add_shader_program(struct vrend_sub_context *sub_ctx,
struct vrend_shader *vs,
struct vrend_shader *fs,
... | 0 |
6,149 | tok_nextc(struct tok_state *tok)
{
for (;;) {
if (tok->cur != tok->inp) {
return Py_CHARMASK(*tok->cur++); /* Fast path */
}
if (tok->done != E_OK)
return EOF;
if (tok->fp == NULL) {
char *end = strchr(tok->inp, '\n');
if (end != NULL)
... | 1 |
464,064 | ecc_ecdsa_sign (const struct ecc_curve *ecc,
const mp_limb_t *zp,
/* Random nonce, must be invertible mod ecc group
order. */
const mp_limb_t *kp,
size_t length, const uint8_t *digest,
mp_limb_t *rp, mp_limb_t *sp,
mp_limb_t *scratch)
{
#define P scratch
#define kinv scratch
#define hp (scr... | 0 |
358,959 | static int rsvp_change(struct tcf_proto *tp, unsigned long base,
u32 handle,
struct rtattr **tca,
unsigned long *arg)
{
struct rsvp_head *data = tp->root;
struct rsvp_filter *f, **fp;
struct rsvp_session *s, **sp;
struct tc_rsvp_pinfo *pinfo = NULL;
struct rtattr *opt = tca[TCA_OPTIONS-1... | 0 |
461,462 | static void coroutine_fn v9fs_link(void *opaque)
{
V9fsPDU *pdu = opaque;
int32_t dfid, oldfid;
V9fsFidState *dfidp, *oldfidp;
V9fsString name;
size_t offset = 7;
int err = 0;
v9fs_string_init(&name);
err = pdu_unmarshal(pdu, offset, "dds", &dfid, &oldfid, &name);
if (err < 0) {
... | 0 |
208,921 | AutofillExternalDelegate::AutofillExternalDelegate(AutofillManager* manager,
AutofillDriver* driver)
: manager_(manager), driver_(driver) {
DCHECK(manager);
}
| 0 |
156,814 | ves_icall_Type_GetInterfaces (MonoReflectionType* type)
{
MonoError error;
MonoDomain *domain = mono_object_domain (type);
MonoArray *intf;
GPtrArray *ifaces = NULL;
int i;
MonoClass *class = mono_class_from_mono_type (type->type);
MonoClass *parent;
MonoBitSet *slots;
MonoGenericContext *context = NULL;
MO... | 0 |
343,649 | void unix_notinflight(struct file *fp)
{
struct sock *s = unix_get_socket(fp);
if(s) {
atomic_dec(&unix_sk(s)->inflight);
atomic_dec(&unix_tot_inflight);
}
} | 1 |
255,014 | static void chs_assemble_msbs_lsbs(DCAXllDecoder *s, DCAXllChSet *c, int band)
{
DCAXllBand *b = &c->bands[band];
int n, ch, nsamples = s->nframesamples;
for (ch = 0; ch < c->nchannels; ch++) {
int shift = chs_get_lsb_width(s, c, band, ch);
if (shift) {
int32_t *msb = b-... | 1 |
28,695 | static int decode_residuals ( FLACContext * s , int32_t * decoded , int pred_order ) {
int i , tmp , partition , method_type , rice_order ;
int rice_bits , rice_esc ;
int samples ;
method_type = get_bits ( & s -> gb , 2 ) ;
if ( method_type > 1 ) {
av_log ( s -> avctx , AV_LOG_ERROR , "illegal residual coding met... | 0 |
284,627 | static inline int unicode_cp_is_allowed(unsigned uni_cp, int document_type)
{
/* XML 1.0 HTML 4.01 HTML 5
* 0x09..0x0A 0x09..0x0A 0x09..0x0A
* 0x0D 0x0D 0x0C..0x0D
* 0x0020..0xD7FF 0x20..0x7E 0x20..0x7E
* 0x00A0..0xD7FF 0x00A0..0xD7FF
* 0xE000..0xFFFD 0xE000..0x10FFFF 0xE000..0xFDCF... | 0 |
419,113 | format_create(struct client *c, struct cmdq_item *item, int tag, int flags)
{
struct format_tree *ft;
if (!event_initialized(&format_job_event)) {
evtimer_set(&format_job_event, format_job_timer, NULL);
format_job_timer(-1, 0, NULL);
}
ft = xcalloc(1, sizeof *ft);
RB_INIT(&ft->tree);
if (c != NULL) {
ft-... | 0 |
335,454 | static int dca_find_frame_end(DCAParseContext *pc1, const uint8_t *buf,
int buf_size)
{
int start_found, i;
uint32_t state;
ParseContext *pc = &pc1->pc;
start_found = pc->frame_start_found;
state = pc->state;
i = 0;
if (!start_found) {
... | 0 |
127,749 | static void cmd_anal_hint(RCore *core, const char *input) {
switch (input[0]) {
case '?':
if (input[1]) {
ut64 addr = r_num_math (core->num, input + 1);
r_core_anal_hint_print (core->anal, addr, 0);
} else {
r_core_cmd_help (core, help_msg_ah);
}
break;
case '.': // "ah."
r_core_anal_hint_print (c... | 0 |
441,206 | void RGWGetObjRetention_ObjStore_S3::send_response()
{
if (op_ret) {
set_req_state_err(s, op_ret);
}
dump_errno(s);
end_header(s, this, "application/xml");
dump_start(s);
if (op_ret) {
return;
}
encode_xml("Retention", obj_retention, s->formatter);
rgw_flush_formatter_and_reset(s, s->formatte... | 0 |
105,145 | static void start_interleave_scan(struct hci_dev *hdev)
{
hdev->interleave_scan_state = INTERLEAVE_SCAN_NO_FILTER;
queue_delayed_work(hdev->req_workqueue,
&hdev->interleave_scan, 0);
} | 0 |
288,459 | static int cli_scanfile ( const char * filename , cli_ctx * ctx ) {
int fd , ret ;
fd = safe_open ( filename , O_RDONLY | O_BINARY ) ;
if ( fd < 0 ) return CL_EOPEN ;
ret = cli_magic_scandesc ( fd , ctx ) ;
close ( fd ) ;
return ret ;
} | 0 |
394,198 | blkid_parttable blkid_partlist_get_table(blkid_partlist ls)
{
if (list_empty(&ls->l_tabs))
return NULL;
return list_entry(ls->l_tabs.next,
struct blkid_struct_parttable, t_tabs);
} | 0 |
55,954 | apr_byte_t oidc_cache_mutex_destroy(server_rec *s, oidc_cache_mutex_t *m) {
apr_status_t rv = APR_SUCCESS;
// oidc_sdebug(s, "enter: %d (m=%pp,s=%pp, p=%d)", (m && m->sema) ? *m->sema : -1, m->mutex ? m->mutex : 0, s, m->is_parent);
if (m->mutex != NULL) {
apr_global_mutex_lock(m->mutex);
(*m->sema)--;
//o... | 0 |
312,900 | void HWNDMessageHandler::OnThemeChanged() {
ui::NativeThemeWin::instance()->CloseHandles();
}
| 0 |
37,315 | //! Resize image to dimensions of a display window \newinstance.
CImg<T> get_resize(const CImgDisplay& disp,
const int interpolation_type=1, const unsigned int boundary_conditions=0,
const float centering_x = 0, const float centering_y = 0,
co... | 0 |
482,126 | static void xennet_alloc_rx_buffers(struct netfront_queue *queue)
{
RING_IDX req_prod = queue->rx.req_prod_pvt;
int notify;
int err = 0;
if (unlikely(!netif_carrier_ok(queue->info->netdev)))
return;
for (req_prod = queue->rx.req_prod_pvt;
req_prod - queue->rx.rsp_cons < NET_RX_RING_SIZE;
req_prod++... | 0 |
324,077 | static int qcow2_do_open(BlockDriverState *bs, QDict *options, int flags,
Error **errp)
{
BDRVQcow2State *s = bs->opaque;
unsigned int len, i;
int ret = 0;
QCowHeader header;
Error *local_err = NULL;
uint64_t ext_end;
uint64_t l1_vm_state_index;
ret =... | 0 |
453,922 | string str() {
return string("a\0b", 3);
} | 0 |
235,226 | RenderView::~RenderView() {
if (decrement_shared_popup_at_destruction_)
shared_popup_counter_->data--;
for (ImageResourceFetcherSet::iterator i = image_fetchers_.begin();
i != image_fetchers_.end(); ++i) {
delete *i;
}
while (!file_chooser_completions_.empty()) {
if (file_chooser_completion... | 0 |
150,192 | static void airo_print_status(const char *devname, u16 status)
{
u8 reason = status & 0xFF;
switch (status & 0xFF00) {
case STAT_NOBEACON:
switch (status) {
case STAT_NOBEACON:
airo_print_dbg(devname, "link lost (missed beacons)");
break;
case STAT_MAXRETRIES:
case STAT_MAXARL:
airo_print_dbg(devna... | 0 |
123,195 | static MagickBooleanType ReadPSDChannelPixels(Image *image,
const size_t channels,const size_t row,const ssize_t type,
const unsigned char *pixels,ExceptionInfo *exception)
{
Quantum
pixel;
register const unsigned char
*p;
register Quantum
*q;
register ssize_t
x;
size_t
packet_size... | 0 |
368,858 | void disconnect_server(PgSocket *server, bool notify, const char *reason, ...)
{
PgPool *pool = server->pool;
PgSocket *client;
static const uint8_t pkt_term[] = {'X', 0,0,0,4};
int send_term = 1;
usec_t now = get_cached_time();
char buf[128];
va_list ap;
va_start(ap, reason);
vsnprintf(buf, sizeof(buf), reas... | 0 |
135,030 | void send_open_url(const char *url)
{
GF_Event evt;
memset(&evt, 0, sizeof(GF_Event));
evt.type = GF_EVENT_NAVIGATE;
evt.navigate.to_url = url;
gf_term_send_event(term, &evt);
} | 0 |
436,883 | static int fts3InitVtab(
int isCreate, /* True for xCreate, false for xConnect */
sqlite3 *db, /* The SQLite database connection */
void *pAux, /* Hash table containing tokenizers */
int argc, /* Number of elements in argv array */
... | 0 |
362,145 | Process_Event( grEvent* event )
{
int ret = 0;
if ( event->key >= '1' && event->key < '1' + N_RENDER_MODES )
{
status.render_mode = event->key - '1';
event_render_mode_change( 0 );
return ret;
}
switch ( event->key )
{
case grKeyEsc:
case grKEY( 'q' ):
r... | 0 |
410,440 | QUtil::setRandomDataProvider(RandomDataProvider* p)
{
random_data_provider = p;
} | 0 |
374,270 | convert_tablespace_priv_string(text *priv_type_text)
{
static const priv_map tablespace_priv_map[] = {
{"CREATE", ACL_CREATE},
{"CREATE WITH GRANT OPTION", ACL_GRANT_OPTION_FOR(ACL_CREATE)},
{NULL, 0}
};
return convert_any_priv_string(priv_type_text, tablespace_priv_map);
} | 0 |
510,806 | void HttpErrorString(const FunctionCallbackInfo<Value>& args) {
Environment* env = Environment::GetCurrent(args);
uint32_t val = args[0]->Uint32Value(env->context()).ToChecked();
args.GetReturnValue().Set(
String::NewFromOneByte(
env->isolate(),
reinterpret_cast<const uint8_t*>(nghttp2_s... | 0 |
395,805 | gs_setdefaultgrayicc(const gs_gstate * pgs, gs_param_string * pval)
{
int code;
char *pname;
int namelen = (pval->size)+1;
gs_memory_t *mem = pgs->memory;
bool not_initialized;
/* Detect if this is our first time in here. If so, then we need to
reset up the default gray color spaces tha... | 0 |
301,902 | static Image *ReadMNGImage(const ImageInfo *image_info,ExceptionInfo *exception)
{
return(ReadPNGImage(image_info,exception));
} | 0 |
79,383 | do_local_notify(xmlNode * notify_src, const char *client_id,
gboolean sync_reply, gboolean from_peer)
{
/* send callback to originating child */
cib_client_t *client_obj = NULL;
int local_rc = pcmk_ok;
if (client_id != NULL) {
client_obj = g_hash_table_lookup(client_list, client... | 0 |
484,701 | static int snd_ctl_elem_info_user(struct snd_ctl_file *ctl,
struct snd_ctl_elem_info __user *_info)
{
struct snd_ctl_elem_info info;
int result;
if (copy_from_user(&info, _info, sizeof(info)))
return -EFAULT;
result = snd_ctl_elem_info(ctl, &info);
if (result < 0)
return result;
/* drop internal access... | 0 |
388,081 | gdm_session_handle_client_begin_verification_for_user (GdmDBusUserVerifier *user_verifier_interface,
GDBusMethodInvocation *invocation,
const char *service_name,
... | 0 |
16,913 | static int check_authenticated_user_and_ip ( int userid , struct query * q ) {
int res = check_user_and_ip ( userid , q ) ;
if ( res ) return res ;
if ( ! users [ userid ] . authenticated ) return 1 ;
return 0 ;
} | 0 |
48,794 | Status CalculateOutputIndex(OpKernelContext* context, int dimension,
const vector<INDEX_TYPE>& parent_output_index,
INDEX_TYPE output_index_multiplier,
INDEX_TYPE output_size,
vector<INDEX_TYPE>* re... | 0 |
432,167 | char *line6_alloc_sysex_buffer(struct usb_line6 *line6, int code1, int code2,
int size)
{
char *buffer = kmalloc(size + SYSEX_EXTRA_SIZE, GFP_ATOMIC);
if (!buffer)
return NULL;
buffer[0] = LINE6_SYSEX_BEGIN;
memcpy(buffer + 1, line6_midi_id, sizeof(line6_midi_id));
buffer[sizeof(line6_midi_id) + 1] =... | 0 |
10,852 | get_caller_uid (GDBusMethodInvocation *context, gint *uid)
{
PolkitSubject *subject;
PolkitSubject *process;
subject = polkit_system_bus_name_new (g_dbus_method_invocation_get_sender (context));
process = polkit_system_bus_name_get_process_sync (POLKIT_SYSTEM_BUS_NAME (subject), NULL,... | 1 |
489,588 | GF_Err gf_lz_compress_payload(u8 **data, u32 data_len, u32 *max_size)
{
*max_size = 0;
return GF_NOT_SUPPORTED;
} | 0 |
183,158 | void CastDetailedView::AppendHeaderEntry() {
CreateSpecialRow(IDS_ASH_STATUS_TRAY_CAST, this);
}
| 0 |
91,238 | LogL16fromY(double Y, int em) /* get 16-bit LogL from Y */
{
if (Y >= 1.8371976e19)
return (0x7fff);
if (Y <= -1.8371976e19)
return (0xffff);
if (Y > 5.4136769e-20)
return itrunc(256.*(log2(Y) + 64.), em);
if (Y < -5.4136769e-20)
return (~0x7fff | itrunc(256.*(log2(-Y) + 64.), em));
return (0);
} | 0 |
401,103 | static void cirrus_get_offsets(VGACommonState *s1,
uint32_t *pline_offset,
uint32_t *pstart_addr,
uint32_t *pline_compare)
{
CirrusVGAState * s = container_of(s1, CirrusVGAState, vga);
uint32_t start_addr, line_offset, ... | 0 |
370,219 | void sctp_transport_burst_limited(struct sctp_transport *t)
{
struct sctp_association *asoc = t->asoc;
u32 old_cwnd = t->cwnd;
u32 max_burst_bytes;
if (t->burst_limited)
return;
max_burst_bytes = t->flight_size + (asoc->max_burst * asoc->pathmtu);
if (max_burst_bytes < old_cwnd) {
t->cwnd = max_burst_bytes;... | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.