problem stringlengths 26 131k | labels class label 2
classes |
|---|---|
void qemu_fclose(QEMUFile *f)
{
if (f->is_writable)
qemu_fflush(f);
if (f->is_file) {
fclose(f->outfile);
}
qemu_free(f);
}
| 1threat |
Split a cell into two rows while duplicating the rest of the data? : <p>I'm pulling data from our database to send out to a 3rd party according to their template. I need to send guardian information, with each person having their own row. Our database has the guardian information with a "/" and then details by each ID ... | 0debug |
Convert hexString to base64 : byte[] ba = Encoding.Default.GetBytes(input);
var hexString = BitConverter.ToString(ba);
hexString = hexString.Replace("-", "");
Console.WriteLine("Or: " + hexString + " in hexadecimal");
So i got this, now how would i convert hexString t... | 0debug |
Using Jupyter notebook for Java : <p>I've used the Jupyter notebook quite a lot for my Python projects, but now I have to work on something in Java. So I was wondering if I could get Jupyter to work with Java?</p>
<p>After some searching I think I understand that you can install different kernels for other languages, ... | 0debug |
Making a unique extension id and key for Chrome extension? : <p>I have a Chrome extension I made, but based it on some example found online. Its not in a crx file. The extension ID is the one used in the example. I would like to change it before I upload my extension to the chrome store. My question is how do I cha... | 0debug |
static int ac3_encode_frame(AVCodecContext *avctx, unsigned char *frame,
int buf_size, void *data)
{
AC3EncodeContext *s = avctx->priv_data;
const SampleType *samples = data;
int ret;
if (s->bit_alloc.sr_code == 1)
adjust_frame_size(s);
deinterleave_in... | 1threat |
how to pass an intent from fragment class to a service class in android : i am new to android and i am learning the service in android , i created a fragment in which i have a button. on that button click i need to toast a message
this is my service class
public class BackgroundSoundService extends Service ... | 0debug |
static void encode_rgb48_10bit(AVCodecContext *avctx, const AVPicture *pic, uint8_t *dst)
{
DPXContext *s = avctx->priv_data;
const uint8_t *src = pic->data[0];
int x, y;
for (y = 0; y < avctx->height; y++) {
for (x = 0; x < avctx->width; x++) {
int value;
if (s... | 1threat |
Why do my code is failing the hidden input test cases? : This is the problem to be solved:
John is assigned a new task today. He is given an array A containing N integers. His task is to update all elements of array to some minimum value x , that is, **A[i]=x;1<=i<=N** ;
such that sum of this new array is strictl... | 0debug |
Skip forbidden parameter combinations when using GridSearchCV : <p>I want to greedily search the entire parameter space of my support vector classifier using <a href="http://scikit-learn.org/stable/modules/generated/sklearn.model_selection.GridSearchCV.html" rel="noreferrer">GridSearchCV</a>. However, some combinations... | 0debug |
static av_cold int dsp_init(AVCodecContext *avctx, AACEncContext *s)
{
int ret = 0;
s->fdsp = avpriv_float_dsp_alloc(avctx->flags & CODEC_FLAG_BITEXACT);
if (!s->fdsp)
return AVERROR(ENOMEM);
ff_kbd_window_init(ff_aac_kbd_long_1024, 4.0, 1024);
ff_kbd_window_init(ff_aac_kbd_... | 1threat |
Is it possible to transfer data from Python to HTML template/Website (Using Flask) : <p>I am a noob to this topic and this is my first question here.
I want to ask if it is possible to <em>upload a changing variable</em> <em>from python to an HTML</em> textbox/paragraph/forms?
I've seen several methods but can't figur... | 0debug |
static void pci_msix(void)
{
QVirtioPCIDevice *dev;
QPCIBus *bus;
QVirtQueuePCI *vqpci;
QGuestAllocator *alloc;
QVirtioBlkReq req;
int n_size = TEST_IMAGE_SIZE / 2;
void *addr;
uint64_t req_addr;
uint64_t capacity;
uint32_t features;
uint32_t free_head;
uint8... | 1threat |
VueJS newline character is not rendered correctly : <p>I got the following problem, I read data string from an API which contains new line characters <code>\n</code> and I want to display them correctly in my template. </p>
<p>But when I do something like:</p>
<pre><code><p>{{ mytext }}</p>
</code></pre>
... | 0debug |
Figuring out JavaScript libraries for Vim autocompletion with TernJS in .tern_project file : <p>I love vim and want to keep using it to do web development although I am struggling setting up my .tern_project file with the correct libraries I need to do autocompletion. I am relatively new to JavaScript but what I have s... | 0debug |
static int qdev_add_one_global(QemuOpts *opts, void *opaque)
{
GlobalProperty *g;
ObjectClass *oc;
g = g_malloc0(sizeof(*g));
g->driver = qemu_opt_get(opts, "driver");
g->property = qemu_opt_get(opts, "property");
g->value = qemu_opt_get(opts, "value");
oc = object_class_by_na... | 1threat |
Disable Firefox Same Origin Policy without installing a plugin : <p>Is there a way to disable the <a href="https://en.wikipedia.org/wiki/Same_origin_policy" rel="noreferrer">same origin policy</a> on the Mozilla Firefox browser <strong>by toggling a flag in the browser</strong>?</p>
<p>This is strictly for development... | 0debug |
How to find the database id of a cloud firestore project? : <p>I'm trying to use the Cloud Firestore REST API, but can't seem to find the project id. </p>
| 0debug |
How to get today 00:00 time : <p>how can I get today datetime from 00:00, for example when I Use:</p>
<pre><code>var dt=DateTime.Now; // 2019/1/1 15:22:22
</code></pre>
<p>I need Another extention method to give this string format:</p>
<pre><code>string today = dt.TodayBegining(); // 2019/1/1 00:00:00
</code></pre>
| 0debug |
char *g_strconcat(const char *s, ...)
{
char *s;
s = __coverity_alloc_nosize__();
__coverity_writeall__(s);
__coverity_mark_as_afm_allocated__(s, AFM_free);
return s;
}
| 1threat |
How can I randomly select from prewritten strings in C#? : <p>I have 100 separate strings, and I want the program to display one of them randomly when I push a button.</p>
| 0debug |
Java Spring do scheduled task at a specific time of specific timezone : <p>I'm developing a website with Spring and Hibernate (the website is about stock trading). </p>
<p>At about 12 AM everyday, I need to cancel all orders. Currently my solution is using a scheduled task that runs every hour:</p>
<pre><code> <ta... | 0debug |
int ff_rfps_add_frame(AVFormatContext *ic, AVStream *st, int64_t ts)
{
int i, j;
int64_t last = st->info->last_dts;
if( ts != AV_NOPTS_VALUE && last != AV_NOPTS_VALUE && ts > last
&& ts - (uint64_t)last < INT64_MAX){
double dts= (is_relative(ts) ? ts - RELATIVE_TS_BASE : ts) * av_q... | 1threat |
updata query from access to sql server : I have this query below from access and I need to convert it into sql server:
UPDATE (CASE_INFO INNER JOIN CASE_PRICE ON CASE_INFO.CASE_TYPE = CASE_PRICE.CASE_TYPE) INNER JOIN [CASECHANGE|INPUT] ON CASE_INFO.CASE_NUMBER = [CASECHANGE|INPUT].CASE_NUMBER SET CASE_INFO.FF_REVENU... | 0debug |
static int protocol_client_msg(VncState *vs, uint8_t *data, size_t len)
{
int i;
uint16_t limit;
switch (data[0]) {
case 0:
if (len == 1)
return 20;
set_pixel_format(vs, read_u8(data, 4), read_u8(data, 5),
read_u8(data, 6), read_u8(data, 7),
read_u16(data, 8), read_u16(data,... | 1threat |
How to fix Perforce error "Can't clobber writable file" or Perforce Error Message - Can't Clobber Writable File : <p><strong>Error: Can't clobber writable file : //file name//</strong></p>
<p><strong>Solution:</strong> When you try to sync a file, perforce expects your files in workspace will have read-only permission... | 0debug |
static int vp3_update_thread_context(AVCodecContext *dst, const AVCodecContext *src)
{
Vp3DecodeContext *s = dst->priv_data, *s1 = src->priv_data;
int qps_changed = 0, i, err;
#define copy_fields(to, from, start_field, end_field) memcpy(&to->start_field, &from->start_field, (char*)&to->end_field - (char*)... | 1threat |
How to configure IIS 7 for localhost website? : <p>I am new in Asp.Net</p>
<p>I have enabled features of IIS 7 on my windows system and able to see IIS manager.</p>
<p>I created an application but build/run application through visual studio it goes to browser and run the application with different port number. When i... | 0debug |
java - illegalStateException: Cannot find changelog location: class path resource (liquibase) : <p>I am getting this error when I try to run my spring boot application. I am new to java and spring development. Please let me know if you require more info. I'm not sure what it means by "cannot find changelog location ...... | 0debug |
Elasticsearch - generic facets structure - calculating aggregations combined with filters : <p>In a new project of ours, we were inspired by this article <a href="http://project-a.github.io/on-site-search-design-patterns-for-e-commerce/#generic-faceted-search" rel="noreferrer">http://project-a.github.io/on-site-search-... | 0debug |
How to remove all files with specific extension in folder? : <p>I am looking for command to delete all files with a specific extension in a given folder. Both, for windows and mac.</p>
<p>Thanks!</p>
| 0debug |
cannot resolve simbol 'adapter' : I have an error with this code, i don't understand why, but "adapter.notifyDataSetChanged();" don't work, the message of error is: "cannot resolve simbol 'adapter'".
Code:wwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww
final String URL = "http://example....";
@Override
prot... | 0debug |
BlockAIOCB *bdrv_aio_discard(BlockDriverState *bs,
int64_t sector_num, int nb_sectors,
BlockCompletionFunc *cb, void *opaque)
{
Coroutine *co;
BlockAIOCBCoroutine *acb;
trace_bdrv_aio_discard(bs, sector_num, nb_sectors, opaque);
acb = qemu_aio_get(&bdrv_em_co_aiocb_info, bs, c... | 1threat |
static void nvdimm_dsm_func_read_fit(AcpiNVDIMMState *state, NvdimmDsmIn *in,
hwaddr dsm_mem_addr)
{
NvdimmFitBuffer *fit_buf = &state->fit_buf;
NvdimmFuncReadFITIn *read_fit;
NvdimmFuncReadFITOut *read_fit_out;
GArray *fit;
uint32_t read_len = 0, func_ret... | 1threat |
Laravel API, how to properly handle errors : <p>Anyone know what is the best way to handle errors in Laravel, there is any rules or something to follow ?</p>
<p>Currently i'm doing this : </p>
<pre><code>public function store(Request $request)
{
$plate = Plate::create($request->all());
if ($plate) {
retur... | 0debug |
Please help in creating a message app filter extension for iPhone : I am developing a message filter app extension.
I searched about it and got to know about identity lookup which is newly introduced concept in ios 11.0.
I came to know that i have to insert keys in info.plist
<key>NSExtension</key>
... | 0debug |
static void do_dma_memory_set(dma_addr_t addr, uint8_t c, dma_addr_t len)
{
#define FILLBUF_SIZE 512
uint8_t fillbuf[FILLBUF_SIZE];
int l;
memset(fillbuf, c, FILLBUF_SIZE);
while (len > 0) {
l = len < FILLBUF_SIZE ? len : FILLBUF_SIZE;
cpu_physical_memory_rw(addr, fillbuf, l, t... | 1threat |
How to calculate the percentage of word using SQL Query? : Actual case is to read the total count difference in percentage basis. Since hello comes in first word its count-'1' but in the 3rd rows Hello count -2. Now i need to calculate the percentage of the word usage like previously it is 1, now it is 2 percentage is ... | 0debug |
In Python - Can I access functions outside of a class not using inheritance or subclassing? : <p>After creating an instance of a class. If there is a function (I am using function because in this case because it is outside of the class so not a method) that I define outside of the class, can I access it?</p>
| 0debug |
Material-ui: outline version of icon : <p>I'm using material-ui in my react web application. I need the icon 'action/description' in a component but in the <em>outline</em> version. </p>
<p>According to the docs:</p>
<blockquote>
<p>For convenience, the full set of google Material icons are available
in Material-... | 0debug |
SonarQube rule: "Using command line arguments is security-sensitive" in Spring Boot application : <p>SonarQube is just showing a Critical security issue in the very basic Spring Boot application. In the main method.</p>
<pre><code>@SpringBootApplication
public class Application {
public static void main(String[] ... | 0debug |
Make Equal-Width SwiftUI Views in List Rows : <p>I have a <code>List</code> that displays days in the current month. Each row in the <code>List</code> contains the abbreviated day, a <code>Divider</code>, and the day number within a <code>VStack</code>. The <code>VStack</code> is then embedded in an <code>HStack</code>... | 0debug |
How to build glus.lib with MinGW and Sublime : I am in a similar situation :
http://stackoverflow.com/questions/15754872/eclipse-cpp-and-gnu-following-these-instructions
But i need to build GLUS with MinGW and sublime text.
I am learning C and OpenGL ,so i lake compilation/dependencies logic.
I would just like to... | 0debug |
parameters in for loop Javascript : 1. I am working on this project for school.
But I can not figure out one problem.
I have 2 lines of boxed both colored, but I use a for loop and in the parameters don't work in the for loop. the lines have both different places and different length. So I have this Question how cou... | 0debug |
int loader_exec(const char * filename, char ** argv, char ** envp,
struct target_pt_regs * regs, struct image_info *infop,
struct linux_binprm *bprm)
{
int retval;
int i;
bprm->p = TARGET_PAGE_SIZE*MAX_ARG_PAGES-sizeof(unsigned int);
memset(bprm->page, 0, sizeof(bprm->... | 1threat |
Docker: npm install behind proxy : <p>I have this Dockerfile:</p>
<pre><code>FROM node:argon
ENV http_proxy http://user:pass@proxy.company.priv:3128
ENV https_proxy https://user:pass@proxy.company.priv:3128
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
# Install app dependencies
COPY package.json /usr/src/app/
RUN... | 0debug |
Payment gateway integration problem in redirection from bcackend to front end in web application : In one of my web application which make use of spring boot and angular 6 environment i am trying to intigeate the payu payment gateway. Now the problem is they will post the success capture or failure capture data to what... | 0debug |
static void do_info_profile(Monitor *mon)
{
int64_t total;
total = qemu_time;
if (total == 0)
total = 1;
monitor_printf(mon, "async time %" PRId64 " (%0.3f)\n",
dev_time, dev_time / (double)ticks_per_sec);
monitor_printf(mon, "qemu time %" PRId64 " (%0.3f)\n",
... | 1threat |
static void string_output_append(StringOutputVisitor *sov, int64_t a)
{
Range *r = g_malloc0(sizeof(*r));
r->begin = a;
r->end = a + 1;
sov->ranges = g_list_insert_sorted_merged(sov->ranges, r, range_compare);
}
| 1threat |
What are selectors in redux? : <p>I am trying to follow this <a href="https://github.com/yelouafi/redux-saga/blob/7628def689433e678d78d9dd978c14162a1d45f1/examples/real-world/reducers/selectors.js#L2" rel="noreferrer">code</a> in <code>redux-saga</code></p>
<pre><code>export const getUser = (state, login) => state.... | 0debug |
Calculating the shortest distance between n GPS points : <p>I have for example 4 points: A (latitute1, longitude1), B (latitute2, longitude2), C (latitute3, longitude3), D (latitute4, longitude4).</p>
<p>If I am a driver and I go from point A, I need an algorithm that calculates the most efficient way for me to visit ... | 0debug |
Native Ads In React Native : <p>How do you implement AdMob's Native Ads in React Native? The best I've found is <a href="https://github.com/sbugert/react-native-admob" rel="noreferrer">react-native-admob</a>, but it only does fixed banners and full screen interstitials. How could I implement native ads <em>inside</em> ... | 0debug |
Strange output (C++) : (C++) I have written the following code, but the output is displaying weird values along the lines of 011512EE. I have no idea where this is coming from or how to fix it. [code][1]
[1]: http://i.stack.imgur.com/UDUhr.png | 0debug |
Need help in building functions in javascript : A parking garage charges a $2.00 minimum fee to park for up to three hours. It charges an additional $0.50 per hour for each hour or part thereof in excess of three hours. The maximum charge for any given 24-hour period is $10.00. Assume that no car parks for longer than ... | 0debug |
any tricks if script and script name modified to quit progrom : <p>Some one please provide me hints. If some one modify script name and modify script contents should not run.</p>
<p>Python 2.7</p>
| 0debug |
Is there a way to prevent fastclick from firing “active” state on scroll? : <p>I’m using <a href="https://github.com/ftlabs/fastclick">FastClick</a> on a page with large links because I want to bypass the 300ms delay for taps in mobile browsers. I have a “highlight” style for the links’ <code>:active</code> states and ... | 0debug |
Please help me!! Gradle Build failed : Information:Gradle tasks [:app:assembleDebug]
C:\Users\davis\AndroidStudioProjects\tester\app\src\main\res\values\dimens.xml
Error:Error: Found item Dimension/abc_alert_dialog_button_bar_height more than one time
Error:Execution failed for task ':app:mergeDebugResources'.... | 0debug |
Select an element with Javascript : <p>Hey Stackoverflow developers, I have this code</p>
<pre><code> <div id="1"></div><div id="2"></div><div id="3"></div><div id="4"></div><div id="5"></div><br>
<div id="6"></div><div id="7... | 0debug |
static void qjson_register_types(void)
{
type_register_static(&qjson_type_info);
}
| 1threat |
Making Azure Virtual Machine VPN-Ready : <p>My company is integrating with this company to enable us both consume services built on each other's platform to provide joint services extended to external users.</p>
<p>They recently sent me a file containing their VPN configuration with spaces provided to enter ours as we... | 0debug |
How to link push button and a new window by coding using QT? : First of all, I created about 20 push buttons using for loop. And named them using if else loop. Now, I want to connect each push buttons with the new dialog box. If I had used the design mode of QT, it would show me the name of the button when I press conn... | 0debug |
static void disas_test_b_imm(DisasContext *s, uint32_t insn)
{
unsigned int bit_pos, op, rt;
uint64_t addr;
int label_match;
TCGv_i64 tcg_cmp;
bit_pos = (extract32(insn, 31, 1) << 5) | extract32(insn, 19, 5);
op = extract32(insn, 24, 1);
addr = s->pc + sextract32(insn, 5, 14) * 4 ... | 1threat |
static int qxl_init_primary(PCIDevice *dev)
{
PCIQXLDevice *qxl = DO_UPCAST(PCIQXLDevice, pci, dev);
VGACommonState *vga = &qxl->vga;
PortioList *qxl_vga_port_list = g_new(PortioList, 1);
int rc;
qxl->id = 0;
qxl_init_ramsize(qxl);
vga->vram_size_mb = qxl->vga.vram_size >> 20;
... | 1threat |
Is there a way to write a lambda expression inside an IF with everything captured? : <p>It's my understanding that if I use the syntax [&] in a lambda expression, then my lambda expression has access to surrounding variables and parameters of the function.</p>
<p>Therefore, I tried to write the following (simplifi... | 0debug |
VueJS this in lodash throttled method : <p>I am trying to throttle a method in my VueJS application. I tried the following at first: </p>
<pre><code>export default {
data () {
return {
foo: 'bar'
}
},
methods: {
doSomething () {
console.log('olas')
}
... | 0debug |
Apple rejects app because it can't reach my ASP.NET API : I run my own VPS in Amsterdam where I have a MySQL database that is being populated and maintained using ASP.NET. It's a Windows Server.
I use this API for four of my existing Android apps (published and working) with a few thousand users who never had any ... | 0debug |
static int protocol_client_init(VncState *vs, uint8_t *data, size_t len)
{
char buf[1024];
VncShareMode mode;
int size;
mode = data[0] ? VNC_SHARE_MODE_SHARED : VNC_SHARE_MODE_EXCLUSIVE;
switch (vs->vd->share_policy) {
case VNC_SHARE_POLICY_IGNORE:
break;
... | 1threat |
Find text in array use preg_match : <p>I have code :</p>
<pre><code>Array
(
[0] => Array
(
[Time] => 05/24/2016 05:24
[Type] => Income
[Batch] => 134410438
[Currency] => USD
[Amount] => 60.00
[Fee] => 0.00
... | 0debug |
Keras: class weights (class_weight) for one-hot encoding : <p>I'd like to use class_weight argument in keras model.fit to handle the imbalanced training data. By looking at some documents, I understood we can pass a dictionary like this:</p>
<pre><code>class_weight = {0 : 1,
1: 1,
2: 5}
</code></pre>
<p>(In t... | 0debug |
static void qio_channel_websock_finalize(Object *obj)
{
QIOChannelWebsock *ioc = QIO_CHANNEL_WEBSOCK(obj);
buffer_free(&ioc->encinput);
buffer_free(&ioc->encoutput);
buffer_free(&ioc->rawinput);
buffer_free(&ioc->rawoutput);
object_unref(OBJECT(ioc->master));
if (ioc->io_tag) {
... | 1threat |
void ff_put_h264_qpel8_mc10_msa(uint8_t *dst, const uint8_t *src,
ptrdiff_t stride)
{
avc_luma_hz_qrt_8w_msa(src - 2, stride, dst, stride, 8, 0);
}
| 1threat |
Use Create-React-App with Material UI : <p>I'm new to Material UI and ReactJS. I've been playing around with <a href="https://github.com/facebookincubator/create-react-app" rel="noreferrer">Create-React-App (CRA)</a> and <a href="https://github.com/reactstrap/reactstrap" rel="noreferrer">reactstrap</a>.
My question is... | 0debug |
Python: Access members of a function from outside that function : <p>Say I had two functions, one belonging to another like so.</p>
<pre><code>def foo():
def bar():
print("im bar")
print("im foo and can call bar")
print("i can call foo, but not bar?")
</code></pre>
<p>How would refer to or call bar?
W... | 0debug |
Insertion order in nested map c++ : <p>I currently have a nested <code>map< int, map < int, char > > m;</code>. I have 2 int values as keys for x,y coordinates and I save a char <code>m[x][y]='A'. I tried inserting the values into a vector</code>map< vector, map< vector, char> > m;` but didn't work. I... | 0debug |
Difference between "ConstraintLayout for android" and "Solver for ConstraintLayout" in android studio SDK tools : <p>There is two option in android studio SDK tools for ConstraintLayout.One is <code>ConstraintLayout for android</code> and another is <code>Solver for ConstraintLayout</code>.</p>
<p>Here is the screensh... | 0debug |
static gboolean serial_xmit(GIOChannel *chan, GIOCondition cond, void *opaque)
{
SerialState *s = opaque;
do {
if (s->tsr_retry <= 0) {
if (s->fcr & UART_FCR_FE) {
if (fifo8_is_empty(&s->xmit_fifo)) {
return FALSE;
}
... | 1threat |
How to show errors/warnings by hotkey in VSCode? : <p>I have to show errors/warnings by mouse now. Is there any hotkey or special button? I could find nothing in "Keyboard Shortcuts". Example of error:</p>
<p><a href="https://i.stack.imgur.com/FfNN8.png" rel="noreferrer"><img src="https://i.stack.imgur.com/FfNN8.png" ... | 0debug |
static void apic_common_class_init(ObjectClass *klass, void *data)
{
ICCDeviceClass *idc = ICC_DEVICE_CLASS(klass);
DeviceClass *dc = DEVICE_CLASS(klass);
dc->vmsd = &vmstate_apic_common;
dc->reset = apic_reset_common;
dc->no_user = 1;
dc->props = apic_properties_common;
idc->init ... | 1threat |
how can i fix this Error in Wamp_Server? : <p><strong>I have problem in my wamp server . I dont know how to fix that . You can see the Error in photo ??</strong>
<a href="https://i.stack.imgur.com/xH0ES.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/xH0ES.png" alt="enter image description here"></a>... | 0debug |
HTML - Text/Button Alignment (CSS Media) : <blockquote>
<p><a href="https://jsfiddle.net/5d401nso/1/" rel="nofollow noreferrer">https://jsfiddle.net/5d401nso/1/</a></p>
</blockquote>
<pre><code>#mobileview{
/*background-image:url("");
background-size:100% 100%;*/
width:auto;
height:auto;
}
@media(max-width:... | 0debug |
UITabBarItem icon not colored correctly for iOS 13 when a bar tint color is specified in Interface Builder in Xcode 11, beta 2 : <p>I have a problem with the color of my UITabBarItems when I run on iOS 13 simulators, using Xcode 11, beta 2. I have made a sample project from scratch, and everything works correctly when... | 0debug |
static void qxl_log_cmd_draw_copy(PCIQXLDevice *qxl, QXLCopy *copy, int group_id)
{
fprintf(stderr, " src %" PRIx64,
copy->src_bitmap);
qxl_log_image(qxl, copy->src_bitmap, group_id);
fprintf(stderr, " area");
qxl_log_rect(©->src_area);
fprintf(stderr, " rop %d", copy->rop_des... | 1threat |
Python array program not giving correct output : <p>I am using below code for adding an element in array but it is giving me below error while running it</p>
<pre><code>cars = ["Ford", "Volvo", "BMW"]
cars.append("Honda")
cars[4] = "BMWq";
for x in cars:
print(x)
Output error
</code></pre>
<p>List assignment in... | 0debug |
How to read test files one by one in vb.net : i am working on a project in which i need to read text files in programs directory and check for specific keywords in it. Eg. A folder contains files with some name (not specific) and i want to read them one by one to check for specific string in them. until all are checked... | 0debug |
i want to use some arabic letters in card view as text in my android app : i want to use some arabic letters in card view as text in my android app , how to achieve this. Anyone please help me. | 0debug |
How to create DateTime from an int6] : The syntax of DateTime: it requires 6 arguments.`DateTime date1 = new DateTime(2008, 1, 1, 6, 32, 0);` If I have `int[] dr = new int[]{2008, 1, 1, 6, 32, 0};` How can I create the DateTime value using the int[] e.g. `DateTime date1 = new DateTime(dr);` ?
` | 0debug |
Why are generics needed when we can do casting to Object class? : <p>We have generics in java using which we can generalize a class.
I know that Object class is the parent class of every class.</p>
<p>When I can typecast to and from Object then why generics are needed?</p>
<pre><code>class Response<T>{
T da... | 0debug |
Which classifier should I use for game automation? : <p>I suppose I have to pick one from this list:</p>
<p><a href="http://scikit-learn.org/stable/modules/scaling_strategies.html" rel="nofollow noreferrer">http://scikit-learn.org/stable/modules/scaling_strategies.html</a></p>
<p>As I need incremental learning.</p>
... | 0debug |
Is it functionally/ practically more efficient to create a CLI program that uses Console.Readline();, or args[i] for input? : <p>When creating a console based app, is it functionally more efficient/ practically more efficient to run off of command line start arguments than it is to use <code>Console.ReadLine();</code>?... | 0debug |
There is a way to make a request every .txt file line? : <p>I'm doing a roblox name checker. Only except code works.</p>
<p>I've tried things like with open(...)as f:,etc.</p>
<pre class="lang-py prettyprint-override"><code>with open('usernames.txt') as f:
for line in f:
a=requests.get('https://api.roblox... | 0debug |
static int applehttp_close(URLContext *h)
{
AppleHTTPContext *s = h->priv_data;
free_segment_list(s);
free_variant_list(s);
ffurl_close(s->seg_hd);
av_free(s);
return 0;
}
| 1threat |
static int get_cluster_offset(BlockDriverState *bs,
VmdkExtent *extent,
VmdkMetaData *m_data,
uint64_t offset,
bool allocate,
uint64_t *cluster_offset,
... | 1threat |
Returning fun messages to different injections : <p>I am developing an web application. Where there is an input box to track the orders and its open for anyone. I want to return funny messages if somebody tries to inject vulnerable scripts. For example, if anyone tries the old school trick</p>
<pre><code>' OR '1'='1
<... | 0debug |
grab all observations from a data set that are present in a second data set based on a linker ID using %in% function R : <p>So, say I have two data sets: </p>
<pre><code>d1<- data.frame(seq(1:10),rnorm(10))
colnames(d1) <- c('id','x1')
d2<- data.frame(seq(3:7),rnorm(5))
colnames(d2) <- c('id','x2')
</code... | 0debug |
Make tab labels stretch to full width in material design for angular : <p>I would like to get tabs to stretch to the full width of their parent div. Anyone know how to do this?</p>
<pre><code><div class="tabs-header">
<mat-tab-group>
<mat-tab label="Signup">Content 1</mat-tab>
... | 0debug |
Write something in .txt file using javascript : <p>How do I write something in a .txt file using javascript?</p>
<p>I created a variable holding a specific value and now I want to safe it into a .txt file</p>
| 0debug |
how can i add values with the same "account title" and display this in my gridview using vb.net / aspx : [This is the source grid view with a sql datasource named trialbalance][1]
[1]: http://i.stack.imgur.com/bA2jO.jpg
[Output gridview should look like this...][2]
[2]: http://i.stack.imgur.com/M9Qmd.jpg | 0debug |
How would I generate a random and unique title in cpp : <p>im kind of new to cpp coding. Anyway I was wondering how I would add random and unique titles to my program that change every time I open it, EG: If i sent a friend a file it might be called <strong>2377213</strong> the first time he opens it but then second ti... | 0debug |
Detect AND, OR in the sentence and split it : <p>I have the following user queries:</p>
<pre><code>Boeing AND Airbus OR twitter
Boeing AND Airbus
</code></pre>
<p>I need to split words in them by AND, OR so, in the end, I will have something like this:</p>
<pre><code>"Boeing" AND "Airbus"
"Boeing" AND "Airbus" OR "t... | 0debug |
I have 4 SQL tables that all i am using same primary key i need below condition SQL Quey : I have 4 [ client,clientmanager,Employee,project] tables in sql that all tables i am using primarykey for same (clientid) so i like to count list of projects,Employee,clients mangers using 'clientid " | 0debug |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.