idx int64 | func string | target int64 |
|---|---|---|
247,609 | TEST_P(SslSocketTest, UpstreamNotReadySslSocket) {
Stats::TestUtil::TestStore stats_store;
NiceMock<LocalInfo::MockLocalInfo> local_info;
testing::NiceMock<Server::Configuration::MockTransportSocketFactoryContext> factory_context;
NiceMock<Init::MockManager> init_manager;
NiceMock<Event::MockDispatcher> dispa... | 0 |
90,139 | std::string CellularNetwork::GetActivationStateString() const {
return ActivationStateToString(this->activation_state_);
}
| 0 |
441,806 | SProcXkbGetNamedIndicator(ClientPtr client)
{
REQUEST(xkbGetNamedIndicatorReq);
swaps(&stuff->length);
REQUEST_SIZE_MATCH(xkbGetNamedIndicatorReq);
swaps(&stuff->deviceSpec);
swaps(&stuff->ledClass);
swaps(&stuff->ledID);
swapl(&stuff->indicator);
return ProcXkbGetNamedIndicator(client)... | 0 |
356,695 | void Statement::Work_BeginRun(Baton* baton) {
STATEMENT_BEGIN(Run);
} | 0 |
317,142 | static void selinux_cred_getsecid(const struct cred *c, u32 *secid)
{
*secid = cred_sid(c);
} | 0 |
197,517 | static json_t * check_attestation_fido_u2f(json_t * j_params, unsigned char * credential_id, size_t credential_id_len, unsigned char * cert_x, size_t cert_x_len, unsigned char * cert_y, size_t cert_y_len, cbor_item_t * att_stmt, unsigned char * rpid_hash, size_t rpid_hash_len, const unsigned char * client_data) {
jso... | 1 |
101,696 | void WebProcessProxy::removeMessageReceiver(CoreIPC::StringReference messageReceiverName, uint64_t destinationID)
{
m_messageReceiverMap.removeMessageReceiver(messageReceiverName, destinationID);
}
| 0 |
230,461 | ns_input(void)
{
uint8_t flags = 0;
LOG_INFO("Received NS from ");
LOG_INFO_6ADDR(&UIP_IP_BUF->srcipaddr);
LOG_INFO_(" to ");
LOG_INFO_6ADDR(&UIP_IP_BUF->destipaddr);
LOG_INFO_(" with target address ");
LOG_INFO_6ADDR((uip_ipaddr_t *) (&UIP_ND6_NS_BUF->tgtipaddr));
LOG_INFO_("\n");
UIP_STAT(++uip_sta... | 0 |
387,808 | void InstanceKlass::rewrite_class(TRAPS) {
assert(is_loaded(), "must be loaded");
if (is_rewritten()) {
assert(is_shared(), "rewriting an unshared class?");
return;
}
Rewriter::rewrite(this, CHECK);
set_rewritten();
} | 0 |
384,113 | raptor_free_xml_writer(raptor_xml_writer* xml_writer)
{
if(!xml_writer)
return;
if(xml_writer->nstack && xml_writer->my_nstack)
raptor_free_namespaces(xml_writer->nstack);
raptor_object_options_clear(&xml_writer->options);
RAPTOR_FREE(raptor_xml_writer, xml_writer);
} | 0 |
351,178 | static void copy_related (const char *inName, const char *outName,
const char *old_ext, const char *new_ext)
{
size_t name_len = strlen(inName);
const size_t old_len = strlen(old_ext);
const size_t new_len = strlen(new_ext);
char *in = malloc(name_len - old_len + new_len + 1);
strncpy(in, inName, (nam... | 0 |
379,664 | R_API void r_anal_function_delete_unused_vars(RAnalFunction *fcn) {
r_return_if_fail (fcn);
void **v;
RPVector *vars_clone = (RPVector *)r_vector_clone ((RVector *)&fcn->vars);
r_pvector_foreach (vars_clone, v) {
RAnalVar *var = *v;
if (r_vector_empty (&var->accesses)) {
r_anal_function_delete_var (fcn, var)... | 0 |
275,497 | njs_vm_value(njs_vm_t *vm, const njs_str_t *path, njs_value_t *retval)
{
u_char *start, *p, *end;
size_t size;
njs_int_t ret;
njs_value_t value, key;
start = path->start;
end = start + path->length;
njs_set_object(&value, &vm->global_object);
for ( ;; ) {
p = n... | 0 |
427,200 | static void whilestat (LexState *ls, int line) {
/* whilestat -> WHILE cond DO block END */
FuncState *fs = ls->fs;
int whileinit;
int condexit;
BlockCnt bl;
luaX_next(ls); /* skip WHILE */
whileinit = luaK_getlabel(fs);
condexit = cond(ls);
enterblock(fs, &bl, 1);
checknext(ls, TK_DO);
block(ls)... | 0 |
196,834 | Status SparseCountSparseOutputShapeFn(InferenceContext *c) {
auto rank = c->Dim(c->input(0), 1);
auto nvals = c->UnknownDim();
c->set_output(0, c->Matrix(nvals, rank)); // out.indices
c->set_output(1, c->Vector(nvals)); // out.values
c->set_output(2, c->Vector(rank)); // out.dense_shape
retu... | 1 |
376,337 | gpg_verify_sync (CamelCipherContext *context,
CamelMimePart *ipart,
GCancellable *cancellable,
GError **error)
{
CamelCipherContextClass *class;
CamelCipherValidity *validity;
const gchar *diagnostics = NULL;
struct _GpgCtx *gpg = NULL;
gchar *sigfile = NULL;
Cam... | 0 |
512,260 | Item *Item_bool_rowready_func2::neg_transformer(THD *thd)
{
Item *item= negated_item(thd);
return item;
} | 0 |
359,379 | DEFUN (no_neighbor_capability_dynamic,
no_neighbor_capability_dynamic_cmd,
NO_NEIGHBOR_CMD2 "capability dynamic",
NO_STR
NEIGHBOR_STR
NEIGHBOR_ADDR_STR2
"Advertise capability to the peer\n"
"Advertise dynamic capability to this neighbor\n")
{
return peer_flag_unset_vty... | 0 |
214,364 | void simplestring_addn(simplestring* target, const char* source, int add_len) {
if(target && source) {
if(!target->str) {
simplestring_init_str(target);
}
if(target->len + add_len + 1 > target->size) {
/* newsize is current length + new length */
int newsize = target->len... | 1 |
336,803 | lprn_bubble_flush(gx_device_printer * pdev, gp_file * fp, Bubble * bbl)
{
gx_device_lprn *const lprn = (gx_device_lprn *) pdev;
int i, j, bx;
byte *p;
int bx0 = bbl->brect.p.x / lprn->nBw;
int bx1 = (bbl->brect.q.x + lprn->nBw - 1) / lprn->nBw;
int bpl = gdev_mem_bytes_per_scan_line(pdev);
i... | 0 |
508,869 | static int find_keyword(Lex_input_stream *lip, uint len, bool function)
{
const char *tok= lip->get_tok_start();
SYMBOL *symbol= get_hash_symbol(tok, len, function);
if (symbol)
{
lip->yylval->symbol.symbol=symbol;
lip->yylval->symbol.str= (char*) tok;
lip->yylval->symbol.length=len;
if ((symb... | 0 |
224,167 | std::size_t size() {
tensorflow::mutex_lock lock(mu_);
return map_.size();
} | 0 |
233,813 | int fmtutil_is_standard_iff_chunk(deark *c, struct de_iffctx *ictx,
u32 ct)
{
switch(ct) {
case CODE__c_:
case CODE_ANNO:
case CODE_AUTH:
case CODE_NAME:
case CODE_TEXT:
return 1;
}
return 0;
} | 0 |
262,025 | Proto_DumpRequest(ProtoRequest *req)
{
#if VGAUTH_PROTO_TRACE
printf("raw data: %s\n", req->rawData ? req->rawData : "<none>");
#endif
Debug("complete: %d\n", req->complete);
Debug("sequenceNumber: %d\n", req->sequenceNumber);
Log("requestType: %d(%s REQ)\n", req->reqType,
ProtoRequestTypeText(req->r... | 0 |
516,252 | static int virtio_net_tx_waiting_pre_load(void *opaque)
{
struct VirtIONetMigTmp *tmp = opaque;
/* Reuse the pointer setup from save */
virtio_net_tx_waiting_pre_save(opaque);
if (tmp->parent->curr_queues > tmp->parent->max_queues) {
error_report("virtio-net: curr_queues %x > max_queues %x",
... | 0 |
427,730 | cdf_print_property_name(char *buf, size_t bufsiz, uint32_t p)
{
size_t i;
for (i = 0; i < __arraycount(vn); i++)
if (vn[i].v == p)
return snprintf(buf, bufsiz, "%s", vn[i].n);
return snprintf(buf, bufsiz, "%#x", p);
} | 0 |
484,814 | static void xennet_bus_close(struct xenbus_device *dev)
{
int ret;
if (xenbus_read_driver_state(dev->otherend) == XenbusStateClosed)
return;
do {
xenbus_switch_state(dev, XenbusStateClosing);
ret = wait_event_timeout(module_wq,
xenbus_read_driver_state(dev->otherend) ==
XenbusStateClosing ||
... | 0 |
226,355 |
GF_Box *stri_box_new()
{
ISOM_DECL_BOX_ALLOC(GF_SubTrackInformationBox, GF_ISOM_BOX_TYPE_STRI);
return (GF_Box *)tmp; | 0 |
244,261 | GF_Err trik_box_read(GF_Box *s,GF_BitStream *bs)
{
u32 i;
GF_TrickPlayBox *ptr = (GF_TrickPlayBox *) s;
ptr->entry_count = (u32) ptr->size;
if ((u64)ptr->entry_count > (u64)SIZE_MAX/sizeof(GF_TrickPlayBoxEntry)) {
GF_LOG(GF_LOG_ERROR, GF_LOG_CONTAINER, ("[iso file] Invalid size %llu in trik\n", ptr->size));
ret... | 0 |
401,585 | static int proc_do_uuid(struct ctl_table *table, int write,
void *buffer, size_t *lenp, loff_t *ppos)
{
struct ctl_table fake_table;
unsigned char buf[64], tmp_uuid[16], *uuid;
uuid = table->data;
if (!uuid) {
uuid = tmp_uuid;
generate_random_uuid(uuid);
} else {
static DEFINE_SPINLOCK(bootid_spinlock);
... | 0 |
329,915 | _cairo_image_spans (void *abstract_renderer,
int y, int height,
const cairo_half_open_span_t *spans,
unsigned num_spans)
{
cairo_image_span_renderer_t *r = abstract_renderer;
uint8_t *mask, *row;
int len;
if (num_spans == 0)
return CAIRO_STATUS_SUCCESS;
mask = r->u.mask.data + (... | 0 |
292,211 | inbound_upart (server *serv, char *chan, char *ip, char *reason,
const message_tags_data *tags_data)
{
session *sess = find_channel (serv, chan);
if (sess)
{
if (*reason)
EMIT_SIGNAL_TIMESTAMP (XP_TE_UPARTREASON, sess, serv->nick, ip, chan,
reason, 0, tags_data->timestamp);
else
EMIT_SIGNA... | 0 |
222,494 | Status AddItem(const string& name, const NameInfoItem& item) {
if (!index_.insert({name, item}).second) {
return errors::InvalidArgument(
strings::StrCat("Duplicated ", item.is_func_arg ? "arg" : "ret",
" name: "),
name);
}
return Status::OK();
} | 0 |
513,336 | int join_read_key2(THD *thd, JOIN_TAB *tab, TABLE *table, TABLE_REF *table_ref)
{
int error;
if (!table->file->inited)
{
error= table->file->ha_index_init(table_ref->key, tab ? tab->sorted : TRUE);
if (error)
{
(void) report_error(table, error);
return 1;
}
}
/*
The following ... | 0 |
300,823 | static int tipc_setsockopt(struct socket *sock, int lvl, int opt,
sockptr_t ov, unsigned int ol)
{
struct sock *sk = sock->sk;
struct tipc_sock *tsk = tipc_sk(sk);
struct tipc_group_req mreq;
u32 value = 0;
int res = 0;
if ((lvl == IPPROTO_TCP) && (sock->type == SOCK_STREAM))
return 0;
if (lvl != SOL_TI... | 0 |
225,457 | Status MutableGraphView::CheckNodesCanBeDeleted(
const absl::flat_hash_set<string>& nodes_to_delete) {
std::vector<string> missing_nodes;
std::vector<string> nodes_with_fanouts;
for (const string& node_name_to_delete : nodes_to_delete) {
NodeDef* node = GetNode(node_name_to_delete);
if (node == nullpt... | 0 |
482,473 | _lou_getCharForDots(widechar d, const DisplayTableHeader *table) {
CharDotsMapping *cdPtr = getCharForDots(d, table);
if (cdPtr) return cdPtr->found;
return '\0';
} | 0 |
369,270 |
static struct io_rsrc_node *io_rsrc_node_alloc(void)
{
struct io_rsrc_node *ref_node;
ref_node = kzalloc(sizeof(*ref_node), GFP_KERNEL);
if (!ref_node)
return NULL;
if (percpu_ref_init(&ref_node->refs, io_rsrc_node_ref_zero,
0, GFP_KERNEL)) {
kfree(ref_node);
return NULL;
}
INIT_LIST_HEAD(&ref_nod... | 0 |
491,961 | __acquires(&fc->lock)
{
struct fuse_inode *fi = get_fuse_inode(req->inode);
loff_t size = i_size_read(req->inode);
struct fuse_write_in *inarg = &req->misc.write.in;
if (!fc->connected)
goto out_free;
if (inarg->offset + PAGE_CACHE_SIZE <= size) {
inarg->size = PAGE_CACHE_SIZE;
} else if (inarg->offset < si... | 0 |
353,238 | bool SplashOutputDev::maskedImageSrc(void *data, SplashColorPtr colorLine,
unsigned char *alphaLine) {
SplashOutMaskedImageData *imgData = (SplashOutMaskedImageData *)data;
unsigned char *p, *aq;
SplashColorPtr q, col;
GfxRGB rgb;
GfxGray gray;
#ifdef SPLASH_CMYK
GfxCMYK cmyk;
GfxColor deviceN;
... | 0 |
252,332 | int IsEXR(const char *filename) {
EXRVersion exr_version;
int ret = ParseEXRVersionFromFile(&exr_version, filename);
if (ret != TINYEXR_SUCCESS) {
return TINYEXR_ERROR_INVALID_HEADER;
}
return TINYEXR_SUCCESS;
} | 0 |
369,233 | static int io_msg_ring_prep(struct io_kiocb *req,
const struct io_uring_sqe *sqe)
{
if (unlikely(sqe->addr || sqe->ioprio || sqe->rw_flags ||
sqe->splice_fd_in || sqe->buf_index || sqe->personality))
return -EINVAL;
req->msg.user_data = READ_ONCE(sqe->off);
req->msg.len = READ_ONCE(sqe->len);
retur... | 0 |
313,806 | add_to_showcmd(int c)
{
char_u *p;
int old_len;
int extra_len;
int overflow;
int i;
static int ignore[] =
{
#ifdef FEAT_GUI
K_VER_SCROLLBAR, K_HOR_SCROLLBAR,
K_LEFTMOUSE_NM, K_LEFTRELEASE_NM,
#endif
K_IGNORE, K_PS,
K_LEFTMOUSE, K_LEFTDRAG, K_LEFTRELEASE, K_MOUSEMOVE,
K_MIDDLEMOUSE, ... | 0 |
393,538 | static SQInteger base_callee(HSQUIRRELVM v)
{
if(v->_callsstacksize > 1)
{
v->Push(v->_callsstack[v->_callsstacksize - 2]._closure);
return 1;
}
return sq_throwerror(v,_SC("no closure in the calls stack"));
} | 0 |
317,167 | static int smack_socket_connect(struct socket *sock, struct sockaddr *sap,
int addrlen)
{
int rc = 0;
if (sock->sk == NULL)
return 0;
if (sock->sk->sk_family != PF_INET &&
(!IS_ENABLED(CONFIG_IPV6) || sock->sk->sk_family != PF_INET6))
return 0;
if (addrlen < offsetofend(struct sockaddr, sa_family))
... | 0 |
195,752 | void MakeDataset(OpKernelContext* ctx, DatasetBase** output) override {
// Create a new SparseTensorSliceDatasetOp::Dataset, insert it in
// the step container, and return it as the output.
const Tensor* indices;
OP_REQUIRES_OK(ctx, ctx->input("indices", &indices));
const Tensor* values;
OP_RE... | 1 |
219,012 | Status ConstantFolding::EvaluateNode(const NodeDef& node,
const TensorVector& inputs,
TensorVector* output) const {
return ::tensorflow::grappler::EvaluateNode(node, inputs, cpu_device_,
resource_mg... | 0 |
238,377 | njs_function_prototype_call(njs_vm_t *vm, njs_value_t *args, njs_uint_t nargs,
njs_index_t unused)
{
njs_int_t ret;
njs_function_t *function;
const njs_value_t *this;
njs_native_frame_t *frame;
if (!njs_is_function(&args[0])) {
njs_type_error(vm, "\"this\" argument is ... | 0 |
252,284 | static void WriteChannelInfo(std::vector<unsigned char> &data,
const std::vector<ChannelInfo> &channels) {
size_t sz = 0;
// Calculate total size.
for (size_t c = 0; c < channels.size(); c++) {
sz += strlen(channels[c].name.c_str()) + 1; // +1 for \0
sz += 16; ... | 0 |
277,673 | start_input_ppm (j_compress_ptr cinfo, cjpeg_source_ptr sinfo)
{
ppm_source_ptr source = (ppm_source_ptr) sinfo;
int c;
unsigned int w, h, maxval;
boolean need_iobuffer, use_raw_buffer, need_rescale;
if (getc(source->pub.input_file) != 'P')
ERREXIT(cinfo, JERR_PPM_NOT);
c = getc(source->pub.input_file... | 0 |
455,393 | xfs_inode_ag_iterator_flags(
struct xfs_mount *mp,
int (*execute)(struct xfs_inode *ip, int flags,
void *args),
int flags,
void *args,
int iter_flags)
{
struct xfs_perag *pag;
int error = 0;
int last_error = 0;
xfs_agnumber_t ag;
ag = 0;
while ((pag = xfs_perag_get(mp, ag))) {
ag = pa... | 0 |
336,593 | void RedCharDeviceVDIPort::send_tokens_to_client(RedCharDeviceClientOpaque *opaque, uint32_t tokens)
{
RedClient *client = (RedClient *) opaque;
client->get_main()->push_agent_tokens(tokens);
} | 0 |
253,613 | smb2_can_echo(struct TCP_Server_Info *server)
{
return server->echoes;
} | 0 |
197,247 | Status ShapeRefiner::InferShapesForFunctionSubNode(
const Node* node, InferenceContext* outer_context) {
TF_RETURN_IF_ERROR(AddNodeInternal(node, outer_context));
InferenceContext* node_context = CHECK_NOTNULL(GetContext(node));
if (StringPiece(node->type_string()) == kArgOp) {
// Handle special node: fu... | 1 |
313,823 | nv_open(cmdarg_T *cap)
{
#ifdef FEAT_DIFF
// "do" is ":diffget"
if (cap->oap->op_type == OP_DELETE && cap->cmdchar == 'o')
{
clearop(cap->oap);
nv_diffgetput(FALSE, cap->opcount);
}
else
#endif
if (VIsual_active) // switch start and end of visual
v_swap_corners(cap->cmdchar);
#ifdef FEAT_JOB... | 0 |
476,143 | void composite_disconnect(struct usb_gadget *gadget)
{
usb_gadget_vbus_draw(gadget, 0);
__composite_disconnect(gadget);
} | 0 |
402,657 | handle_unlock_token(context *ctx, struct pollfd *pollfd, socklen_t size)
{
struct msghdr msg;
struct iovec iov;
ssize_t n;
int rc = cms_context_alloc(&ctx->cms);
if (rc < 0) {
send_response(ctx, ctx->backup_cms, pollfd, rc);
return;
}
steal_from_cms(ctx->backup_cms, ctx->cms);
char *buffer = malloc(size)... | 0 |
313,746 | nv_ctrlh(cmdarg_T *cap)
{
if (VIsual_active && VIsual_select)
{
cap->cmdchar = 'x'; // BS key behaves like 'x' in Select mode
v_visop(cap);
}
else
nv_left(cap);
} | 0 |
449,299 | nv_screengo(oparg_T *oap, int dir, long dist)
{
int linelen = linetabsize(ml_get_curline());
int retval = OK;
int atend = FALSE;
int n;
int col_off1; // margin offset for first screen line
int col_off2; // margin offset for wrapped screen line
int width1; // text width for first scre... | 0 |
238,403 | njs_function_capture_global_closures(njs_vm_t *vm, njs_function_t *function)
{
void *start, *end;
uint32_t n;
njs_value_t *value, **refs, **global;
njs_index_t *indexes, index;
njs_native_frame_t *native;
njs_function_lambda_t *lambda;
... | 0 |
437,708 | int cx23888_ir_probe(struct cx23885_dev *dev)
{
struct cx23888_ir_state *state;
struct v4l2_subdev *sd;
struct v4l2_subdev_ir_parameters default_params;
int ret;
state = kzalloc(sizeof(struct cx23888_ir_state), GFP_KERNEL);
if (state == NULL)
return -ENOMEM;
spin_lock_init(&state->rx_kfifo_lock);
if (kfifo_... | 0 |
389,745 | check_for_opt_string_or_number_arg(typval_T *args, int idx)
{
return (args[idx].v_type == VAR_UNKNOWN
|| check_for_string_or_number_arg(args, idx) != FAIL);
} | 0 |
275,526 | njs_vm_object_alloc(njs_vm_t *vm, njs_value_t *retval, ...)
{
va_list args;
njs_int_t ret;
njs_value_t *name, *value;
njs_object_t *object;
njs_object_prop_t *prop;
njs_lvlhsh_query_t lhq;
object = njs_object_alloc(vm);
if (njs_slow_path(object ==... | 0 |
244,170 | GF_Box *ssix_box_new()
{
ISOM_DECL_BOX_ALLOC(GF_SubsegmentIndexBox, GF_ISOM_BOX_TYPE_SSIX);
return (GF_Box *)tmp;
} | 0 |
482,550 | passFindCharacters(const FileInfo *file, widechar *instructions, int end,
widechar **characters, int *length) {
int IC = 0;
int lookback = 0;
*characters = NULL;
*length = 0;
while (IC < end) {
widechar instruction = instructions[IC];
switch (instruction) {
case pass_string:
case pass_dots: {
int c... | 0 |
310,025 | _nc_screen_init(void)
{
NCURSES_SP_NAME(_nc_screen_init) (CURRENT_SCREEN);
} | 0 |
343,286 | static int dlmap_init(DLHandler * const dlhandler, const int clientfd,
void * const tls_clientfd, const int xferfd,
const char * const name, const int f,
void * const tls_fd, const off_t restartat,
const int ascii_mode, const unsign... | 0 |
338,156 | void WasmBinaryBuilder::pushExpression(Expression* curr) {
auto type = curr->type;
if (type.isTuple()) {
// Store tuple to local and push individual extracted values
Builder builder(wasm);
// Non-nullable types require special handling as they cannot be stored to
// a local.
std::vector<Type> fi... | 0 |
326,095 | regpiece(int *flagp)
{
char_u *ret;
int op;
char_u *next;
int flags;
long minval;
long maxval;
ret = regatom(&flags);
if (ret == NULL)
return NULL;
op = peekchr();
if (re_multi_type(op) == NOT_MULTI)
{
*flagp = flags;
return ret;
}
// de... | 0 |
432,283 | static MemoryRegionSection memory_region_find_rcu(MemoryRegion *mr,
hwaddr addr, uint64_t size)
{
MemoryRegionSection ret = { .mr = NULL };
MemoryRegion *root;
AddressSpace *as;
AddrRange range;
FlatView *view;
FlatRange *fr;
addr += mr->add... | 0 |
243,983 | GF_Err sdtp_box_read(GF_Box *s, GF_BitStream *bs)
{
GF_SampleDependencyTypeBox *ptr = (GF_SampleDependencyTypeBox*)s;
/*out-of-order sdtp, assume no padding at the end*/
if (!ptr->sampleCount) ptr->sampleCount = (u32) ptr->size;
else if (ptr->sampleCount > (u32) ptr->size) return GF_ISOM_INVALID_FILE;
ptr->sampl... | 0 |
294,685 | rt_complete_frags(VALUE klass, VALUE hash)
{
static VALUE tab = Qnil;
int g;
long e;
VALUE k, a, d;
if (NIL_P(tab)) {
tab = f_frozen_ary(11,
f_frozen_ary(2,
sym("time"),
f_frozen_ary(3,
sym("hour"),
sym("min"),
sym("sec"))),
f_frozen_ary(2,
... | 0 |
224,172 | TF_EXCLUSIVE_LOCKS_REQUIRED(mu_) {
if (tuple[index].has_value()) {
return errors::InvalidArgument("The tensor for index '", index,
"' for key '", key.scalar<int64_t>()(),
"' was already initialized '",
... | 0 |
404,719 | int receive_fd(struct file *file, unsigned int o_flags)
{
return __receive_fd(file, NULL, o_flags);
} | 0 |
226,375 | GF_Err unkn_box_size(GF_Box *s)
{
GF_UnknownBox *ptr = (GF_UnknownBox *)s;
if (ptr->dataSize && ptr->data) {
ptr->size += ptr->dataSize;
}
return GF_OK;
} | 0 |
221,123 | void DecodePngV2(OpKernelContext* context, StringPiece input) {
int channel_bits = (data_type_ == DataType::DT_UINT8) ? 8 : 16;
png::DecodeContext decode;
OP_REQUIRES(
context, png::CommonInitDecode(input, channels_, channel_bits, &decode),
errors::InvalidArgument("Invalid PNG. Failed to i... | 0 |
198,662 | ex_copy(linenr_T line1, linenr_T line2, linenr_T n)
{
linenr_T count;
char_u *p;
count = line2 - line1 + 1;
if ((cmdmod.cmod_flags & CMOD_LOCKMARKS) == 0)
{
curbuf->b_op_start.lnum = n + 1;
curbuf->b_op_end.lnum = n + count;
curbuf->b_op_start.col = curbuf->b_op_end.col = 0;
}
/*
*... | 1 |
366,257 | static void umount_tree(struct mount *mnt, enum umount_tree_flags how)
{
LIST_HEAD(tmp_list);
struct mount *p;
if (how & UMOUNT_PROPAGATE)
propagate_mount_unlock(mnt);
/* Gather the mounts to umount */
for (p = mnt; p; p = next_mnt(p, mnt)) {
p->mnt.mnt_flags |= MNT_UMOUNT;
list_move(&p->mnt_list, &tmp_lis... | 0 |
234,725 | int btrfs_uuid_scan_kthread(void *data)
{
struct btrfs_fs_info *fs_info = data;
struct btrfs_root *root = fs_info->tree_root;
struct btrfs_key key;
struct btrfs_path *path = NULL;
int ret = 0;
struct extent_buffer *eb;
int slot;
struct btrfs_root_item root_item;
u32 item_size;
struct btrfs_trans_handle *trans... | 0 |
275,484 | njs_vm_value_buffer_set(njs_vm_t *vm, njs_value_t *value, const u_char *start,
uint32_t size)
{
return njs_buffer_set(vm, value, start, size);
} | 0 |
401,534 | static void process_random_ready_list(void)
{
unsigned long flags;
struct random_ready_callback *rdy, *tmp;
spin_lock_irqsave(&random_ready_list_lock, flags);
list_for_each_entry_safe(rdy, tmp, &random_ready_list, list) {
struct module *owner = rdy->owner;
list_del_init(&rdy->list);
rdy->func(rdy);
module... | 0 |
247,150 | 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 |
383,370 | gdImageFilledArc (gdImagePtr im, int cx, int cy, int w, int h, int s, int e, int color, int style)
{
gdPoint pts[3];
int i;
int lx = 0, ly = 0;
int fx = 0, fy = 0;
int w2, h2;
w2 = w / 2;
h2 = h / 2;
while (e < s)
{
e += 360;
}
for (i = s; (i <= e); i++)
{
int x, y;
x = (... | 0 |
333,064 | nfa_regcomp(char_u *expr, int re_flags)
{
nfa_regprog_T *prog = NULL;
size_t prog_size;
int *postfix;
if (expr == NULL)
return NULL;
#ifdef DEBUG
nfa_regengine.expr = expr;
#endif
nfa_re_flags = re_flags;
init_class_tab();
if (nfa_regcomp_start(expr, re_flags) == FAIL)
return NU... | 0 |
357,677 | SQClass::SQClass(SQSharedState *ss,SQClass *base)
{
_base = base;
_typetag = 0;
_hook = NULL;
_udsize = 0;
_locked = false;
_constructoridx = -1;
if(_base) {
_constructoridx = _base->_constructoridx;
_udsize = _base->_udsize;
_defaultvalues.copy(base->_defaultvalues);... | 0 |
317,325 | static inline u16 inode_mode_to_security_class(umode_t mode)
{
switch (mode & S_IFMT) {
case S_IFSOCK:
return SECCLASS_SOCK_FILE;
case S_IFLNK:
return SECCLASS_LNK_FILE;
case S_IFREG:
return SECCLASS_FILE;
case S_IFBLK:
return SECCLASS_BLK_FILE;
case S_IFDIR:
return SECCLASS_DIR;
case S_IFCHR:
return... | 0 |
263,297 | off_t _q_iosend(FILE *outfp, FILE *infp, off_t nbytes) {
if (nbytes == 0) return 0;
unsigned char buf[QIOSEND_CHUNK_SIZE];
off_t total = 0; // total size sent
while (total < nbytes) {
size_t chunksize; // this time sending size
if (nbytes - total <= sizeof(buf)) chunksize = nbytes - tot... | 0 |
393,497 | static SQInteger closure_acall(HSQUIRRELVM v)
{
return _closure_acall(v,SQTrue);
} | 0 |
384,298 | gs_heap_free_object(gs_memory_t * mem, void *ptr, client_name_t cname)
{
gs_malloc_memory_t *mmem = (gs_malloc_memory_t *) mem;
gs_malloc_block_t *bp;
gs_memory_type_ptr_t pstype;
struct_proc_finalize((*finalize));
if_debug3m('a', mem, "[a-]gs_free(%s) 0x%lx(%u)\n",
client_name_strin... | 0 |
90,176 | virtual void RemoveNetworkObserver(const std::string& service_path,
NetworkObserver* observer) {
DCHECK(observer);
DCHECK(service_path.size());
NetworkObserverMap::iterator map_iter =
network_observers_.find(service_path);
if (map_iter != network_observers_... | 0 |
376,335 | gpg_ctx_set_ostream (struct _GpgCtx *gpg,
CamelStream *ostream)
{
g_object_ref (ostream);
if (gpg->ostream)
g_object_unref (gpg->ostream);
gpg->ostream = ostream;
gpg->seen_eof1 = FALSE;
} | 0 |
196,893 | void DefaultCertValidator::updateDigestForSessionId(bssl::ScopedEVP_MD_CTX& md,
uint8_t hash_buffer[EVP_MAX_MD_SIZE],
unsigned hash_length) {
int rc;
// Hash all the settings that affect whether the server will ... | 1 |
226,181 |
GF_Err strk_box_read(GF_Box *s, GF_BitStream *bs)
{
GF_Err e;
GF_SubTrackBox *ptr = (GF_SubTrackBox *)s;
e = gf_isom_box_array_read(s, bs);
if (e) return e;
if (!ptr->info) {
GF_LOG(GF_LOG_ERROR, GF_LOG_CONTAINER, ("[iso file] Missing SubTrackInformationBox\n"));
return GF_ISOM_INVALID_FILE;
}
return GF_OK... | 0 |
231,061 | BaseType_t xQueueGenericSend( QueueHandle_t xQueue,
const void * const pvItemToQueue,
TickType_t xTicksToWait,
const BaseType_t xCopyPosition )
{
BaseType_t xEntryTimeSet = pdFALSE, xYieldRequired;
TimeOut_t xTimeOut... | 0 |
384,679 | check_string (uint32_t option, char *buf, uint32_t len, uint32_t maxlen,
const char *name)
{
if (len > NBD_MAX_STRING || len > maxlen) {
nbdkit_error ("%s: %s too long", name_of_nbd_opt (option), name);
return -1;
}
if (strnlen (buf, len) != len) {
nbdkit_error ("%s: %s may not include N... | 0 |
509,527 | int ha_maria::multi_range_read_explain_info(uint mrr_mode, char *str,
size_t size)
{
return ds_mrr.dsmrr_explain_info(mrr_mode, str, size);
} | 0 |
508,385 | void close_thread_table(THD *thd, TABLE **table_ptr)
{
TABLE *table= *table_ptr;
DBUG_ENTER("close_thread_table");
DBUG_PRINT("tcache", ("table: '%s'.'%s' %p", table->s->db.str,
table->s->table_name.str, table));
DBUG_ASSERT(!table->file->keyread_enabled());
DBUG_ASSERT(!table->file ||... | 0 |
483,491 | u64 __init efi_mem_desc_end(efi_memory_desc_t *md)
{
u64 size = md->num_pages << EFI_PAGE_SHIFT;
u64 end = md->phys_addr + size;
return end;
} | 0 |
432,727 | static void util_set_pen(wmfAPI * API, wmfDC * dc)
{
wmf_magick_t
*ddata = WMF_MAGICK_GetData(API);
wmfPen
*pen = 0;
double
pen_width,
pixel_width;
unsigned int
pen_style;
pen = WMF_DC_PEN(dc);
pen_width = (WMF_PEN_WIDTH(pen) + WMF_PEN_HEIGHT(pen)) / 2;
/* Pixel width is inverse ... | 0 |
275,950 | static void XYcZ_addC(uECC_word_t * X1,
uECC_word_t * Y1,
uECC_word_t * X2,
uECC_word_t * Y2,
uECC_Curve curve) {
/* t1 = X1, t2 = Y1, t3 = X2, t4 = Y2 */
uECC_word_t t5[uECC_MAX_WORDS];
uECC_word_t t6[uECC_MAX_WORDS];
... | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.