unique_id
int64
13
189k
target
int64
0
1
code
stringlengths
20
241k
__index_level_0__
int64
0
18.9k
76,797
0
decode_NXAST_RAW_EXIT(struct ofpbuf *out) { ofpact_put_EXIT(out); return 0; }
12,900
4,340
0
_zip_dirent_init(struct zip_dirent *de) { de->version_madeby = 0; de->version_needed = 20; /* 2.0 */ de->bitflags = 0; de->comp_method = 0; de->last_mod = 0; de->crc = 0; de->comp_size = 0; de->uncomp_size = 0; de->filename = NULL; de->filename_len = 0; de->extrafield = NULL;...
12,901
155,235
0
bool HTMLFormElement::noValidate() const { return fastHasAttribute(novalidateAttr); }
12,902
37,330
0
static struct sctp_packet *sctp_ootb_pkt_new(struct net *net, const struct sctp_association *asoc, const struct sctp_chunk *chunk) { struct sctp_packet *packet; struct sctp_transport *transport; __u16 sport; __u16 dport; __u32 vtag; /* Get the source and destination port from the inbound pack...
12,903
167,231
0
std::unique_ptr<infobars::InfoBar> InfoBarService::CreateConfirmInfoBar( std::unique_ptr<ConfirmInfoBarDelegate> delegate) { #if defined(OS_MACOSX) if (views_mode_controller::IsViewsBrowserCocoa()) return InfoBarService::CreateConfirmInfoBarCocoa(std::move(delegate)); #endif return std::make_unique<ConfirmI...
12,904
80,949
0
static int handle_ept_misconfig(struct kvm_vcpu *vcpu) { gpa_t gpa; /* * A nested guest cannot optimize MMIO vmexits, because we have an * nGPA here instead of the required GPA. */ gpa = vmcs_read64(GUEST_PHYSICAL_ADDRESS); if (!is_guest_mode(vcpu) && !kvm_io_bus_write(vcpu, KVM_FAST_MMIO_BUS, gpa, 0, N...
12,905
2,860
0
ProcShmAttach(ClientPtr client) { SHMSTAT_TYPE buf; ShmDescPtr shmdesc; REQUEST(xShmAttachReq); REQUEST_SIZE_MATCH(xShmAttachReq); LEGAL_NEW_RESOURCE(stuff->shmseg, client); if ((stuff->readOnly != xTrue) && (stuff->readOnly != xFalse)) { client->errorValue = stuff->readOnly; r...
12,906
89,807
0
int OpenAndConfPCPv6Socket(void) { int s; int i = 1; struct sockaddr_in6 addr; s = socket(PF_INET6, SOCK_DGRAM, 0/*IPPROTO_UDP*/); if(s < 0) { syslog(LOG_ERR, "%s: socket(): %m", "OpenAndConfPCPv6Socket"); return -1; } if(setsockopt(s, SOL_SOCKET, SO_REUSEADDR, &i, sizeof(i)) < 0) { syslog(LOG_WARNING, "%s...
12,907
64,219
0
static void core_child_init(apr_pool_t *pchild, server_rec *s) { apr_proc_t proc; #if APR_HAS_THREADS int threaded_mpm; if (ap_mpm_query(AP_MPMQ_IS_THREADED, &threaded_mpm) == APR_SUCCESS && threaded_mpm) { apr_thread_mutex_create(&rng_mutex, APR_THREAD_MUTEX_DEFAULT, pchild); } #end...
12,908
56,967
0
static size_t fuse_send_read(struct fuse_req *req, struct fuse_io_priv *io, loff_t pos, size_t count, fl_owner_t owner) { struct file *file = io->file; struct fuse_file *ff = file->private_data; struct fuse_conn *fc = ff->fc; fuse_read_fill(req, file, pos, count, FUSE_READ); if (owner != NULL) { struct ...
12,909
179,798
1
static int __driver_rfc4106_decrypt(struct aead_request *req) { u8 one_entry_in_sg = 0; u8 *src, *dst, *assoc; unsigned long tempCipherLen = 0; __be32 counter = cpu_to_be32(1); int retval = 0; struct crypto_aead *tfm = crypto_aead_reqtfm(req); struct aesni_rfc4106_gcm_ctx *ctx = aesni_rfc4106_gcm_ctx_get(tfm); u32 key_...
12,910
94,613
0
static void iov_fault_in_pages_read(struct iovec *iov, unsigned long len) { while (!iov->iov_len) iov++; while (len > 0) { unsigned long this_len; this_len = min_t(unsigned long, len, iov->iov_len); fault_in_pages_readable(iov->iov_base, this_len); len -= this_len; iov++; } }
12,911
184,384
1
void HostPortAllocatorSession::OnSessionRequestDone( UrlFetcher* url_fetcher, const net::URLRequestStatus& status, int response_code, const std::string& response) { url_fetchers_.erase(url_fetcher); delete url_fetcher; if (response_code != net::HTTP_OK) { LOG(WARNING) << "Received error when allo...
12,912
126,446
0
void BrowserWindowGtk::UpdateDevTools() { UpdateDevToolsForContents(chrome::GetActiveWebContents(browser_.get())); }
12,913
160,476
0
void RenderFrameHostImpl::RegisterMojoInterfaces() { #if !defined(OS_ANDROID) registry_->AddInterface(base::Bind(&InstalledAppProviderImplDefault::Create)); #endif // !defined(OS_ANDROID) PermissionManager* permission_manager = GetProcess()->GetBrowserContext()->GetPermissionManager(); if (delegate_) { ...
12,914
148,050
0
static void VoidMethodDefaultDoubleArgMethod(const v8::FunctionCallbackInfo<v8::Value>& info) { ExceptionState exception_state(info.GetIsolate(), ExceptionState::kExecutionContext, "TestObject", "voidMethodDefaultDoubleArg"); TestObject* impl = V8TestObject::ToImpl(info.Holder()); double default_double_arg; i...
12,915
40,873
0
static JSON_INLINE void list_insert(list_t *list, list_t *node) { node->next = list; node->prev = list->prev; list->prev->next = node; list->prev = node; }
12,916
56,970
0
static int fuse_setlk(struct file *file, struct file_lock *fl, int flock) { struct inode *inode = file_inode(file); struct fuse_conn *fc = get_fuse_conn(inode); FUSE_ARGS(args); struct fuse_lk_in inarg; int opcode = (fl->fl_flags & FL_SLEEP) ? FUSE_SETLKW : FUSE_SETLK; pid_t pid = fl->fl_type != F_UNLCK ? current...
12,917
55,411
0
static bool tcp_syn_flood_action(const struct sock *sk, const struct sk_buff *skb, const char *proto) { struct request_sock_queue *queue = &inet_csk(sk)->icsk_accept_queue; const char *msg = "Dropping request"; bool want_cookie = false; #ifdef CONFIG_SYN_COOKIES if (sysctl_tcp_syncookies) { msg = "Send...
12,918
28,749
0
int kvm_apic_has_interrupt(struct kvm_vcpu *vcpu) { struct kvm_lapic *apic = vcpu->arch.apic; int highest_irr; if (!kvm_vcpu_has_lapic(vcpu) || !apic_enabled(apic)) return -1; apic_update_ppr(apic); highest_irr = apic_find_highest_irr(apic); if ((highest_irr == -1) || ((highest_irr & 0xF0) <= kvm_apic_ge...
12,919
154,155
0
uint32_t GetCompressedFormatRowPitch(const CompressedFormatInfo& info, uint32_t width) { uint32_t num_blocks_wide = (width + info.block_size - 1) / info.block_size; return num_blocks_wide * info.bytes_per_block; }
12,920
89,413
0
static void event_nick_collision(IRC_SERVER_REC *server, const char *data) { time_t new_connect; if (!IS_IRC_SERVER(server)) return; /* after server kills us because of nick collision, we want to connect back immediately. but no matter how hard they kill us, don't connect to the server more than once in ...
12,921
155,499
0
void DataReductionProxySettings::ClearDataSavingStatistics( DataReductionProxySavingsClearedReason reason) { DCHECK(thread_checker_.CalledOnValidThread()); DCHECK(data_reduction_proxy_service_->compression_stats()); data_reduction_proxy_service_->compression_stats()->ClearDataSavingStatistics( reason); ...
12,922
60,629
0
int snd_seq_port_connect(struct snd_seq_client *connector, struct snd_seq_client *src_client, struct snd_seq_client_port *src_port, struct snd_seq_client *dest_client, struct snd_seq_client_port *dest_port, struct snd_seq_port_subscribe *info) { struct snd_seq_subscribers *subs; bool exclusive; i...
12,923
154,424
0
bool GLES2DecoderPassthroughImpl::CheckErrorCallbackState() { bool had_error_ = had_error_callback_; had_error_callback_ = false; if (had_error_) { FlushErrors(); } return had_error_; }
12,924
156,875
0
DocumentInit DocumentInit::Create() { return DocumentInit(nullptr); }
12,925
133,610
0
void WebContentsImpl::OnPluginCrashed(const base::FilePath& plugin_path, base::ProcessId plugin_pid) { FOR_EACH_OBSERVER(WebContentsObserver, observers_, PluginCrashed(plugin_path, plugin_pid)); }
12,926
145,843
0
HeadlessDevToolsManagerDelegate::NetworkDisable( content::DevToolsAgentHost* agent_host, int session_id, int command_id, const base::DictionaryValue* params) { HeadlessBrowserContextImpl* browser_context = static_cast<HeadlessBrowserContextImpl*>( browser_->GetDefaultBrowserContext());...
12,927
161,440
0
void StorageHandler::NotifyCacheStorageContentChanged(const std::string& origin, const std::string& name) { DCHECK_CURRENTLY_ON(BrowserThread::UI); frontend_->CacheStorageContentUpdated(origin, name); }
12,928
167,088
0
bool BluetoothSocketListenUsingRfcommFunction::CreateParams() { params_ = bluetooth_socket::ListenUsingRfcomm::Params::Create(*args_); return params_ != nullptr; }
12,929
106,621
0
void WebPageProxy::setCustomUserAgent(const String& customUserAgent) { if (m_customUserAgent == customUserAgent) return; m_customUserAgent = customUserAgent; if (m_customUserAgent.isEmpty()) { setUserAgent(standardUserAgent(m_applicationNameForUserAgent)); return; } setUse...
12,930
110,622
0
void GLES2DecoderImpl::ReleaseIOSurfaceForTexture(GLuint texture_id) { TextureToIOSurfaceMap::iterator it = texture_to_io_surface_map_.find( texture_id); if (it != texture_to_io_surface_map_.end()) { CFTypeRef surface = it->second; CFRelease(surface); texture_to_io_surface_map_.erase(it); } }
12,931
82,417
0
char *jsvGetFlatStringPointer(JsVar *v) { assert(jsvIsFlatString(v)); if (!jsvIsFlatString(v)) return 0; return (char*)(v+1); // pointer to the next JsVar }
12,932
128,518
0
void ShellSurface::UpdateWidgetBounds() { DCHECK(widget_); if (widget_->IsMaximized() || widget_->IsFullscreen() || IsResizing()) return; if (!pending_configs_.empty() || scoped_configure_) return; gfx::Rect visible_bounds = GetVisibleBounds(); gfx::Rect new_widget_bounds = visible_bounds; if (i...
12,933
70,381
0
jas_mb_t *jas_get_mb(void *ptr) { return JAS_CAST(jas_mb_t *, JAS_CAST(max_align_t *, ptr) - JAS_MB_ADJUST); }
12,934
120,224
0
static Layer* FindFirstScrollableLayer(Layer* layer) { if (!layer) return NULL; if (layer->scrollable()) return layer; for (size_t i = 0; i < layer->children().size(); ++i) { Layer* found = FindFirstScrollableLayer(layer->children()[i].get()); if (found) return found; } return NULL; }...
12,935
85,743
0
static struct config_group *o2nm_cluster_group_make_group(struct config_group *group, const char *name) { struct o2nm_cluster *cluster = NULL; struct o2nm_node_group *ns = NULL; struct config_group *o2hb_group = NULL, *ret = NULL; /* this runs under the parent dir's i_mutex; there can be only * one call...
12,936
65,189
0
int udpv6_offload_init(void) { return inet6_add_offload(&udpv6_offload, IPPROTO_UDP); }
12,937
184,839
1
void AppLauncherHandler::FillAppDictionary(base::DictionaryValue* dictionary) { // CreateAppInfo and ClearOrdinals can change the extension prefs. base::AutoReset<bool> auto_reset(&ignore_changes_, true); base::ListValue* list = new base::ListValue(); Profile* profile = Profile::FromWebUI(web_ui()); PrefService* prefs...
12,938
35,006
0
static int sctp_getsockopt_adaptation_layer(struct sock *sk, int len, char __user *optval, int __user *optlen) { struct sctp_setadaptation adaptation; if (len != sizeof(struct sctp_setadaptation)) return -EINVAL; adaptation.ssb_adaptation_ind = sctp_sk(sk)->adaptation_ind; if (copy_to_user(optval, &adapta...
12,939
68,328
0
static bool is_orphaned_event(struct perf_event *event) { return event->state == PERF_EVENT_STATE_DEAD; }
12,940
14,596
0
sd_source_prepare (GSource *source, gint *timeout) { *timeout = -1; return FALSE; }
12,941
17,362
0
set_pwd () { SHELL_VAR *temp_var, *home_var; char *temp_string, *home_string; home_var = find_variable ("HOME"); home_string = home_var ? value_cell (home_var) : (char *)NULL; temp_var = find_variable ("PWD"); if (temp_var && imported_p (temp_var) && (temp_string = value_cell (temp_var)) && sa...
12,942
186,942
1
void ServiceWorkerPaymentInstrument::OnPaymentAppInvoked( mojom::PaymentHandlerResponsePtr response) { DCHECK(delegate_); if (delegate_ != nullptr) { delegate_->OnInstrumentDetailsReady(response->method_name, response->stringified_details); delegate_ = nullptr; } }
12,943
51,748
0
dissect_rpcap_filterbpf_insn (tvbuff_t *tvb, packet_info *pinfo _U_, proto_tree *parent_tree, gint offset) { proto_tree *tree, *code_tree; proto_item *ti, *code_ti; guint8 inst_class; ti = proto_tree_add_item (parent_tree, hf_filterbpf_insn, tvb, offset, 8, ENC_NA); tree = proto...
12,944
114,542
0
WebPluginAcceleratedSurface* WebPluginProxy::GetAcceleratedSurface( gfx::GpuPreference gpu_preference) { if (!accelerated_surface_.get()) accelerated_surface_.reset( WebPluginAcceleratedSurfaceProxy::Create(this, gpu_preference)); return accelerated_surface_.get(); }
12,945
125,294
0
RenderViewImpl::~RenderViewImpl() { history_page_ids_.clear(); if (decrement_shared_popup_at_destruction_) shared_popup_counter_->data--; while (!file_chooser_completions_.empty()) { if (file_chooser_completions_.front()->completion) { file_chooser_completions_.front()->completion->didChooseFile( ...
12,946
132,895
0
SharedQuadState* CreateSharedQuadState(RenderPass* render_pass) { gfx::Transform quad_transform = gfx::Transform(1.0, 0.0, 0.5, 1.0, 0.5, 0.0); gfx::Size content_bounds(26, 28); gfx::Rect visible_content_rect(10, 12, 14, 16); gfx::Rect clip_rect(19, 21, 23, 25); bool is_clipped = false; float opacity = 1.f;...
12,947
148,190
0
void V8TestObject::VoidMethodUnsignedShortArgMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) { RUNTIME_CALL_TIMER_SCOPE_DISABLED_BY_DEFAULT(info.GetIsolate(), "Blink_TestObject_voidMethodUnsignedShortArg"); test_object_v8_internal::VoidMethodUnsignedShortArgMethod(info); }
12,948
60,848
0
logger_write_line (struct t_logger_buffer *logger_buffer, const char *format, ...) { char *message, buf_time[256], buf_beginning[1024]; const char *charset; time_t seconds; struct tm *date_tmp; int log_level; charset = weechat_info_get ("charset_terminal", ""); if (!logg...
12,949
11,589
0
daemon_linux_lvm2_lv_set_name_authorized_cb (Daemon *daemon, Device *device, DBusGMethodInvocation *context, const gchar *action_id, guint n...
12,950
15,044
0
PHP_FUNCTION(dom_document_create_entity_reference) { zval *id; xmlNode *node; xmlDocPtr docp = NULL; dom_object *intern; int ret, name_len; char *name; if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Os", &id, dom_document_class_entry, &name, &name_len) == FAILURE) { return; } DOM_G...
12,951
167,373
0
void RequestFaviconSyncForPageURL(const GURL& page_url) { base::RunLoop run_loop; quit_closure_ = run_loop.QuitClosure(); favicon_service_->GetRawFaviconForPageURL( page_url, {favicon_base::IconType::kFavicon}, gfx::kFaviconSize, /*fallback_to_host=*/false, base::Bind(&RemoveFavico...
12,952
78,604
0
pgp_put_data_plain(sc_card_t *card, unsigned int tag, const u8 *buf, size_t buf_len) { struct pgp_priv_data *priv = DRVDATA(card); sc_apdu_t apdu; u8 ins = 0xDA; u8 p1 = tag >> 8; u8 p2 = tag & 0xFF; u8 apdu_case = (card->type == SC_CARD_TYPE_OPENPGP_GNUK) ? SC_APDU_CASE_3_SHORT : SC_APDU_CASE_3; int r; LOG...
12,953
84,457
0
_movR(int n) { int i, m = searchKeyNum(); if (Currentbuf->firstLine == NULL) return; for (i = 0; i < m; i++) cursorRight(Currentbuf, n); displayBuffer(Currentbuf, B_NORMAL); }
12,954
84,444
0
DEFUN(ldBmark, BOOKMARK VIEW_BOOKMARK, "View bookmarks") { cmd_loadURL(BookmarkFile, NULL, NO_REFERER, NULL); }
12,955
164,449
0
static int accessPayload( BtCursor *pCur, /* Cursor pointing to entry to read from */ u32 offset, /* Begin reading this far into payload */ u32 amt, /* Read this many bytes */ unsigned char *pBuf, /* Write the bytes into this buffer */ int eOp /* zero to read. non-zero t...
12,956
31,317
0
static int crypto_pcomp_report(struct sk_buff *skb, struct crypto_alg *alg) { return -ENOSYS; }
12,957
135,897
0
void TextTrackCue::CueWillChange() { if (track_) track_->CueWillChange(this); }
12,958
119,307
0
bool TranslateInfoBarDelegate::ShouldShowNeverTranslateShortcut() { DCHECK_EQ(translate::TRANSLATE_STEP_BEFORE_TRANSLATE, step_); return !GetWebContents()->GetBrowserContext()->IsOffTheRecord() && (prefs_->GetTranslationDeniedCount(original_language_code()) >= kNeverTranslateMinCount); }
12,959
49,198
0
static int packet_rcv_vnet(struct msghdr *msg, const struct sk_buff *skb, size_t *len) { struct virtio_net_hdr vnet_hdr; if (*len < sizeof(vnet_hdr)) return -EINVAL; *len -= sizeof(vnet_hdr); if (__packet_rcv_vnet(skb, &vnet_hdr)) return -EINVAL; return memcpy_to_msg(msg, (void *)&vnet_hdr, sizeof(vne...
12,960
3,368
0
static void *edid_load(struct drm_connector *connector, const char *name, const char *connector_name) { const struct firmware *fw = NULL; const u8 *fwdata; u8 *edid; int fwsize, builtin; int i, valid_extensions = 0; bool print_bad_edid = !connector->bad_edid_counter || (drm_debug & DRM_UT_KMS); builtin = mat...
12,961
110,068
0
bool HTMLSelectElement::shouldShowFocusRingOnMouseFocus() const { return true; }
12,962
142,466
0
void ShelfLayoutManager::OnOverviewModeStartingAnimationComplete( bool canceled) { UpdateVisibilityState(); MaybeUpdateShelfBackground(AnimationChangeType::ANIMATE); }
12,963
102,121
0
void SyncManager::SyncInternal::CopyObservers( ObserverList<SyncManager::Observer>* observers_copy) { DCHECK_EQ(0U, observers_copy->size()); base::AutoLock lock(observers_lock_); if (observers_.size() == 0) return; ObserverListBase<SyncManager::Observer>::Iterator it(observers_); SyncManager::Observer...
12,964
23,262
0
static int decode_attr_files_total(struct xdr_stream *xdr, uint32_t *bitmap, uint64_t *res) { __be32 *p; int status = 0; *res = 0; if (unlikely(bitmap[0] & (FATTR4_WORD0_FILES_TOTAL - 1U))) return -EIO; if (likely(bitmap[0] & FATTR4_WORD0_FILES_TOTAL)) { p = xdr_inline_decode(xdr, 8); if (unlikely(!p)) g...
12,965
50,954
0
static struct mountpoint *lookup_mountpoint(struct dentry *dentry) { struct hlist_head *chain = mp_hash(dentry); struct mountpoint *mp; hlist_for_each_entry(mp, chain, m_hash) { if (mp->m_dentry == dentry) { /* might be worth a WARN_ON() */ if (d_unlinked(dentry)) return ERR_PTR(-ENOENT); mp->m_count...
12,966
66,223
0
static inline int mailimf_quoted_pair_parse(const char * message, size_t length, size_t * indx, char * result) { size_t cur_token; cur_token = * indx; if (cur_token + 1 >= length) return MAILIMF_ERROR_PARSE; if (message[cur_token] != '\\') return MAILIMF_ERROR_PARSE; cur_token ++; * r...
12,967
103,109
0
void Browser::FocusNextPane() { UserMetrics::RecordAction(UserMetricsAction("FocusNextPane"), profile_); window_->RotatePaneFocus(true); }
12,968
87,223
0
NTSTATUS TCWriteRegistryKey (PUNICODE_STRING keyPath, wchar_t *keyValueName, ULONG keyValueType, void *valueData, ULONG valueSize) { OBJECT_ATTRIBUTES regObjAttribs; HANDLE regKeyHandle; NTSTATUS status; UNICODE_STRING valName; InitializeObjectAttributes (&regObjAttribs, keyPath, OBJ_KERNEL_HANDLE | OBJ_CASE_INSE...
12,969
103,569
0
bool ContainerNode::getUpperLeftCorner(FloatPoint& point) const { if (!renderer()) return false; RenderObject *o = renderer(); RenderObject *p = o; if (!o->isInline() || o->isReplaced()) { point = o->localToAbsolute(FloatPoint(), false, true); return true; } while (o) {...
12,970
76,866
0
encode_EXIT(const struct ofpact_null *null OVS_UNUSED, enum ofp_version ofp_version OVS_UNUSED, struct ofpbuf *out) { put_NXAST_EXIT(out); }
12,971
16,560
0
FileTransfer::AddDownloadFilenameRemap(char const *source_name,char const *target_name) { if(!download_filename_remaps.IsEmpty()) { download_filename_remaps += ";"; } download_filename_remaps += source_name; download_filename_remaps += "="; download_filename_remaps += target_name; }
12,972
168,667
0
IndexedDBTransaction::~IndexedDBTransaction() { IDB_ASYNC_TRACE_END("IndexedDBTransaction::lifetime", this); DCHECK_EQ(state_, FINISHED); DCHECK(preemptive_task_queue_.empty()); DCHECK_EQ(pending_preemptive_events_, 0); DCHECK(task_queue_.empty()); DCHECK(abort_task_stack_.empty()); DCHECK(!processing_eve...
12,973
107,662
0
Eina_Bool ewk_view_stop(Evas_Object* ewkView) { EWK_VIEW_SD_GET_OR_RETURN(ewkView, smartData, false); return ewk_frame_stop(smartData->main_frame); }
12,974
122,043
0
void StartWatchingPolicy() { policy_watcher_.reset( policy_hack::PolicyWatcher::Create(context_->file_task_runner())); policy_watcher_->StartWatching( base::Bind(&HostProcess::OnPolicyUpdate, base::Unretained(this))); }
12,975
51,094
0
static int apparmor_path_truncate(const struct path *path) { return common_perm_path(OP_TRUNC, path, MAY_WRITE | AA_MAY_META_WRITE); }
12,976
181,082
1
lldp_private_8021_print(netdissect_options *ndo, const u_char *tptr, u_int tlv_len) { int subtype, hexdump = FALSE; u_int sublen; u_int tval; uint8_t i; if (tlv_len < 4) { return hexdump; } subtype = *(tptr+3); ND_PRINT((ndo, "\n\t %s Subtype (%u)", tok2str(lldp_8021_subtype_values, "unknown", subtype), subtype)...
12,977
27,966
0
static int shm_fsync(struct file *file, loff_t start, loff_t end, int datasync) { struct shm_file_data *sfd = shm_file_data(file); if (!sfd->file->f_op->fsync) return -EINVAL; return sfd->file->f_op->fsync(sfd->file, start, end, datasync); }
12,978
90,017
0
size_t ZSTD_compressCCtx(ZSTD_CCtx* cctx, void* dst, size_t dstCapacity, const void* src, size_t srcSize, int compressionLevel) { DEBUGLOG(4, "ZSTD_compressCCtx (srcSize=%u)", (U32)srcSize); assert(cctx != NULL); return ZSTD_compress_using...
12,979
143,440
0
void processInputAttribute(const NameType& attributeName, const String& attributeValue) { if (match(attributeName, srcAttr)) setUrlToLoad(attributeValue, DisallowURLReplacement); else if (match(attributeName, typeAttr)) m_inputIsImage = equalIgnoringCase(attributeValue, I...
12,980
4,307
0
PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ { if (BG(strtok_zval)) { zval_ptr_dtor(&BG(strtok_zval)); } BG(strtok_string) = NULL; BG(strtok_zval) = NULL; #ifdef HAVE_PUTENV zend_hash_destroy(&BG(putenv_ht)); #endif if (BG(umask) != -1) { umask(BG(umask)); } /* Check if locale was changed and change it back ...
12,981
50,534
0
static void swevent_hlist_put(struct perf_event *event) { int cpu; for_each_possible_cpu(cpu) swevent_hlist_put_cpu(event, cpu); }
12,982
100,972
0
void pack() { if (isPacked()) return; m_isPacked = true; }
12,983
78,686
0
static int match_hist_bytes(sc_card_t *card, const char *str, size_t len) { const char *src = (const char *) card->reader->atr_info.hist_bytes; size_t srclen = card->reader->atr_info.hist_bytes_len; size_t offset = 0; if (len == 0) len = strlen(str); if (srclen < len) return 0; while (srclen - offset > len) ...
12,984
174,037
0
Track::~Track() { Info& info = const_cast<Info&>(m_info); info.Clear(); ContentEncoding** i = content_encoding_entries_; ContentEncoding** const j = content_encoding_entries_end_; while (i != j) { ContentEncoding* const encoding = *i++; delete encoding; } delete[] content_encoding_entries_; }
12,985
43,167
0
static struct oz_endpoint *oz_ep_alloc(int buffer_size, gfp_t mem_flags) { struct oz_endpoint *ep; ep = kzalloc(sizeof(struct oz_endpoint)+buffer_size, mem_flags); if (!ep) return NULL; INIT_LIST_HEAD(&ep->urb_list); INIT_LIST_HEAD(&ep->link); ep->credit = -1; if (buffer_size) { ep->buffer_size = buffer_si...
12,986
77,051
0
parse_GROUP(char *arg, struct ofpbuf *ofpacts, enum ofputil_protocol *usable_protocols OVS_UNUSED) { return str_to_u32(arg, &ofpact_put_GROUP(ofpacts)->group_id); }
12,987
17,956
0
kex_free_newkeys(struct newkeys *newkeys) { if (newkeys == NULL) return; if (newkeys->enc.key) { explicit_bzero(newkeys->enc.key, newkeys->enc.key_len); free(newkeys->enc.key); newkeys->enc.key = NULL; } if (newkeys->enc.iv) { explicit_bzero(newkeys->enc.iv, newkeys->enc.iv_len); free(newkeys->enc.iv); ...
12,988
107,259
0
void AutomationProvider::OverrideEncoding(int tab_handle, const std::string& encoding_name, bool* success) { *success = false; if (tab_tracker_->ContainsHandle(tab_handle)) { NavigationController* nav = tab_tracker_->GetResource...
12,989
150,528
0
void SetHeader(const std::string& header) { base::AutoLock auto_lock(lock_); header_ = header; }
12,990
84,068
0
php_stream *php_stream_url_wrap_http(php_stream_wrapper *wrapper, const char *path, const char *mode, int options, char **opened_path, php_stream_context *context STREAMS_DC TSRMLS_DC) /* {{{ */ { return php_stream_url_wrap_http_ex(wrapper, path, mode, options, opened_path, context, PHP_URL_REDIRECT_MAX, HTTP_WRAPPER_...
12,991
36,389
0
int vfs_mknod(struct inode *dir, struct dentry *dentry, umode_t mode, dev_t dev) { int error = may_create(dir, dentry); if (error) return error; if ((S_ISCHR(mode) || S_ISBLK(mode)) && !capable(CAP_MKNOD)) return -EPERM; if (!dir->i_op->mknod) return -EPERM; error = devcgroup_inode_mknod(mode, dev); if ...
12,992
28,519
0
void qeth_core_get_ethtool_stats(struct net_device *dev, struct ethtool_stats *stats, u64 *data) { struct qeth_card *card = dev->ml_priv; data[0] = card->stats.rx_packets - card->perf_stats.initial_rx_packets; data[1] = card->perf_stats.bufs_rec; data[2] = card->stats.tx_packets - card->perf_stats.initial...
12,993
171,873
0
static BOOLEAN btif_hl_get_bta_mdep_role(bthl_mdep_role_t mdep, tBTA_HL_MDEP_ROLE *p){ BOOLEAN status = TRUE; switch (mdep) { case BTHL_MDEP_ROLE_SOURCE: *p = BTA_HL_MDEP_ROLE_SOURCE; break; case BTHL_MDEP_ROLE_SINK: *p = BTA_HL_MDEP_ROLE_SINK; break; default: *p = BTA_HL_MDEP_ROLE_SOURCE; sta...
12,994
142,392
0
void ShelfBackgroundAnimator::AnimateBackground( ShelfBackgroundType background_type, AnimationChangeType change_type) { StopAnimator(); if (change_type == AnimationChangeType::IMMEDIATE) { animator_.reset(); SetTargetValues(background_type); SetAnimationValues(1.0); } else if (CanReuseAnimat...
12,995
38,610
0
struct task_struct *__switch_to(struct task_struct *prev, struct task_struct *new) { struct thread_struct *new_thread, *old_thread; struct task_struct *last; #ifdef CONFIG_PPC_BOOK3S_64 struct ppc64_tlb_batch *batch; #endif WARN_ON(!irqs_disabled()); /* Back up the TAR across context switches. * Note that the...
12,996
84,668
0
int open_related_ns(struct ns_common *ns, struct ns_common *(*get_ns)(struct ns_common *ns)) { struct path path = {}; struct file *f; void *err; int fd; fd = get_unused_fd_flags(O_CLOEXEC); if (fd < 0) return fd; while (1) { struct ns_common *relative; relative = get_ns(ns); if (IS_ERR(relative))...
12,997
30,520
0
static int nr_listen(struct socket *sock, int backlog) { struct sock *sk = sock->sk; lock_sock(sk); if (sk->sk_state != TCP_LISTEN) { memset(&nr_sk(sk)->user_addr, 0, AX25_ADDR_LEN); sk->sk_max_ack_backlog = backlog; sk->sk_state = TCP_LISTEN; release_sock(sk); return 0; } release_sock(sk); ...
12,998
132,584
0
void WebKitTestController::OnPrintMessage(const std::string& message) { printer_->AddMessageRaw(message); }
12,999