unique_id int64 13 189k | target int64 0 1 | code stringlengths 20 241k | __index_level_0__ int64 0 18.9k |
|---|---|---|---|
24,121 | 0 | static int prism2_close(struct net_device *dev)
{
struct hostap_interface *iface;
local_info_t *local;
PDEBUG(DEBUG_FLOW, "%s: prism2_close\n", dev->name);
iface = netdev_priv(dev);
local = iface->local;
if (dev == local->ddev) {
prism2_sta_deauth(local, WLAN_REASON_DEAUTH_LEAVING);
}
#ifndef PRISM2_NO_KERN... | 400 |
145,145 | 0 | void GpuProcessHost::DidDestroyOffscreenContext(const GURL& url) {
auto candidate = urls_with_live_offscreen_contexts_.find(url);
if (candidate != urls_with_live_offscreen_contexts_.end()) {
urls_with_live_offscreen_contexts_.erase(candidate);
}
}
| 401 |
164,555 | 0 | int corruptPageError(int lineno, MemPage *p){
char *zMsg;
sqlite3BeginBenignMalloc();
zMsg = sqlite3_mprintf("database corruption page %d of %s",
(int)p->pgno, sqlite3PagerFilename(p->pBt->pPager, 0)
);
sqlite3EndBenignMalloc();
if( zMsg ){
sqlite3ReportError(SQLITE_CORRUPT, lineno, zMsg);
}
s... | 402 |
108,285 | 0 | bool FrameLoader::subframeIsLoading() const
{
for (Frame* child = m_frame->tree()->lastChild(); child; child = child->tree()->previousSibling()) {
FrameLoader* childLoader = child->loader();
DocumentLoader* documentLoader = childLoader->documentLoader();
if (documentLoader && documentLoader-... | 403 |
134,936 | 0 | bool IsVoiceInteractionEnabled() {
return IsVoiceInteractionLocalesSupported() &&
IsVoiceInteractionFlagsEnabled();
}
| 404 |
128,720 | 0 | std::string TemplateURLRef::ReplaceSearchTerms(
const SearchTermsArgs& search_terms_args,
const SearchTermsData& search_terms_data,
PostContent* post_content) const {
ParseIfNecessary(search_terms_data);
if (!valid_)
return std::string();
std::string url(HandleReplacements(search_terms_args, sear... | 405 |
107,141 | 0 | void LayerTreeHostQt::renderNextFrame()
{
m_waitingForUIProcess = false;
scheduleLayerFlush();
}
| 406 |
164,867 | 0 | bool VerifyNoDownloads() const {
DownloadManager::DownloadVector items;
GetDownloads(browser(), &items);
return items.empty();
}
| 407 |
24,685 | 0 | void posix_cpu_timer_get(struct k_itimer *timer, struct itimerspec *itp)
{
union cpu_time_count now;
struct task_struct *p = timer->it.cpu.task;
int clear_dead;
/*
* Easy part: convert the reload time.
*/
sample_to_timespec(timer->it_clock,
timer->it.cpu.incr, &itp->it_interval);
if (timer->it.cpu.exp... | 408 |
18,596 | 0 | long ext4_fallocate(struct file *file, int mode, loff_t offset, loff_t len)
{
struct inode *inode = file->f_path.dentry->d_inode;
handle_t *handle;
loff_t new_size;
unsigned int max_blocks;
int ret = 0;
int ret2 = 0;
int retries = 0;
int flags;
struct ext4_map_blocks map;
unsigned int credits, blkbits = inode... | 409 |
183,593 | 1 | WebPluginResourceClient* WebPluginDelegateImpl::CreateResourceClient(
unsigned long resource_id, const GURL& url, bool notify_needed,
intptr_t notify_data, intptr_t existing_stream) {
// Stream already exists. This typically happens for range requests
// initiated via NPN_RequestRead.
if (existing_stream)... | 410 |
87,482 | 0 | static unsigned generateFixedLitLenTree(HuffmanTree* tree)
{
unsigned i, error = 0;
unsigned* bitlen = (unsigned*)calloc(NUM_DEFLATE_CODE_SYMBOLS, sizeof(unsigned));
if(!bitlen) return 83; /*alloc fail*/
/*288 possible codes: 0-255=literals, 256=endcode, 257-285=lengthcodes, 286-287=unused*/
for(i = 0; i <... | 411 |
82,318 | 0 | NO_INLINE JsVar *jspeBlockOrStatement() {
if (lex->tk=='{') {
jspeBlock();
return 0;
} else {
JsVar *v = jspeStatement();
if (lex->tk==';') JSP_ASSERT_MATCH(';');
return v;
}
}
/** Parse using current lexer until we hit the end of
* input or there was some problem. */
NO_INLINE JsVar *jspPar... | 412 |
25,181 | 0 | static inline int rt_is_expired(struct rtable *rth)
{
return rth->rt_genid != rt_genid(dev_net(rth->dst.dev));
}
| 413 |
124,048 | 0 | bool BookmarksGetFunction::RunImpl() {
scoped_ptr<bookmarks::GetRecent::Params> params(
bookmarks::GetRecent::Params::Create(*args_));
EXTENSION_FUNCTION_VALIDATE(params.get());
if (params->number_of_items < 1)
return false;
std::vector<const BookmarkNode*> nodes;
bookmark_utils::GetMostRecentlyAdd... | 414 |
139,098 | 0 | void CreateUnifiedStream(const url::Origin& security_origin) {
std::string output_id = GetNondefaultIdExpectedToPassPermissionsCheck();
std::string input_id = GetNondefaultInputId();
std::string hashed_output_id = MediaStreamManager::GetHMACForMediaDeviceID(
kSalt, url::Origin(GURL(kSecurityOrigin... | 415 |
7,100 | 0 | tt_cmap14_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
FT_UNUSED( cmap );
/* This can't happen */
*pchar_code = 0;
return 0;
}
| 416 |
27,935 | 0 | static int orinoco_ioctl_set_mlme(struct net_device *dev,
struct iw_request_info *info,
union iwreq_data *wrqu, char *extra)
{
struct orinoco_private *priv = ndev_priv(dev);
struct iw_mlme *mlme = (struct iw_mlme *)extra;
unsigned long flags;
int ret = 0;
if (orinoco_lock(priv, &flags) != 0)
return ... | 417 |
161,034 | 0 | TopDomainEntry IDNSpoofChecker::LookupSkeletonInTopDomains(
const std::string& skeleton) {
DCHECK(!skeleton.empty());
TopDomainPreloadDecoder preload_decoder(
g_trie_params.huffman_tree, g_trie_params.huffman_tree_size,
g_trie_params.trie, g_trie_params.trie_bits,
g_trie_params.trie_root_posit... | 418 |
18,241 | 0 | conn *conn_from_freelist() {
conn *c;
pthread_mutex_lock(&conn_lock);
if (freecurr > 0) {
c = freeconns[--freecurr];
} else {
c = NULL;
}
pthread_mutex_unlock(&conn_lock);
return c;
}
| 419 |
53,565 | 0 | read_Digests(struct archive_read *a, struct _7z_digests *d, size_t num)
{
const unsigned char *p;
unsigned i;
if (num == 0)
return (-1);
memset(d, 0, sizeof(*d));
d->defineds = malloc(num);
if (d->defineds == NULL)
return (-1);
/*
* Read Bools.
*/
if ((p = header_bytes(a, 1)) == NULL)
return (-1);
... | 420 |
176,374 | 0 | static void TransitionElementsKindImpl(Handle<JSObject> object,
Handle<Map> to_map) {
Handle<Map> from_map = handle(object->map());
ElementsKind from_kind = from_map->elements_kind();
ElementsKind to_kind = to_map->elements_kind();
if (IsFastHoleyElementsKind(from_kind)) {
to_kind = GetHoleyElementsKind(to_... | 421 |
131,829 | 0 | static void unsignedLongAttributeAttributeGetterCallback(v8::Local<v8::String>, const v8::PropertyCallbackInfo<v8::Value>& info)
{
TRACE_EVENT_SET_SAMPLING_STATE("Blink", "DOMGetter");
TestObjectPythonV8Internal::unsignedLongAttributeAttributeGetter(info);
TRACE_EVENT_SET_SAMPLING_STATE("V8", "V8Execution")... | 422 |
133,681 | 0 | string cookie_value() {
return decoder_->cookie_value_;
}
| 423 |
113,734 | 0 | GpuProcessHostUIShim::~GpuProcessHostUIShim() {
DCHECK(CalledOnValidThread());
g_hosts_by_id.Pointer()->Remove(host_id_);
DictionaryValue* dict = new DictionaryValue();
dict->SetInteger("level", logging::LOG_ERROR);
dict->SetString("header", "GpuProcessHostUIShim");
dict->SetString("message", "GPU Process ... | 424 |
44,425 | 0 | static bool perms_include(int fmode, mode_t req_mode)
{
mode_t r;
switch (req_mode & O_ACCMODE) {
case O_RDONLY:
r = S_IROTH;
break;
case O_WRONLY:
r = S_IWOTH;
break;
case O_RDWR:
r = S_IROTH | S_IWOTH;
break;
default:
return false;
}
return ((fmode & r) == r);
}
| 425 |
130,378 | 0 | HTMLFormControlElement::~HTMLFormControlElement()
{
#if !ENABLE(OILPAN)
#if ENABLE(ASSERT)
setNeedsWillValidateCheck();
setNeedsValidityCheck();
#endif
setForm(0);
#endif
}
| 426 |
32,752 | 0 | static int tg3_set_pauseparam(struct net_device *dev, struct ethtool_pauseparam *epause)
{
struct tg3 *tp = netdev_priv(dev);
int err = 0;
if (tg3_flag(tp, USE_PHYLIB)) {
u32 newadv;
struct phy_device *phydev;
phydev = tp->mdio_bus->phy_map[TG3_PHY_MII_ADDR];
if (!(phydev->supported & SUPPORTED_Pause) ||
... | 427 |
17,266 | 0 | tt_cmap13_char_next( TT_CMap cmap,
FT_UInt32 *pchar_code )
{
TT_CMap13 cmap13 = (TT_CMap13)cmap;
FT_UInt gindex;
/* no need to search */
if ( cmap13->valid && cmap13->cur_charcode == *pchar_code )
{
tt_cmap13_next( cmap13 );
if ( cmap13->valid )
... | 428 |
20,712 | 0 | void kvm_arch_async_page_ready(struct kvm_vcpu *vcpu, struct kvm_async_pf *work)
{
int r;
if ((vcpu->arch.mmu.direct_map != work->arch.direct_map) ||
is_error_page(work->page))
return;
r = kvm_mmu_reload(vcpu);
if (unlikely(r))
return;
if (!vcpu->arch.mmu.direct_map &&
work->arch.cr3 != vcpu->... | 429 |
3,643 | 0 | static void print_word(BIO *bp, BN_ULONG w)
{
#ifdef SIXTY_FOUR_BIT
if (sizeof(w) > sizeof(unsigned long)) {
unsigned long h = (unsigned long)(w >> 32), l = (unsigned long)(w);
if (h)
BIO_printf(bp, "%lX%08lX", h, l);
else
BIO_printf(bp, "%lX", l);
return;
... | 430 |
160,148 | 0 | void BackendIO::OnIOComplete(int result) {
DCHECK(IsEntryOperation());
DCHECK_NE(result, net::ERR_IO_PENDING);
result_ = result;
NotifyController();
}
| 431 |
65,318 | 0 | nfsd4_clone(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate,
struct nfsd4_clone *clone)
{
struct file *src, *dst;
__be32 status;
status = nfsd4_verify_copy(rqstp, cstate, &clone->cl_src_stateid, &src,
&clone->cl_dst_stateid, &dst);
if (status)
goto out;
status = nfsd4_clone_file_range(src,... | 432 |
154,531 | 0 | GLES2DecoderPassthroughImpl::TexturePendingBinding::TexturePendingBinding(
GLenum target,
GLuint unit,
base::WeakPtr<TexturePassthrough> texture)
: target(target), unit(unit), texture(std::move(texture)) {}
| 433 |
112,099 | 0 | const char* PassphraseRequiredReasonToString(
PassphraseRequiredReason reason) {
switch (reason) {
case REASON_PASSPHRASE_NOT_REQUIRED:
return "REASON_PASSPHRASE_NOT_REQUIRED";
case REASON_ENCRYPTION:
return "REASON_ENCRYPTION";
case REASON_DECRYPTION:
return "REASON_DECRYPTION";
... | 434 |
93,259 | 0 | static inline u16 tun16_to_cpu(struct tun_struct *tun, __virtio16 val)
{
return __virtio16_to_cpu(tun_is_little_endian(tun), val);
}
| 435 |
142,763 | 0 | void HTMLMediaElement::ConfigureTextTrackDisplay() {
DCHECK(text_tracks_);
BLINK_MEDIA_LOG << "configureTextTrackDisplay(" << (void*)this << ")";
if (processing_preference_change_)
return;
bool have_visible_text_track = text_tracks_->HasShowingTracks();
text_tracks_visible_ = have_visible_text_track;
... | 436 |
3,033 | 0 | static int checkMatrixLMN(i_ctx_t * i_ctx_p, ref *CIEdict)
{
int code;
float value[9];
ref *tempref;
code = dict_find_string(CIEdict, "MatrixLMN", &tempref);
if (code > 0 && !r_has_type(tempref, t_null)) {
if (!r_is_array(tempref))
return_error(gs_error_typecheck);
if (r... | 437 |
168,200 | 0 | void WebBluetoothServiceImpl::GattCharacteristicValueChanged(
device::BluetoothAdapter* adapter,
device::BluetoothRemoteGattCharacteristic* characteristic,
const std::vector<uint8_t>& value) {
if (!base::ContainsKey(characteristic_id_to_service_id_,
characteristic->GetIdentifier()... | 438 |
59,472 | 0 | xmlParseDocTypeDecl(xmlParserCtxtPtr ctxt) {
const xmlChar *name = NULL;
xmlChar *ExternalID = NULL;
xmlChar *URI = NULL;
/*
* We know that '<!DOCTYPE' has been detected.
*/
SKIP(9);
SKIP_BLANKS;
/*
* Parse the DOCTYPE name.
*/
name = xmlParseName(ctxt);
if (na... | 439 |
109,250 | 0 | void InspectorOverlay::reset(const IntSize& viewportSize, const IntSize& frameViewFullSize, int scrollX, int scrollY)
{
RefPtr<JSONObject> resetData = JSONObject::create();
resetData->setNumber("pageScaleFactor", m_page->pageScaleFactor());
resetData->setNumber("deviceScaleFactor", m_page->deviceScaleFactor... | 440 |
66,462 | 0 | static void cp2112_remove(struct hid_device *hdev)
{
struct cp2112_device *dev = hid_get_drvdata(hdev);
int i;
sysfs_remove_group(&hdev->dev.kobj, &cp2112_attr_group);
i2c_del_adapter(&dev->adap);
if (dev->gpio_poll) {
dev->gpio_poll = false;
cancel_delayed_work_sync(&dev->gpio_poll_worker);
}
for (i = 0;... | 441 |
185,352 | 1 | void GLSurfaceOzoneSurfacelessSurfaceImpl::Destroy() {
if (!context_)
return;
scoped_refptr<gfx::GLContext> previous_context = gfx::GLContext::GetCurrent();
scoped_refptr<gfx::GLSurface> previous_surface;
bool was_current = previous_context && previous_context->IsCurrent(nullptr) &&
gfx::GLSurface::GetCurrent() == thi... | 442 |
85,839 | 0 | static void __dm_internal_suspend(struct mapped_device *md, unsigned suspend_flags)
{
struct dm_table *map = NULL;
lockdep_assert_held(&md->suspend_lock);
if (md->internal_suspend_count++)
return; /* nested internal suspend */
if (dm_suspended_md(md)) {
set_bit(DMF_SUSPENDED_INTERNALLY, &md->flags);
return... | 443 |
82,941 | 0 | static RList* relocs(RBinFile *bf) {
RList *ret = NULL;
RBinReloc *ptr = NULL;
RBinElfReloc *relocs = NULL;
struct Elf_(r_bin_elf_obj_t) *bin = NULL;
ut64 got_addr;
int i;
if (!bf || !bf->o || !bf->o->bin_obj) {
return NULL;
}
bin = bf->o->bin_obj;
if (!(ret = r_list_newf (free))) {
return NULL;
}
/* FI... | 444 |
141,787 | 0 | std::string ChromeMetricsServiceClient::GetVersionString() {
return metrics::GetVersionString();
}
| 445 |
2,436 | 0 | bool smb2cli_conn_req_possible(struct smbXcli_conn *conn, uint32_t *max_dyn_len)
{
uint16_t credits = 1;
if (conn->smb2.cur_credits == 0) {
if (max_dyn_len != NULL) {
*max_dyn_len = 0;
}
return false;
}
if (conn->smb2.server.capabilities & SMB2_CAP_LARGE_MTU) {
credits = conn->smb2.cur_credits;
}
if... | 446 |
160,517 | 0 | bool WebContentsImpl::OnMessageReceived(RenderFrameHostImpl* render_frame_host,
const IPC::Message& message) {
{
WebUIImpl* web_ui = render_frame_host->web_ui();
if (web_ui && web_ui->OnMessageReceived(message, render_frame_host))
return true;
}
for (auto& ob... | 447 |
132,140 | 0 | ContentClient* RenderViewTest::CreateContentClient() {
return new TestContentClient;
}
| 448 |
180,301 | 1 | void gdImageLine (gdImagePtr im, int x1, int y1, int x2, int y2, int color)
{
int dx, dy, incr1, incr2, d, x, y, xend, yend, xdirflag, ydirflag;
int wid;
int w, wstart;
int thick = im->thick;
if (color == gdAntiAliased) {
/*
gdAntiAliased passed as color: use the much faster, much cheaper
and equally attractive gdI... | 449 |
151,066 | 0 | bool FindInspectedBrowserAndTabIndex(
WebContents* inspected_web_contents, Browser** browser, int* tab) {
if (!inspected_web_contents)
return false;
for (auto* b : *BrowserList::GetInstance()) {
int tab_index =
b->tab_strip_model()->GetIndexOfWebContents(inspected_web_contents);
if (tab_ind... | 450 |
77,939 | 0 | DestroyJNG(unsigned char *chunk,Image **color_image,
ImageInfo **color_image_info,Image **alpha_image,ImageInfo **alpha_image_info)
{
(void) RelinquishMagickMemory(chunk);
if (color_image_info && *color_image_info)
{
DestroyImageInfo(*color_image_info);
*color_image_info = (ImageInfo *)NULL;
}
if (a... | 451 |
11,544 | 0 | bool ignore_file(const char *filename) {
assert(filename);
return
filename[0] == '.' ||
streq(filename, "lost+found") ||
streq(filename, "aquota.user") ||
streq(filename, "aquota.group") ||
endswith(filename, "~") ||
... | 452 |
76,147 | 0 | alloc_value_block(void (*alloc_func) (vector_t *), const char *block_type)
{
char *buf;
char *str = NULL;
vector_t *vec = NULL;
bool first_line = true;
buf = (char *) MALLOC(MAXBUF);
while (read_line(buf, MAXBUF)) {
if (!(vec = alloc_strvec(buf)))
continue;
if (first_line) {
first_line = false;
if... | 453 |
68,007 | 0 | static MagickBooleanType load_tile_rle(Image *image,Image *tile_image,
XCFDocInfo *inDocInfo,XCFLayerInfo *inLayerInfo,size_t data_length)
{
ExceptionInfo
*exception;
MagickOffsetType
size;
Quantum
alpha;
register PixelPacket
*q;
size_t
length;
ssize_t
bytes_per_pixel,
cou... | 454 |
19,643 | 0 | GC_INNER void * GC_generic_malloc_inner(size_t lb, int k)
{
void *op;
if(SMALL_OBJ(lb)) {
struct obj_kind * kind = GC_obj_kinds + k;
size_t lg = GC_size_map[lb];
void ** opp = &(kind -> ok_freelist[lg]);
op = *opp;
if (EXPECT(0 == op, FALSE)) {
if (GC_size_m... | 455 |
22,239 | 0 | struct net_device *rose_dev_get(rose_address *addr)
{
struct net_device *dev;
rcu_read_lock();
for_each_netdev_rcu(&init_net, dev) {
if ((dev->flags & IFF_UP) && dev->type == ARPHRD_ROSE && rosecmp(addr, (rose_address *)dev->dev_addr) == 0) {
dev_hold(dev);
goto out;
}
}
dev = NULL;
out:
rcu_read_unloc... | 456 |
32,300 | 0 | static struct ext4_dir_entry_tail *get_dirent_tail(struct inode *inode,
struct ext4_dir_entry *de)
{
struct ext4_dir_entry_tail *t;
#ifdef PARANOID
struct ext4_dir_entry *d, *top;
d = de;
top = (struct ext4_dir_entry *)(((void *)de) +
(EXT4_BLOCK_SIZE(inode->i_sb) -
sizeof(struct ext4_dir_entry_tail)... | 457 |
185,538 | 1 | void XSSAuditor::init(Document* document, XSSAuditorDelegate* auditorDelegate)
{
const size_t miniumLengthForSuffixTree = 512; // FIXME: Tune this parameter.
const int suffixTreeDepth = 5;
ASSERT(isMainThread());
if (m_state != Uninitialized)
return;
m_state = FilteringTokens;
if (Settings* settings = document->setti... | 458 |
24,532 | 0 | static int b43_dma_set_mask(struct b43_wldev *dev, u64 mask)
{
u64 orig_mask = mask;
bool fallback = 0;
int err;
/* Try to set the DMA mask. If it fails, try falling back to a
* lower mask, as we can always also support a lower one. */
while (1) {
err = dma_set_mask(dev->dev->dma_dev, mask);
if (!err) {
... | 459 |
4,540 | 0 | static int X509_get_signature_nid(const X509 *x)
{
return OBJ_obj2nid(x->sig_alg->algorithm);
}
| 460 |
38,094 | 0 | static void stop_command_port(struct usb_serial *serial)
{
struct usb_serial_port *command_port;
struct whiteheat_command_private *command_info;
command_port = serial->port[COMMAND_PORT];
command_info = usb_get_serial_port_data(command_port);
mutex_lock(&command_info->mutex);
command_info->port_running--;
if (!... | 461 |
180,532 | 1 | static int cypress_open(struct tty_struct *tty, struct usb_serial_port *port)
{
struct cypress_private *priv = usb_get_serial_port_data(port);
struct usb_serial *serial = port->serial;
unsigned long flags;
int result = 0;
if (!priv->comm_is_ok)
return -EIO;
/* clear halts before open */
usb_clear_halt(serial->dev, 0x... | 462 |
53,985 | 0 | void ndp_set_log_priority(struct ndp *ndp, int priority)
{
ndp->log_priority = priority;
}
| 463 |
163,228 | 0 | NavigationLogger(WebContents* web_contents)
: WebContentsObserver(web_contents) {}
| 464 |
107,670 | 0 | const char* ewk_view_theme_get(const Evas_Object* ewkView)
{
EWK_VIEW_SD_GET_OR_RETURN(ewkView, smartData, 0);
EWK_VIEW_PRIV_GET_OR_RETURN(smartData, priv, 0);
return priv->settings.theme;
}
| 465 |
84,494 | 0 | escdmap(char c)
{
int d;
d = (int)c - (int)'0';
c = getch();
if (IS_DIGIT(c)) {
d = d * 10 + (int)c - (int)'0';
c = getch();
}
if (c == '~')
escKeyProc((int)d, K_ESCD, EscDKeymap);
}
| 466 |
63,250 | 0 | void _WM_do_meta_smpteoffset(struct _mdi *mdi, struct _event_data *data) {
/* placeholder function so we can record tempo in the event stream
* for conversion function _WM_Event2Midi */
#ifdef DEBUG_MIDI
uint8_t ch = data->channel;
MIDI_EVENT_DEBUG(__FUNCTION__, ch, data->data.value);
#else
UNUSED(data);
#... | 467 |
175,601 | 0 | status_t NuMediaExtractor::setDataSource(int fd, off64_t offset, off64_t size) {
ALOGV("setDataSource fd=%d (%s), offset=%lld, length=%lld",
fd, nameForFd(fd).c_str(), (long long) offset, (long long) size);
Mutex::Autolock autoLock(mLock);
if (mImpl != NULL) {
return -EINVAL;
}
sp<FileSource... | 468 |
104,416 | 0 | GLvoid StubGLBufferData(GLenum target, GLsizeiptr size, const void* data,
GLenum usage) {
glBufferData(target, size, data, usage);
}
| 469 |
94,876 | 0 | static int __usbnet_status_start_force(struct usbnet *dev, gfp_t mem_flags)
{
int ret = 0;
mutex_lock(&dev->interrupt_mutex);
if (dev->interrupt_count) {
ret = usb_submit_urb(dev->interrupt, mem_flags);
dev_dbg(&dev->udev->dev,
"submitted interrupt URB for resume\n");
}
mutex_unlock(&dev->interrupt_mutex);... | 470 |
105,215 | 0 | bool shouldApplyWrappingStyle(Node* node) const
{
return m_highestNodeToBeSerialized && m_highestNodeToBeSerialized->parentNode() == node->parentNode()
&& m_wrappingStyle && m_wrappingStyle->style();
}
| 471 |
112,015 | 0 | bool SyncTest::TearDownLocalPythonTestServer() {
if (!sync_server_.Stop()) {
LOG(ERROR) << "Could not stop local python test server.";
return false;
}
xmpp_port_.reset();
return true;
}
| 472 |
41,708 | 0 | static void free_async_extent_pages(struct async_extent *async_extent)
{
int i;
if (!async_extent->pages)
return;
for (i = 0; i < async_extent->nr_pages; i++) {
WARN_ON(async_extent->pages[i]->mapping);
page_cache_release(async_extent->pages[i]);
}
kfree(async_extent->pages);
async_extent->nr_pages = 0;
... | 473 |
110,459 | 0 | void GLES2DecoderImpl::DoBufferData(
GLenum target, GLsizeiptr size, const GLvoid * data, GLenum usage) {
if (!validators_->buffer_target.IsValid(target)) {
SetGLErrorInvalidEnum("glBufferData", target, "target");
return;
}
if (!validators_->buffer_usage.IsValid(usage)) {
SetGLErrorInvalidEnum("gl... | 474 |
133,340 | 0 | void TestPaletteDelegate::CreateNote() {
++create_note_count_;
}
| 475 |
91,017 | 0 | void CWebServer::Cmd_SetUnused(WebEmSession & session, const request& req, Json::Value &root)
{
if (session.rights != 2)
{
session.reply_status = reply::forbidden;
return; //Only admin user allowed
}
std::string sidx = request::findValue(&req, "idx");
if (sidx.empty())
return;
int idx... | 476 |
79,659 | 0 | static char *convert_string(const char *bytes, ut32 len) {
ut32 idx = 0, pos = 0;
ut32 str_sz = 32 * len + 1;
char *cpy_buffer = len > 0 ? malloc (str_sz) : NULL;
if (!cpy_buffer) {
return cpy_buffer;
}
memset (cpy_buffer, 0, str_sz);
while (idx < len && pos < len) {
if (dso_json_char_needs_hexing (bytes[idx... | 477 |
12,627 | 0 | DEFUN (show_ip_bgp_vpnv4_all_neighbor_advertised_routes,
show_ip_bgp_vpnv4_all_neighbor_advertised_routes_cmd,
"show ip bgp vpnv4 all neighbors A.B.C.D advertised-routes",
SHOW_STR
IP_STR
BGP_STR
"Display VPNv4 NLRI specific information\n"
"Display information about all ... | 478 |
80,802 | 0 | GF_Err mvhd_dump(GF_Box *a, FILE * trace)
{
GF_MovieHeaderBox *p;
p = (GF_MovieHeaderBox *) a;
gf_isom_box_dump_start(a, "MovieHeaderBox", trace);
fprintf(trace, "CreationTime=\""LLD"\" ", LLD_CAST p->creationTime);
fprintf(trace, "ModificationTime=\""LLD"\" ", LLD_CAST p->modificationTime);
fprintf(trace, "Tim... | 479 |
53,187 | 0 | static struct async *async_getcompleted(struct usb_dev_state *ps)
{
unsigned long flags;
struct async *as = NULL;
spin_lock_irqsave(&ps->lock, flags);
if (!list_empty(&ps->async_completed)) {
as = list_entry(ps->async_completed.next, struct async,
asynclist);
list_del_init(&as->asynclist);
}
spin_unlock_... | 480 |
170,738 | 0 | status_t OMXNodeInstance::getState(OMX_STATETYPE* state) {
Mutex::Autolock autoLock(mLock);
OMX_ERRORTYPE err = OMX_GetState(mHandle, state);
CLOG_IF_ERROR(getState, err, "");
return StatusFromOMXError(err);
}
| 481 |
173,512 | 0 | OMX_ERRORTYPE omx_vdec::use_android_native_buffer(OMX_IN OMX_HANDLETYPE hComp, OMX_PTR data)
{
DEBUG_PRINT_LOW("Inside use_android_native_buffer");
OMX_ERRORTYPE eRet = OMX_ErrorNone;
UseAndroidNativeBufferParams *params = (UseAndroidNativeBufferParams *)data;
if ((params == NULL) ||
(params->nativeBuffer =... | 482 |
154,407 | 0 | SamplerManager* sampler_manager() {
return group_->sampler_manager();
}
| 483 |
105,000 | 0 | const char* HttpBridge::GetResponseContent() const {
DCHECK_EQ(MessageLoop::current(), created_on_loop_);
base::AutoLock lock(fetch_state_lock_);
DCHECK(fetch_state_.request_completed);
return fetch_state_.response_content.data();
}
| 484 |
22,742 | 0 | static int __udp6_lib_mcast_deliver(struct net *net, struct sk_buff *skb,
struct in6_addr *saddr, struct in6_addr *daddr,
struct udp_table *udptable)
{
struct sock *sk, *stack[256 / sizeof(struct sock *)];
const struct udphdr *uh = udp_hdr(skb);
struct udp_hslot *hslot = udp_hashslot(udptable, net, ntohs(uh->des... | 485 |
174,257 | 0 | status_t Camera3Device::RequestThread::removeTriggers(
const sp<CaptureRequest> &request) {
Mutex::Autolock al(mTriggerMutex);
CameraMetadata &metadata = request->mSettings;
/**
* Replace all old entries with their old values.
*/
for (size_t i = 0; i < mTriggerReplacedMap.size(); ++i) {
RequestTrigger... | 486 |
70,064 | 0 | int restartServer(int flags, mstime_t delay) {
int j;
/* Check if we still have accesses to the executable that started this
* server instance. */
if (access(server.executable,X_OK) == -1) return C_ERR;
/* Config rewriting. */
if (flags & RESTART_SERVER_CONFIG_REWRITE &&
server.config... | 487 |
75,539 | 0 | static unsigned usb_bus_is_wusb(struct usb_bus *bus)
{
struct usb_hcd *hcd = bus_to_hcd(bus);
return hcd->wireless;
}
| 488 |
46,745 | 0 | static int cbc_encrypt(struct blkcipher_desc *desc,
struct scatterlist *dst, struct scatterlist *src,
unsigned int nbytes)
{
struct camellia_sparc64_ctx *ctx = crypto_blkcipher_ctx(desc->tfm);
struct blkcipher_walk walk;
cbc_crypt_op *op;
const u64 *key;
int err;
op = camellia_sparc64_cbc_encry... | 489 |
27,477 | 0 | static inline struct ip_tunnel **ipgre_bucket(struct ipgre_net *ign,
struct ip_tunnel *t)
{
return __ipgre_bucket(ign, &t->parms);
}
| 490 |
11,911 | 0 | int CMS_RecipientInfo_ktri_get0_signer_id(CMS_RecipientInfo *ri,
ASN1_OCTET_STRING **keyid,
X509_NAME **issuer,
ASN1_INTEGER **sno)
{
CMS_KeyTransRecipientInfo *ktri;
if (ri->type != CMS... | 491 |
111,435 | 0 | WebPage::~WebPage()
{
deleteGuardedObject(d);
d = 0;
}
| 492 |
114,292 | 0 | void WebGraphicsContext3DCommandBufferImpl::copyTextureToParentTextureCHROMIUM(
WebGLId texture, WebGLId parentTexture) {
NOTIMPLEMENTED();
}
| 493 |
27,335 | 0 | static void ip4_frag_init(struct inet_frag_queue *q, void *a)
{
struct ipq *qp = container_of(q, struct ipq, q);
struct ip4_create_arg *arg = a;
qp->protocol = arg->iph->protocol;
qp->id = arg->iph->id;
qp->ecn = ip4_frag_ecn(arg->iph->tos);
qp->saddr = arg->iph->saddr;
qp->daddr = arg->iph->daddr;
qp->user = ... | 494 |
65,194 | 0 | static void grace_ender(struct work_struct *grace)
{
struct delayed_work *dwork = to_delayed_work(grace);
struct lockd_net *ln = container_of(dwork, struct lockd_net,
grace_period_end);
locks_end_grace(&ln->lockd_manager);
}
| 495 |
49,487 | 0 | static void hid_device_release(struct device *dev)
{
struct hid_device *hid = to_hid_device(dev);
hid_close_report(hid);
kfree(hid->dev_rdesc);
kfree(hid);
}
| 496 |
171,496 | 0 | WORD32 ih264d_set_flush_mode(iv_obj_t *dec_hdl, void *pv_api_ip, void *pv_api_op)
{
dec_struct_t * ps_dec;
ivd_ctl_flush_op_t *ps_ctl_op = (ivd_ctl_flush_op_t*)pv_api_op;
ps_ctl_op->u4_error_code = 0;
ps_dec = (dec_struct_t *)(dec_hdl->pv_codec_handle);
UNUSED(pv_api_ip);
/* ! */
/* Signal flush frame ... | 497 |
66,076 | 0 | static void edge_heartbeat_schedule(struct edgeport_serial *edge_serial)
{
if (!edge_serial->use_heartbeat)
return;
schedule_delayed_work(&edge_serial->heartbeat_work,
FW_HEARTBEAT_SECS * HZ);
}
| 498 |
178,263 | 1 | my_object_dict_of_dicts (MyObject *obj, GHashTable *in,
GHashTable **out, GError **error)
{
*out = g_hash_table_new_full (g_str_hash, g_str_equal,
(GDestroyNotify) g_free,
(GDestroyNotify) g_hash_table_destroy);
g_hash_table_foreach (in, hash_forea... | 499 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.