instruction
stringclasses
1 value
input
stringlengths
56
241k
output
int64
0
1
__index_level_0__
int64
0
175k
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: exsltDateLeapYear (const xmlChar *dateTime) { double year; year = exsltDateYear(dateTime); if (xmlXPathIsNaN(year)) return xmlXPathNewFloat(xmlXPathNAN); if (IS_LEAP((long)year)) return xmlXPathNewBoolean(1); return xmlXPathNewBoolean(0); } Commit Message: Roll libxslt to 891681e3e948f31...
0
156,614
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int __init hardlockup_panic_setup(char *str) { if (!strncmp(str, "panic", 5)) hardlockup_panic = 1; else if (!strncmp(str, "nopanic", 7)) hardlockup_panic = 0; else if (!strncmp(str, "0", 1)) watchdog_enabled = 0; return 1; } Commit Message: perf: Remove the nmi parameter from the swevent and ov...
0
26,379
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static toff_t tiff_seekproc(thandle_t clientdata, toff_t offset, int from) { tiff_handle *th = (tiff_handle *)clientdata; gdIOCtx *ctx = th->ctx; int result; switch(from) { default: case SEEK_SET: /* just use offset */ break; case SEEK_END: /* invert offset, so that it is from start, not end as sup...
0
73,738
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void free_utc(struct user_ta_ctx *utc) { struct user_ta_elf *elf; tee_pager_rem_uta_areas(utc); TAILQ_FOREACH(elf, &utc->elfs, link) release_ta_memory_by_mobj(elf->mobj_code); release_ta_memory_by_mobj(utc->mobj_stack); release_ta_memory_by_mobj(utc->mobj_exidx); /* * Close sessions opened by t...
0
86,937
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void HTMLFormControlElement::DisabledAttributeChanged() { EventDispatchForbiddenScope event_forbidden; ListedElement::DisabledAttributeChanged(); if (LayoutObject* o = GetLayoutObject()) o->InvalidateIfControlStateChanged(kEnabledControlState); if (AXObjectCache* cache = GetDocument().ExistingAXObje...
0
136,545
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void ExtensionGlobalError::AddExternalExtension(const std::string& id) { external_extension_ids_->insert(id); } Commit Message: [i18n-fixlet] Make strings branding specific in extension code. IDS_EXTENSIONS_UNINSTALL IDS_EXTENSIONS_INCOGNITO_WARNING IDS_EXTENSION_INSTALLED_HEADING IDS_EXTENSION_ALERT_ITEM_EXT...
0
107,735
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void PageInfo::OnChangePasswordButtonPressed( content::WebContents* web_contents) { #if defined(FULL_SAFE_BROWSING) DCHECK(password_protection_service_); DCHECK(safe_browsing_status_ == SAFE_BROWSING_STATUS_SIGN_IN_PASSWORD_REUSE || safe_browsing_status_ == SAFE_BROWSING_STATUS_EN...
1
172,436
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: explicit Object(Object* next) : next_(next) {} Commit Message: [oilpan] Fix GCInfoTable for multiple threads Previously, grow and access from different threads could lead to a race on the table backing; see bug. - Rework the table to work on an existing reservation. - Commit upon growing, avoiding any copies...
0
153,795
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: PasswordAutofillAgent::PasswordValueGatekeeper::~PasswordValueGatekeeper() { } Commit Message: [Android][TouchToFill] Use FindPasswordInfoForElement for triggering Use for TouchToFill the same triggering logic that is used for regular suggestions. Bug: 1010233 Change-Id: I111d4eac4ce94dd94b86097b6b6c98e08875e1...
0
137,669
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int ip_vs_genl_dump_services(struct sk_buff *skb, struct netlink_callback *cb) { int idx = 0, i; int start = cb->args[0]; struct ip_vs_service *svc; struct net *net = skb_sknet(skb); mutex_lock(&__ip_vs_mutex); for (i = 0; i < IP_VS_SVC_TAB_SIZE; i++) { list_for_each_entry(svc, &ip_vs_svc_...
0
34,206
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: fill_small_buf(__le16 smb2_command, struct cifs_tcon *tcon, void *buf, unsigned int *total_len) { struct smb2_sync_pdu *spdu = (struct smb2_sync_pdu *)buf; /* lookup word count ie StructureSize from table */ __u16 parmsize = smb2_req_struct_sizes[le16_to_cpu(smb2_command)]; /* * smaller than SMALL_...
0
84,938
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void inet_register_protosw(struct inet_protosw *p) { struct list_head *lh; struct inet_protosw *answer; int protocol = p->protocol; struct list_head *last_perm; spin_lock_bh(&inetsw_lock); if (p->type >= SOCK_MAX) goto out_illegal; /* If we are trying to override a permanent protocol, bail. */ last_p...
0
41,537
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void fuse_copy_finish(struct fuse_copy_state *cs) { if (cs->currbuf) { struct pipe_buffer *buf = cs->currbuf; if (cs->write) buf->len = PAGE_SIZE - cs->len; cs->currbuf = NULL; } else if (cs->pg) { if (cs->write) { flush_dcache_page(cs->pg); set_page_dirty_lock(cs->pg); } put_page(c...
0
96,793
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void HarfBuzzShaper::setDrawRange(int from, int to) { ASSERT_WITH_SECURITY_IMPLICATION(from >= 0); ASSERT_WITH_SECURITY_IMPLICATION(to <= m_run.length()); m_fromIndex = from; m_toIndex = to; } Commit Message: Always initialize |m_totalWidth| in HarfBuzzShaper::shape. R=leviw@chromium.org BUG=476...
0
128,427
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void GLES2DecoderImpl::DoCopyTexImage2D( GLenum target, GLint level, GLenum internal_format, GLint x, GLint y, GLsizei width, GLsizei height, GLint border) { DCHECK(!ShouldDeferReads()); TextureRef* texture_ref = texture_manager()->GetTextureInfoForTarget( &state_, target...
0
120,798
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: size_t ZSTD_compressBlock(ZSTD_CCtx* cctx, void* dst, size_t dstCapacity, const void* src, size_t srcSize) { size_t const blockSizeMax = ZSTD_getBlockSize(cctx); if (srcSize > blockSizeMax) return ERROR(srcSize_wrong); return ZSTD_compressContinue_internal(cctx, dst, dstCapacity, src, srcSize, 0 /* f...
0
90,014
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static struct ovl_entry *ovl_alloc_entry(void) { return kzalloc(sizeof(struct ovl_entry), GFP_KERNEL); } Commit Message: fs: limit filesystem stacking depth Add a simple read-only counter to super_block that indicates how deep this is in the stack of filesystems. Previously ecryptfs was the only stackable fil...
0
74,574
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int thread_cpu_nsleep(const clockid_t which_clock, int flags, struct timespec *rqtp, struct timespec __user *rmtp) { return -EINVAL; } Commit Message: remove div_long_long_rem x86 is the only arch right now, which provides an optimized for div_long_long_rem and it has the downside that one has ...
0
24,701
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void writeGenerateFreshDenseArray(uint32_t length) { append(GenerateFreshDenseArrayTag); doWriteUint32(length); } Commit Message: Replace further questionable HashMap::add usages in bindings BUG=390928 R=dcarney@chromium.org Review URL: https://codereview.chromium.org/411273002 git...
0
120,562
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void Reverb_free(ReverbContext *pContext){ LVREV_ReturnStatus_en LvmStatus=LVREV_SUCCESS; /* Function call status */ LVREV_ControlParams_st params; /* Control Parameters */ LVREV_MemoryTable_st MemTab; /* Free the algorithm memory */ LvmStatus = LVREV_GetMemoryTable(pContext->hInstance...
0
157,447
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: int cap_ptrace_access_check(struct task_struct *child, unsigned int mode) { int ret = 0; const struct cred *cred, *child_cred; rcu_read_lock(); cred = current_cred(); child_cred = __task_cred(child); if (cred->user->user_ns == child_cred->user->user_ns && cap_issubset(child_cred->cap_permitted, cred->...
0
20,275
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void AutocompleteSuggestionsReturned( const std::vector<base::string16>& result) { autofill_manager_->autocomplete_history_manager_->SendSuggestions(&result); } Commit Message: [AF] Don't simplify/dedupe suggestions for (partially) filled sections. Since Autofill does not fill field by field anymo...
0
155,015
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static size_t net_tx_pkt_fetch_fragment(struct NetTxPkt *pkt, int *src_idx, size_t *src_offset, struct iovec *dst, int *dst_idx) { size_t fetched = 0; struct iovec *src = pkt->vec; *dst_idx = NET_TX_PKT_FRAGMENT_HEADER_NUM; while (fetched < IP_FRAG_ALIGN_SIZE(pkt->virt_hdr.gso_size)) { ...
0
8,957
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void reds_handle_auth_mechname(void *opaque) { RedLinkInfo *link = (RedLinkInfo *)opaque; AsyncRead *obj = &link->async_read; RedsSASL *sasl = &link->stream->sasl; sasl->mechname[sasl->len] = '\0'; spice_info("Got client mechname '%s' check against '%s'", sasl->mechname,...
0
1,871
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void gd_error(const char *format, ...) { va_list args; va_start(args, format); _gd_error_ex(GD_WARNING, format, args); va_end(args); } Commit Message: Fix #340: System frozen gdImageCreate() doesn't check for oversized images and as such is prone to DoS vulnerabilities. We fix that by applying the same ove...
0
73,100
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: sg_poll(struct file *filp, poll_table * wait) { __poll_t res = 0; Sg_device *sdp; Sg_fd *sfp; Sg_request *srp; int count = 0; unsigned long iflags; sfp = filp->private_data; if (!sfp) return EPOLLERR; sdp = sfp->parentdp; if (!sdp) return EPOLLERR; poll_wait(filp, &sfp->read_wait, wait); read_loc...
0
75,143
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: 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->didChoose...
0
108,453
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static __poll_t sock_poll(struct file *file, poll_table *wait) { struct socket *sock = file->private_data; __poll_t events = poll_requested_events(wait), mask = 0; if (sock->ops->poll) { sock_poll_busy_loop(sock, events); mask = sock->ops->poll(file, sock, wait); } else if (sock->ops->poll_mask) { sock...
0
82,275
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void RenderBox::computeLogicalHeight(LayoutUnit logicalHeight, LayoutUnit logicalTop, LogicalExtentComputedValues& computedValues) const { computedValues.m_extent = logicalHeight; computedValues.m_position = logicalTop; if (isTableCell() || (isInline() && !isReplaced())) return; Length h...
0
116,487
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: int ci_hdrc_host_init(struct ci13xxx *ci) { struct ci_role_driver *rdrv; if (!hw_read(ci, CAP_DCCPARAMS, DCCPARAMS_HC)) return -ENXIO; rdrv = devm_kzalloc(ci->dev, sizeof(struct ci_role_driver), GFP_KERNEL); if (!rdrv) return -ENOMEM; rdrv->start = host_start; rdrv->stop = host_stop; rdrv->irq = hos...
0
32,039
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void ext4_truncate(struct inode *inode) { struct ext4_inode_info *ei = EXT4_I(inode); unsigned int credits; handle_t *handle; struct address_space *mapping = inode->i_mapping; /* * There is a possibility that we're either freeing the inode * or it's a completely new inode. In those cases we might not ...
0
67,539
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void DevToolsSession::AddHandler( std::unique_ptr<protocol::DevToolsDomainHandler> handler) { handler->Wire(dispatcher_.get()); handler->SetRenderer(process_, host_); handlers_[handler->name()] = std::move(handler); } Commit Message: DevTools: speculative fix for crash in NetworkHandler::Disable ...
1
172,740
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: virtual void BeginPassHook(unsigned int /*pass*/) { psnr_ = kMaxPsnr; nframes_ = 0; } Commit Message: Merge Conflict Fix CL to lmp-mr1-release for ag/849478 DO NOT MERGE - libvpx: Pull from upstream Current HEAD: 7105df53d7dc13d5e575bc8df714ec8d1da36b06 BUG=23452792 Change-Id: Ic78176fc369e0bac...
0
164,528
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static MagickBooleanType WriteDPXImage(const ImageInfo *image_info,Image *image) { const char *value; const StringInfo *profile; DPXInfo dpx; MagickBooleanType status; MagickOffsetType offset; MagickStatusType flags; GeometryInfo geometry_info; QuantumInfo *q...
0
71,523
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: MagickExport signed int ReadBlobMSBSignedLong(Image *image) { union { unsigned int unsigned_value; signed int signed_value; } quantum; quantum.unsigned_value=ReadBlobMSBLong(image); return(quantum.signed_value); } Commit Message: https://github.com/ImageMagick/ImageMagick6/issues/...
0
88,549
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int pcd_command(struct pcd_unit *cd, char *cmd, int dlen, char *fun) { pi_connect(cd->pi); write_reg(cd, 6, 0xa0 + 0x10 * cd->drive); if (pcd_wait(cd, IDE_BUSY | IDE_DRQ, 0, fun, "before command")) { pi_disconnect(cd->pi); return -1; } write_reg(cd, 4, dlen % 256); write_reg(cd, 5, dlen / 256)...
0
87,967
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: FrameSelection::FrameSelection(LocalFrame& frame) : frame_(frame), layout_selection_(LayoutSelection::Create(*this)), selection_editor_(SelectionEditor::Create(frame)), granularity_(TextGranularity::kCharacter), x_pos_for_vertical_arrow_navigation_(NoXPosForVerticalArrowNavigation()), ...
0
124,771
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: int jas_image_writecmpt2(jas_image_t *image, int cmptno, jas_image_coord_t x, jas_image_coord_t y, jas_image_coord_t width, jas_image_coord_t height, long *buf) { jas_image_cmpt_t *cmpt; jas_image_coord_t i; jas_image_coord_t j; long v; long *bufptr; if (cmptno < 0 || cmptno >= image->numcmpts_) goto...
0
72,786
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void write_dict(bytearray_t * bplist, node_t* node, hashtable_t* ref_table, uint8_t ref_size) { node_t* cur = NULL; uint64_t i = 0; uint64_t size = node_n_children(node) / 2; uint8_t marker = BPLIST_DICT | (size < 15 ? size : 0xf); byte_array_append(bplist, &marker, sizeof(uint8_t)); ...
0
68,044
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int nci_add_new_protocol(struct nci_dev *ndev, struct nfc_target *target, __u8 rf_protocol, __u8 rf_tech_and_mode, void *params) { struct rf_tech_specific_params_nfca_poll *nfca_poll; struct rf_tech_specific_params_nfcb_poll *nfcb_poll; struct rf_tech_specific_params_nfcf_poll *nfcf_poll...
0
34,541
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static jboolean Region_isEmpty(JNIEnv* env, jobject region) { bool result = GetSkRegion(env, region)->isEmpty(); return boolTojboolean(result); } Commit Message: Check that the parcel contained the expected amount of region data. DO NOT MERGE bug:20883006 Change-Id: Ib47a8ec8696dbc37e958b8dbceb43fcbabf6605b ...
0
157,230
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void cuse_gendev_release(struct device *dev) { kfree(dev); } Commit Message: cuse: fix memory leak The problem is that fuse_dev_alloc() acquires an extra reference to cc.fc, and the original ref count is never dropped. Reported-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Miklos Szeredi...
0
58,060
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void FrameLoader::RestoreScrollPositionAndViewState() { if (!frame_->GetPage() || !GetDocumentLoader() || !GetDocumentLoader()->GetHistoryItem() || in_restore_scroll_) { return; } base::AutoReset<bool> in_restore_scroll(&in_restore_scroll_, true); RestoreScrollPositionAndViewState( GetDocu...
0
152,571
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: virDomainSetMemoryFlags(virDomainPtr domain, unsigned long memory, unsigned int flags) { virConnectPtr conn; VIR_DOMAIN_DEBUG(domain, "memory=%lu, flags=%x", memory, flags); virResetLastError(); virCheckDomainReturn(domain, -1); conn = domain->conn; virCheckRead...
0
93,917
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: int DH_compute_key(unsigned char *key, const BIGNUM *pub_key, DH *dh) { #ifdef OPENSSL_FIPS if (FIPS_mode() && !(dh->meth->flags & DH_FLAG_FIPS_METHOD) && !(dh->flags & DH_FLAG_NON_FIPS_ALLOW)) { DHerr(DH_F_DH_COMPUTE_KEY, DH_R_NON_FIPS_METHOD); return 0; } #endif return dh->me...
0
15,392
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: bool Editor::CanDHTMLCut() { GetFrame().GetDocument()->UpdateStyleAndLayoutIgnorePendingStylesheets(); return !IsInPasswordField(GetFrame() .Selection() .ComputeVisibleSelectionInDOMTree() .Start()) && !Di...
0
124,656
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: status_t Parcel::writeBoolVector(const std::unique_ptr<std::vector<bool>>& val) { return writeNullableTypedVector(val, &Parcel::writeBool); } Commit Message: Add bound checks to utf16_to_utf8 Bug: 29250543 Change-Id: I518e7b2fe10aaa3f1c1987586a09b1110aff7e1a (cherry picked from commit 7e93b2ddcb49b5365fbe1dab1...
0
163,604
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void TemplateURL::SetPrepopulateId(int id) { data_.prepopulate_id = id; const bool prepopulated = id > 0; for (TemplateURLRef& ref : url_refs_) ref.prepopulated_ = prepopulated; suggestions_url_ref_.prepopulated_ = prepopulated; instant_url_ref_.prepopulated_ = prepopulated; image_url_ref_.prepopu...
0
120,311
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b) { int i; BN_ULONG *A; const BN_ULONG *B; bn_check_top(b); if (a == b) return(a); if (bn_wexpand(a,b->top) == NULL) return(NULL); #if 1 A=a->d; B=b->d; for (i=b->top>>2; i>0; i--,A+=4,B+=4) { BN_ULONG a0,a1,a2,a3; a0=B[0]; a1=B[1]; a2=B[2]; a3=B[3]; ...
0
14,543
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: bool ExtensionTabUtil::GetDefaultTab(Browser* browser, WebContents** contents, int* tab_id) { DCHECK(browser); DCHECK(contents); *contents = chrome::GetActiveWebContents(browser); if (*contents) { if (tab_id) *tab_id = Ge...
0
116,040
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int phar_hex_str(const char *digest, size_t digest_len, char **signature) /* {{{ */ { int pos = -1; size_t len = 0; *signature = (char*)safe_pemalloc(digest_len, 2, 1, PHAR_G(persist)); for (; len < digest_len; ++len) { (*signature)[++pos] = hexChars[((const unsigned char *)digest)[len] >> 4]; (*...
0
49,894
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int sctp_getsockopt_disable_fragments(struct sock *sk, int len, char __user *optval, int __user *optlen) { int val; if (len < sizeof(int)) return -EINVAL; len = sizeof(int); val = (sctp_sk(sk)->disable_fragments == 1); if (put_user(len, optlen)) return -EFAULT; if (copy_to_user(optval, &va...
0
32,999
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: SYSCALL_DEFINE3(shmctl, int, shmid, int, cmd, struct shmid_ds __user *, buf) { struct shmid_kernel *shp; int err, version; struct ipc_namespace *ns; if (cmd < 0 || shmid < 0) return -EINVAL; version = ipc_parse_version(&cmd); ns = current->nsproxy->ipc_ns; switch (cmd) { case IPC_INFO: case SHM_INFO...
1
165,910
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: int snd_seq_dispatch_event(struct snd_seq_event_cell *cell, int atomic, int hop) { struct snd_seq_client *client; int result; if (snd_BUG_ON(!cell)) return -EINVAL; client = snd_seq_client_use_ptr(cell->event.source.client); if (client == NULL) { snd_seq_cell_free(cell); /* release this cell */ retur...
0
54,689
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void DoubleOrStringAttributeAttributeSetter( 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 = ...
0
134,695
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: struct sk_buff *napi_frags_skb(struct napi_struct *napi) { struct sk_buff *skb = napi->skb; struct ethhdr *eth; unsigned int hlen; unsigned int off; napi->skb = NULL; skb_reset_mac_header(skb); skb_gro_reset_offset(skb); off = skb_gro_offset(skb); hlen = off + sizeof(*eth); eth = skb_gro_header_fast(...
0
32,167
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: xmlParseNmtoken(xmlParserCtxtPtr ctxt) { xmlChar buf[XML_MAX_NAMELEN + 5]; int len = 0, l; int c; int count = 0; #ifdef DEBUG nbParseNmToken++; #endif GROW; if (ctxt->instate == XML_PARSER_EOF) return(NULL); c = CUR_CHAR(l); while (xmlIsNameChar(ctxt, c)) { if (coun...
0
59,506
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: struct pt_regs *save_v86_state(struct kernel_vm86_regs *regs) { struct tss_struct *tss; struct pt_regs *ret; unsigned long tmp; /* * This gets called from entry.S with interrupts disabled, but * from process context. Enable interrupts here, before trying * to access user space. */ local_irq_enable()...
0
20,969
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: ofputil_protocol_from_ofp_version(enum ofp_version version) { return rightmost_1bit(ofputil_protocols_from_ofp_version(version)); } Commit Message: ofp-group: Don't assert-fail decoding bad OF1.5 group mod type or command. When decoding a group mod, the current code validates the group type and command afte...
0
77,657
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void HTMLInputElement::setValueAsDate(double value, ExceptionCode& ec) { m_inputType->setValueAsDate(value, ec); } Commit Message: Setting input.x-webkit-speech should not cause focus change In r150866, we introduced element()->focus() in destroyShadowSubtree() to retain focus on <input> when its type attri...
0
113,008
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void V8TestObject::HighEntropyAttributeWithMeasureAsAttributeSetterCallback( const v8::FunctionCallbackInfo<v8::Value>& info) { RUNTIME_CALL_TIMER_SCOPE_DISABLED_BY_DEFAULT(info.GetIsolate(), "Blink_TestObject_highEntropyAttributeWithMeasureAs_Setter"); v8::Local<v8::Value> v8_value = info[0]; UseCoun...
0
134,739
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: GURL GetWebUIURL(std::string host) { return GURL(std::string(kChromeUIScheme) + "://" + host); } Commit Message: Use unique processes for data URLs on restore. Data URLs are usually put into the process that created them, but this info is not tracked after a tab restore. Ensure that they do not end up in the...
0
154,534
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void WebBluetoothServiceImpl::OnGetDeviceSuccess( RequestDeviceCallback callback, blink::mojom::WebBluetoothRequestDeviceOptionsPtr options, const std::string& device_address) { device_chooser_controller_.reset(); const device::BluetoothDevice* const device = GetAdapter()->GetDevice(device_...
0
155,111
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: ofputil_encode_packet_in_private(const struct ofputil_packet_in_private *pin, enum ofputil_protocol protocol, enum nx_packet_in_format packet_in_format) { enum ofp_version version = ofputil_protocol_to_ofp_version(protocol); struct ofpbuf ...
0
77,585
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: bool ExtensionRegistry::RemoveBlacklisted(const std::string& id) { return blacklisted_extensions_.Remove(id); } Commit Message: [Extensions] Add GetInstalledExtension() method to ExtensionRegistry This CL adds GetInstalledExtension() method to ExtensionRegistry and uses it instead of deprecated ExtensionServi...
0
123,997
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void RenderWidgetHostViewAura::OnCompositingLockStateChanged( ui::Compositor* compositor) { if (!compositor->IsLocked() && can_lock_compositor_ == YES_DID_LOCK) { can_lock_compositor_ = NO_PENDING_RENDERER_FRAME; } } Commit Message: Implement TextureImageTransportSurface using texture mailbox This h...
0
114,867
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: base::TimeTicks TabLifecycleUnitSource::TabLifecycleUnit::GetLastFocusedTime() const { return last_focused_time_; } Commit Message: Connect the LocalDB to TabManager. Bug: 773382 Change-Id: Iec8fe5226ee175105d51f300f30b4865478ac099 Reviewed-on: https://chromium-review.googlesource.com/1118611 Commit-Queue...
0
132,105
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: dummy_set_flag(struct trace_array *tr, u32 old_flags, u32 bit, int set) { return 0; } Commit Message: Merge tag 'trace-v4.18-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace Pull tracing fixes from Steven Rostedt: "This contains a few fixes and a clean up. - a bad merge caused an ...
0
81,267
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void RenderWidgetHostImpl::SetIgnoreInputEvents(bool ignore_input_events) { ignore_input_events_ = ignore_input_events; } Commit Message: Implement TextureImageTransportSurface using texture mailbox This has a couple of advantages: - allow tearing down and recreating the UI parent context without losing the r...
0
114,709
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: xmlParseStringEntityRef(xmlParserCtxtPtr ctxt, const xmlChar ** str) { xmlChar *name; const xmlChar *ptr; xmlChar cur; xmlEntityPtr ent = NULL; if ((str == NULL) || (*str == NULL)) return(NULL); ptr = *str; cur = *ptr; if (cur != '&') return(NULL); ptr++; name = ...
0
59,519
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int may_linkat(struct path *link) { struct inode *inode; if (!sysctl_protected_hardlinks) return 0; inode = link->dentry->d_inode; /* Source inode owner (or CAP_FOWNER) can hardlink all they like, * otherwise, it must be a safe source. */ if (safe_hardlink_source(inode) || inode_owner_or_capa...
0
67,451
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: diskfile_recv(struct iperf_stream *sp) { int r; r = sp->rcv2(sp); if (r > 0) { (void) write(sp->diskfile_fd, sp->buffer, r); (void) fsync(sp->diskfile_fd); } return r; } Commit Message: Fix a buffer overflow / heap corruption issue that could occur if a malformed JSON string was passed on ...
0
53,362
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void HTMLInputElement::SetNonAttributeValueByUserEdit( const String& sanitized_value) { SetValueBeforeFirstUserEditIfNotSet(); SetNonAttributeValue(sanitized_value); CheckIfValueWasReverted(sanitized_value); } Commit Message: MacViews: Enable secure text input for password Textfields. In Cocoa the NST...
0
126,099
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int read_from_url(struct playlist *pls, struct segment *seg, uint8_t *buf, int buf_size, enum ReadFromURLMode mode) { int ret; /* limit read if the segment was only a part of a file */ if (seg->size >= 0) buf_size = FFMIN(buf_size, seg...
0
61,814
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void MediaControlsHeaderView::SetAppIcon(const gfx::ImageSkia& img) { app_icon_view_->SetImage(img); } Commit Message: [Lock Screen Media Controls] Tweak UI based on new mocks This CL rearranges the different components of the CrOS lock screen media controls based on the newest mocks. This involves resizing m...
0
136,528
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: rdpdr_send_client_name_request(void) { /* DR_CORE_CLIENT_NAME_REQ */ STREAM s; struct stream name = { 0 }; if (NULL == g_rdpdr_clientname) { g_rdpdr_clientname = g_hostname; } s_realloc(&name, 512 * 4); s_reset(&name); out_utf16s(&name, g_rdpdr_clientname); s_mark_end(&name); s = channel_init(rdpd...
0
93,056
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int snd_usb_cm106_write_int_reg(struct usb_device *dev, int reg, u16 value) { u8 buf[4]; buf[0] = 0x20; buf[1] = value & 0xff; buf[2] = (value >> 8) & 0xff; buf[3] = reg; return snd_usb_ctl_msg(dev, usb_sndctrlpipe(dev, 0), USB_REQ_SET_CONFIGURATION, USB_DIR_OUT | USB_TYPE_CLASS | USB_RECIP...
0
55,260
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void LYHandleFIG(HTStructured * me, const BOOL *present, STRING2PTR value, int isobject, int imagemap, const char *id, const char *src, int convert, int start, BOOL *intern_flag GCC_UNUSED) { if (start == TRUE) { me->inFIG = TRUE; if (me->inA) { SET_SKIP_STACK(HTML_A); ...
0
59,013
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: PassRefPtr<ExecutableMemoryHandle> ExecutableAllocator::allocate(JSGlobalData& globalData, size_t sizeInBytes, void* ownerUID, JITCompilationEffort effort) { RefPtr<ExecutableMemoryHandle> result = allocator->allocate(sizeInBytes, ownerUID); if (!result) { if (effort == JITCompilationCanFail) ...
0
97,924
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int jpeg2000_decode_tile(Jpeg2000DecoderContext *s, Jpeg2000Tile *tile, AVFrame *picture) { int compno, reslevelno, bandno; int x, y; uint8_t *line; Jpeg2000T1Context t1; /* Loop on tile components */ for (compno = 0; compno < s->ncomponents; compno...
0
28,066
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void PDFiumEngine::AppendBlankPages(int num_pages) { DCHECK_NE(num_pages, 0); if (!doc_) return; selection_.clear(); pending_pages_.clear(); while (pages_.size() > 1) { pages_.pop_back(); FPDFPage_Delete(doc_, pages_.size()); } std::vector<pp::Rect> page_rects; pp::Size page_size =...
0
147,385
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: PassthroughResources::PassthroughResources() : texture_object_map(nullptr) {} Commit Message: Add GL_PROGRAM_COMPLETION_QUERY_CHROMIUM This makes the query of GL_COMPLETION_STATUS_KHR to programs much cheaper by minimizing the round-trip to the GPU thread. Bug: 881152, 957001 Change-Id: Iadfa798af29225e752c710...
0
141,793
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: enum act_return http_action_set_req_line(struct act_rule *rule, struct proxy *px, struct session *sess, struct stream *s, int flags) { struct chunk *replace; enum act_return ret = ACT_RET_ERR; replace = alloc_trash_chunk(); if (!replace) goto leave; /* If we have ...
0
6,812
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void SessionService::SortTabsBasedOnVisualOrderAndPrune( std::map<int, SessionWindow*>* windows, std::vector<SessionWindow*>* valid_windows) { std::map<int, SessionWindow*>::iterator i = windows->begin(); while (i != windows->end()) { if (i->second->tabs.empty() || i->second->is_constrained || ...
0
108,845
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: AudioInputDeviceManager* MediaStreamManager::audio_input_device_manager() { DCHECK_CURRENTLY_ON(BrowserThread::IO); DCHECK(audio_input_device_manager_.get()); return audio_input_device_manager_.get(); } Commit Message: Fix MediaObserver notifications in MediaStreamManager. This CL fixes the stream type us...
0
148,365
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: pimv2_addr_print(netdissect_options *ndo, const u_char *bp, enum pimv2_addrtype at, int silent) { int af; int len, hdrlen; ND_TCHECK(bp[0]); if (pimv2_addr_len == 0) { ND_TCHECK(bp[1]); switch (bp[0]) { case 1: af = AF_INET; len = sizeof(struct in_addr); break; cas...
1
167,857
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: spnego_gss_unwrap( OM_uint32 *minor_status, gss_ctx_id_t context_handle, gss_buffer_t input_message_buffer, gss_buffer_t output_message_buffer, int *conf_state, gss_qop_t *qop_state) { OM_uint32 ret; ret = gss_unwrap(minor_status, context_handle, input_message_buffer, output_message_b...
1
166,666
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int write_name_extension(git_index *index, git_filebuf *file) { git_buf name_buf = GIT_BUF_INIT; git_vector *out = &index->names; git_index_name_entry *conflict_name; struct index_extension extension; size_t i; int error = 0; git_vector_foreach(out, i, conflict_name) { if ((error = create_name_ex...
0
83,767
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: nsPluginInstance::shut() { gnash::log_debug("Gnash plugin shutting down"); if (_streamfd != -1) { if (close(_streamfd) == -1) { perror("closing _streamfd"); } else { _streamfd = -1; } } } Commit Message: CWE ID: CWE-264
0
13,231
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: std::vector<InputHandler*> InputHandler::ForAgentHost( DevToolsAgentHostImpl* host) { return DevToolsSession::HandlersForAgentHost<InputHandler>( host, Input::Metainfo::domainName); } Commit Message: DevTools: speculative fix for crash in NetworkHandler::Disable This keeps BrowserContext* and Stor...
0
148,461
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static inline uint32_t clipf_c_one(uint32_t a, uint32_t mini, uint32_t maxi, uint32_t maxisign) { if(a > mini) return mini; else if((a^(1U<<31)) > maxisign) return maxi; else return a; } Commit Message: avcodec/dsputil: fix signedness in sizeof() comparissions Signed-off-by: Mich...
0
28,110
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int __set_cpus_allowed_ptr(struct task_struct *p, const struct cpumask *new_mask, bool check) { const struct cpumask *cpu_valid_mask = cpu_active_mask; unsigned int dest_cpu; struct rq_flags rf; struct rq *rq; int ret = 0; rq = task_rq_lock(p, &rf); if (p->flags & PF_KTHREAD) { /* * Ker...
0
55,476
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: PHP_FUNCTION(urldecode) { char *in_str, *out_str; int in_str_len, out_str_len; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &in_str, &in_str_len) == FAILURE) { return; } out_str = estrndup(in_str, in_str_len); out_str_len = php_url_decode(out_str, in_str_len); RETURN_STRINGL(o...
0
9,665
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: bool WebContentsImpl::CreateRenderViewForInitialEmptyDocument() { return CreateRenderViewForRenderManager( GetRenderViewHost(), MSG_ROUTING_NONE, MSG_ROUTING_NONE, frame_tree_.root()->devtools_frame_token(), frame_tree_.root()->current_replication_state()); } Commit Message: Prevent renderer ...
0
144,925
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: cmsBool CMSEXPORT cmsIT8SetDataRowColDbl(cmsHANDLE hIT8, int row, int col, cmsFloat64Number Val) { cmsIT8* it8 = (cmsIT8*) hIT8; char Buff[256]; _cmsAssert(hIT8 != NULL); snprintf(Buff, 255, it8->DoubleFormatter, Val); return SetData(it8, row, col, Buff); } Commit Message: Upgrade Visual s...
0
78,081
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int crypto_init_blkcipher_ops_sync(struct crypto_tfm *tfm) { struct blkcipher_tfm *crt = &tfm->crt_blkcipher; struct blkcipher_alg *alg = &tfm->__crt_alg->cra_blkcipher; unsigned long align = crypto_tfm_alg_alignmask(tfm) + 1; unsigned long addr; crt->setkey = setkey; crt->encrypt = alg->encrypt; c...
0
31,292
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static void set_skip_buddy(struct sched_entity *se) { for_each_sched_entity(se) cfs_rq_of(se)->skip = se; } Commit Message: sched/fair: Fix infinite loop in update_blocked_averages() by reverting a9e7f6544b9c Zhipeng Xie, Xie XiuQi and Sargun Dhillon reported lockups in the scheduler under high loads, starti...
0
92,681
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: void rds_recv_incoming(struct rds_connection *conn, struct in6_addr *saddr, struct in6_addr *daddr, struct rds_incoming *inc, gfp_t gfp) { struct rds_sock *rs = NULL; struct sock *sk; unsigned long flags; struct rds_conn_path *cp; inc->i_conn = conn; inc->i_rx_jiffies = jiffies; if (conn...
0
87,825
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: static int tg3_nvram_read_be32(struct tg3 *tp, u32 offset, __be32 *val) { u32 v; int res = tg3_nvram_read(tp, offset, &v); if (!res) *val = cpu_to_be32(v); return res; } Commit Message: tg3: fix length overflow in VPD firmware parsing Commit 184b89044fb6e2a74611dafa69b1dce0d98612c6 ("tg3: Use VPD fw versi...
0
32,638
Analyze the following code, commit message, and CWE ID. Determine whether it has a vulnerability. If it does, return '1'; if it doesn't, return '0'.
Code: HttpBridge::RequestContextGetter::GetURLRequestContext() { if (!context_) { net::URLRequestContext* baseline_context = baseline_context_getter_->GetURLRequestContext(); context_ = new RequestContext(baseline_context); baseline_context_getter_ = NULL; } if (is_user_agent_set()) conte...
0
100,128