problem
stringlengths
26
131k
labels
class label
2 classes
How does python pass keyword changes values in list : I have one small code in python. I have created list and I am passing it as function parameter. According to me it should give output as 1 2 3 4 5. But it is giving me 5 2 3 4 5 as output. If I am just writing 'pass' keyword inside for loop then it should not do an...
0debug
static CCIDBus *ccid_bus_new(DeviceState *dev) { CCIDBus *bus; bus = FROM_QBUS(CCIDBus, qbus_create(&ccid_bus_info, dev, NULL)); bus->qbus.allow_hotplug = 1; return bus; }
1threat
How to configure react-script so that it doesn't override tsconfig.json on 'start' : <p>I'm currently using <code>create-react-app</code> to bootstrap one of my projects. Basically, I'm trying to set up paths in tsconfig.json by adding these to the default tsconfig.json generated by create-react-app:</p> <pre><code>"b...
0debug
static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_idx, InputStream *ist, int in_program) { AVStream *stream = ist->st; AVCodecParameters *par; AVCodecContext *dec_ctx; char val_str[128]; const char *s; AVRational sar, dar; AVBPrint pbuf; const AVCodec...
1threat
static int gif_parse_next_image(GifState *s) { ByteIOContext *f = s->f; int ret, code; for (;;) { code = url_fgetc(f); #ifdef DEBUG printf("gif: code=%02x '%c'\n", code, code); #endif switch (code) { case ',': if (gif_read_image(s) < 0) ...
1threat
How can i to make anagram program using who char with dynamic array? : this is the Code i have, what should i do ? it's not event a String. it use dynamic Array. i dont event know what i should to do. thanks import java.util.ArrayList; import java.util.Collections; public class ArrayCheck { ...
0debug
Angular 4 setting selected option in Dropdown : <p>several questions about this and diffrent answeres. But none of them realy answeres the question. So again:</p> <p>Setting default of a Dropdown select by value isnt working in my case. why? This is from the dynamic Form tutorial of Angular 4:</p> <pre><code>&lt;sele...
0debug
static void virtio_vga_realize(VirtIOPCIProxy *vpci_dev, Error **errp) { VirtIOVGA *vvga = VIRTIO_VGA(vpci_dev); VirtIOGPU *g = &vvga->vdev; VGACommonState *vga = &vvga->vga; Error *err = NULL; uint32_t offset; int i; vga->vram_size_mb = 8; vga_common_init(vga, OBJECT(vp...
1threat
unable to implement OnClickListener into seperate java class (android studio) : OnClickListener works fine when i implement on MainActivity class of java .But its a messy practice to use on same class of main interference. So i add a separate java class "ButtonListener.java" and wrote the following code p...
0debug
void x86_cpu_list (FILE *f, int (*cpu_fprintf)(FILE *f, const char *fmt, ...), const char *optarg) { unsigned char model = !strcmp("?model", optarg); unsigned char dump = !strcmp("?dump", optarg); unsigned char cpuid = !strcmp("?cpuid", optarg); x86_def_t *def; char buf[256]...
1threat
How can i sum two or more numbers(possibility for client to enter two or more numbers) same for Subtraction, Multiplication and Division c# : using System; using System.Linq; namespace Kalkulator { internal class Program { private static void Main(string[] args) { switch (C...
0debug
Replace items in a list by for in statement ( Python) : <p>I am a new Python user and I am wondering how to replace every integer in a list with str variables? </p> <p>I used the for-in statement, but it is not working. Please let me know how I can make the code work? Thank you so much! </p> <p><a href="https://i.sta...
0debug
How can I see the current version of packages installed by pipenv? : <p>I'm managing my Python dependencies with <a href="https://pipenv.readthedocs.io/en/latest/" rel="noreferrer">pipenv</a>. How can see the currently installed versions of packages?</p> <p>I could examine <code>Pipfile.lock</code>, but is there a si...
0debug
Is there Multimap in Kotlin? : <p>I need to store values in map likie this:</p> <pre><code> val map = HashMap&lt;String, Set&lt;String&gt;&gt;() </code></pre> <p>But it is hard to interact with Set inside the map.</p> <p>Is there any multimap implementations in Kotlin like <a href="https://google.github.io/guava/rel...
0debug
what's the difference between the two function? : def PartitionDemo(a,p,r): x=a[p] start=p end=r while start<end : while start<end and a[end]>=x : end-=1 while start<end and a[start]<x : a[start]=a[end] start+=1 a[end]=a[start] ...
0debug
JAVA class hierarchy: Which of the following lines will not compile? : <p>Having the following class hierarchy:</p> <pre><code>Interface Animal {…} class Dog implements Animal{…} class Poodle extends Dog {…} class Labrador extends Dog {…} </code></pre> <p>Which of the following lines will not compile? </p> <pre><cod...
0debug
Need explaining on what code does : <p>So I have this code because I need to add photos to my JTable and so I need to make an abstract table model. However, after seeing this code I seriously have no idea what It does, but I really want to understand it. If you could please explain it to me that would be awesome! (I al...
0debug
Use a generator for Keras model.fit_generator : <p>I originally tried to use <code>generator</code> syntax when writing a custom generator for training a Keras model. So I <code>yield</code>ed from <code>__next__</code>. However, when I would try to train my mode with <code>model.fit_generator</code> I would get an err...
0debug
static inline void gen_op_eval_bge(TCGv dst, TCGv_i32 src) { gen_mov_reg_V(cpu_tmp0, src); gen_mov_reg_N(dst, src); tcg_gen_xor_tl(dst, dst, cpu_tmp0); tcg_gen_xori_tl(dst, dst, 0x1); }
1threat
using an enviroment variable for local sequelize configuration : <p>I'm looking to use an environment variable inside of the config.json file of my project using sequelize. I'm using dotenv to set environment variables locally. My config.json file looks like this</p> <pre><code>{ "development": { "username": pro...
0debug
How to send button value to datagridview? : How to send a button value to data grid view ,if the data grid view cell is last focus then the button value goes to last focus cell.
0debug
static uint64_t get_cluster_offset(BlockDriverState *bs, uint64_t offset, int *num) { BDRVQcowState *s = bs->opaque; int l1_index, l2_index; uint64_t l2_offset, *l2_table, cluster_offset; int l1_bits, c; int index_in_cluster, nb_available, nb_needed, nb_clusters; ...
1threat
disabling navlink react router : <p>I am using react router in and I want to disable the to attribute in a certain state. I passed empty string, but that doesn't disable the link instead it takes to the base route of the page. I even tried to pass null but that breaks the code. Is it even possible to do so?</p> <pre><...
0debug
static int handle_utimensat(FsContext *ctx, V9fsPath *fs_path, const struct timespec *buf) { int ret; #ifdef CONFIG_UTIMENSAT int fd; struct handle_data *data = (struct handle_data *)ctx->private; fd = open_by_handle(data->mountfd, fs_path->data, O_NONBLOCK); if...
1threat
def min_of_three(a,b,c): if (a <= b) and (a <= c): smallest = a elif (b <= a) and (b <= c): smallest = b else: smallest = c return smallest
0debug
Is there any tool for monitoring Memory Management? : <p>I know we can check in android studio itself, but i want separate tool for testing.please can any one suggest what are the tools are available for test for android app performance....</p>
0debug
unsigned int EmulateAll(unsigned int opcode, FPA11* qfpa, CPUARMState* qregs) { unsigned int nRc = 0; FPA11 *fpa11; qemufpa=qfpa; user_registers=qregs; #if 0 fprintf(stderr,"emulating FP insn 0x%08x, PC=0x%08x\n", opcode, qregs[REG_PC]); #endif fpa11 = GET_FPA11(); if (fpa11...
1threat
How to debug this debugger error? : I am using `SQLite` Database to get the product name, quantity, price but when ever i press add_to_cart button, it force closes. [This is what my debugger says, how to debug this ][1] public void addToCart(Order order){ SQLiteDatabase db = getReadableDatabase(); ...
0debug
How to create optional RewriteCond in Apache : <p>i have touble for my .htaccess config., this is part of config:</p> <pre><code>RewriteCond %{QUERY_STRING} ^token=(.*) RewriteRule ^aplikasi/(.*).asp aplikasi.php?halaman=$1&amp;token=%1 </code></pre> <p>and result that config is:</p> <pre><code>http://{domain}/aplik...
0debug
query = 'SELECT * FROM customers WHERE email = ' + email_input
1threat
Javscript object with shared name : So, I'm trying to create an object like: var a = { b:"object_id", b:function(){ return c(this.b); } } var c = { "object_id": { foo: "bar" } } But it only registers the last value for the key 'b'. But I think I've seen something like t...
0debug
Chrome extension page action appearing outside of address bar : <p>I wrote a Chrome Extension page action, with the following implementation:</p> <p>In manifest.json:</p> <pre><code> "permissions" : [ "declarativeContent" ], </code></pre> <p>In background.js:</p> <pre><code>chrome.runtime.onInstalled.addLi...
0debug
IoT speed sensor : <p>Do you know any IoT sensor for speed detection of a human and sending it to a mobile application?</p> <p>In other words, I am looking for a very small IoT sensor that sends the speed data of players of a sports team to a mobile application.</p>
0debug
static CharDriverState *qemu_chr_open_stdio(const char *id, ChardevBackend *backend, ChardevReturn *ret, Error **errp) { ChardevStdio *opts = backend->u.stdio; CharDriverStat...
1threat
How can I make Elixir mix test output more verbose? : <p>In my Elixir/Phoenix app, when I run</p> <pre><code>mix test </code></pre> <p>I get output like:</p> <pre><code>$ mix test .... Finished in 0.09 seconds 4 tests, 0 failures </code></pre> <p>with dots for each test that succeeded. </p> <p>How do I output the...
0debug
static uint32_t sdhci_read_dataport(SDHCIState *s, unsigned size) { uint32_t value = 0; int i; if ((s->prnsts & SDHC_DATA_AVAILABLE) == 0) { ERRPRINT("Trying to read from empty buffer\n"); return 0; } for (i = 0; i < size; i++) { value |= s->fifo_buffer[s->...
1threat
Thumbnail Metadata Disappeared When Importing File with Copy to App : <p>I have been using the URL Resources to embed the thumbnail metadata into my custom document-based file. When I export my custom document file, the thumbnail shows up nicely when glanced in iOS Files app.</p> <pre><code>override func fileAttribute...
0debug
How can I replace ~60 print entries in 5 different files using vim or sed? : <p>Fabfile (directory) containing Python files:</p> <pre><code>print "DEBUG fab_helper DRYRUN: True"+var print "DEBUG fab_helper DRYRUN: True" #print "DEBUG cfn_stackname: "+cfn_stackname </code></pre> <p>To:</p> <pre><code>LOGGER.DEBUG("DE...
0debug
getting Invalid json error when I am decoding below data using json_decode in PHP : <p>[{\\"field_display_txt\\":\\"New custom field phone\\",\\"field_value\\":0},{\\"field_display_txt\\":\\"New custom field\\",\\"field_value\\":\\"test_zapier\\"},{\\"field_display_txt\\":\\"New custom field select\\",\\"field_value\\"...
0debug
How do c++ compilers find an extern variable? : <p>I compile this program by g++ and clang++. There has a difference:<br> g++ prints 1, but clang++ prints 2.<br> It seems that<br> g++: the extern varible is defined in the shortest scope.<br> clang++: the extern varible is defined in the shortest global scope.</p> <p>D...
0debug
void memory_region_set_address(MemoryRegion *mr, hwaddr addr) { MemoryRegion *parent = mr->parent; int priority = mr->priority; bool may_overlap = mr->may_overlap; if (addr == mr->addr || !parent) { mr->addr = addr; return; } memory_region_transaction_begin(); m...
1threat
How to highlight table tennis plates in Openlayers? : I want to highlight all table tennis plates in ol. The tag ist leisure=table_tennis_table and i know there is a possibility to do it with ol.style. Pls help
0debug
void ppc_cpu_list (FILE *f, int (*cpu_fprintf)(FILE *f, const char *fmt, ...)) { int i; for (i = 0; ; i++) { (*cpu_fprintf)(f, "PowerPC %-16s PVR %08x\n", ppc_defs[i].name, ppc_defs[i].pvr); if (strcmp(ppc_defs[i].name, "default") == 0) break; } ...
1threat
static int thread_init(AVCodecContext *avctx) { int i; ThreadContext *c; int thread_count = avctx->thread_count; if (!thread_count) { int nb_cpus = get_logical_cpus(avctx); if (nb_cpus > 1) thread_count = avctx->thread_count = nb_cpus + 1; } if...
1threat
bash: What are the purposes of the two semicolons in echo? : Can someone explain the meaning of the following bash script? I am mainly confused about the echo usage. What are the purposes of the two semicolons? for addr in $@; do for i in $(seq 8 -2 2); do echo -ne "\x${addr:$i:2}"; done done
0debug
Keep only numbers between spesific letters : I want to keep a value in several seperated long text strings with one part in common. One of the text strings: N-05-0040(119) f 2005 svart hp Ml:153 - 160 - 20 - 75 Tot 31- 3- 3- 6- 13 (4)29,7M - (4)28,2aK Kr 204.500, 2pr 2010, Trener: Ole Olesen The common part i...
0debug
Databricks error when trying to load a module using apache spark : <p>I'm using a notebook within Databricks. The notebook is set up with python 3 if that helps. Everything is working fine and I can extract data from Azure Storage. However when I run:</p> <p><code>import org.apache.spark.sql.types.StructType</code></p...
0debug
how to store vector in a vector c++ : <p>I want to store some int vectors into a vector, so firstly I initialize a vector type vector, then iterate for begin to end, and store int numbers into each subvectoer from 0 to 4 like below code: </p> <pre><code>std::vector&lt;std::vector&lt;int&gt; &gt; v(12); void fun_1(st...
0debug
How to dynamically add/remove show fields in Sonata Admin : <p>I wanted to remove some show fields that are only relevant if some other fields have a certain value, but the entity cannot be accessed from the admin class.</p>
0debug
C# out parameter and dictionary : <p>I've a dictionary object in my C# code:dictEmployees;---></p> <p>It has a list of all Employees.Employee class has two properties...Id and Salary.Lets say, Initially, this collection has a salary of 50K for employee Id 1.</p> <pre><code>Employee employee = new Employee(); dictEmpl...
0debug
linux fio write the disk , how to recover .very urgent. help me,please, : I`m use os is CentOS release 6.6 . today , i want to test the disk write speed. i have a 500g disk is /dev/sdc. i use the cmd : fio -filename=/dev/sdc -direct=1 -iodepth 1 -thread -rw=randwrite -ioengine=psync -bs=16k -size=1G -numjobs=5 -...
0debug
why static variable intialised in each calling of function but we have to declare it everytime in C : I read that : static variable is initialised only once (unlike auto variable) and further defination of static variable would be bypassed during runtime. [from the link][1]. then why I am getting error that "i was ...
0debug
Java script get an object array filtered only with certain properties : I have an array of objects(object is `<Employee>` type) as shown below, [{i: "MCA001", j: 4, n: "KEITH G MCALLISTER", m: null, a: 1, …} , {...}] i want this <Employee> object array filtered with certain properties, for an instance, ...
0debug
Converting Time how can I improve my code? : <p>Just started programming so any suggestion or constructive criticism would be much appreciated. I'm pretty sure there are ways to shorten this I just don't know how, especially the use of functions.</p> <pre><code>#include &lt;stdio.h&gt; #include &lt;stdlib.h&gt; int i...
0debug
How to run a cronjob every 50 minutes? : <p>I want to run cron job in following manner</p> <p>00:00 00:50 01:40 02:30 and so on</p> <p>how can i setup cron tab so it works like this</p>
0debug
int ga_install_service(const char *path, const char *logfile, const char *state_dir) { int ret = EXIT_FAILURE; SC_HANDLE manager; SC_HANDLE service; TCHAR module_fname[MAX_PATH]; GString *cmdline; SERVICE_DESCRIPTION desc = { (char *)QGA_SERVICE_DESCRIPTION }; ...
1threat
How to prevent Browser cache on Angular 2 site? : <p>We're currently working on a new project with regular updates that's being used daily by one of our clients. This project is being developed using angular 2 and we're facing cache issues, that is our clients are not seeing the latest changes on their machines.</p> <...
0debug
How to pass multiple parameters to middleware with OR condition in Laravel 5.2 : <p>I am trying to set permission to access an action to two different user roles Admin, Normal_User as shown below.</p> <pre><code>Route::group(['middleware' =&gt; ['role_check:Normal_User','role_check:Admin']], function() { Route...
0debug
How to monitor websocket frames in firefox : <p>I know there was an extension called 'websocket-monitor', but it's no longer available.</p> <p>It seems that nobody can view websocket frames by firefox. </p>
0debug
$ {I} and ${colours[i]} is not printing the values in console? : <pre><code>const colors = ['Red', 'Green', 'Blue'] for(let i=0, max = colors.length; i&lt; max; i++) { console.log('Color at position ${i} is ${colors[i]}'); } </code></pre> <p>output: Color at position ${i} is ${colors[i]}</p>
0debug
what the problem with my code is bien repeating 5 time : import React, { Component } from "react"; class App extends Component { state = {value: [{title: "my title",category: "action",replies: "62",views: "26k",activity: "18h"}]}; render() {return ( <div>{this.state.value ? this.state.value.map(valu => Object.keys(...
0debug
return cur == NULL ? -1 : cur->val; (I am confused for this c++ sentence) : <pre><code> /** Helper function to return the index-th node in the linked list. */ SinglyListNode* getNode(int index) { SinglyListNode *cur = head; for (int i = 0; i &lt; index &amp;&amp; cur; ++i) { cur = cur-&gt;next; }...
0debug
int32 float128_to_int32_round_to_zero( float128 a STATUS_PARAM ) { flag aSign; int32 aExp, shiftCount; uint64_t aSig0, aSig1, savedASig; int32 z; aSig1 = extractFloat128Frac1( a ); aSig0 = extractFloat128Frac0( a ); aExp = extractFloat128Exp( a ); aSign = extractFloat128Sign( ...
1threat
static void float_number(void) { int i; struct { const char *encoded; double decoded; int skip; } test_cases[] = { { "32.43", 32.43 }, { "0.222", 0.222 }, { "-32.12313", -32.12313 }, { "-32.20e-10", -32.20e-10, .skip = 1 }, { }, ...
1threat
static void cortex_a15_initfn(Object *obj) { ARMCPU *cpu = ARM_CPU(obj); set_feature(&cpu->env, ARM_FEATURE_V7); set_feature(&cpu->env, ARM_FEATURE_VFP4); set_feature(&cpu->env, ARM_FEATURE_VFP_FP16); set_feature(&cpu->env, ARM_FEATURE_NEON); set_feature(&cpu->env, ARM_FEATURE_THUMB2EE); ...
1threat
Maven on Windows Subsystem For Linux : <p>I'm trying to run maven on Windows Subsystem for Linux, and getting "cannot allocate memory" errors. However, <em>free -m</em> shows that I have plenty of memory available, and the same build on Cygwin succeeds.</p> <p>Anyone have any tips for dealing with this? I'd prefer to ...
0debug
static int dvbsub_parse_region_segment(AVCodecContext *avctx, const uint8_t *buf, int buf_size) { DVBSubContext *ctx = avctx->priv_data; const uint8_t *buf_end = buf + buf_size; int region_id, object_id; int av_unused version; DVBSubRegion *region; ...
1threat
When I float the div to the right the screen messes up...I've tried clear and some other options... : I'm having an issue in general when it comes to floats. I'll be doing fine with the layout but once I start floating the whole page does weird stuff. I think I need a better understanding of the concept of what goes on...
0debug
What is difference between echo and return in shortcode function with wordpress? : <p>I found both 'echo' and 'return' are working fine to display in shortcode function.</p> <pre><code>function display_shortcode_content($atts) { echo "COMES"; } function display_shortcode_content($atts) { return "COMES"; } <...
0debug
IE11 - does a polyfill / script exist for CSS variables? : <p>I'm developing a webpage in a mixed web browser environment (Chrome/IE11). IE11 doesn't support CSS variables, is there a polyfill or script that exists that would allow me to use CSS variables in IE11?</p>
0debug
static int mjpeg_decode_sof0(MJpegDecodeContext *s, UINT8 *buf, int buf_size) { int len, nb_components, i, width, height; init_get_bits(&s->gb, buf, buf_size); len = get_bits(&s->gb, 16); if (get_bits(&s->gb, 8) != 8) return -1; height = g...
1threat
Instagram. Given a User_id, how do i find the username? : <p>I have a list of thousands of instagram user-ids. How do i get their Instagram usernames/handles? </p> <p>Thanks</p>
0debug
Error when checking model input: expected lstm_1_input to have 3 dimensions, but got array with shape (339732, 29) : <p>My input is simply a csv file with 339732 rows and two columns :</p> <ul> <li>the first being 29 feature values, i.e. X</li> <li>the second being a binary label value, i.e. Y</li> </ul> <p>I am tryi...
0debug
Verify container running state : <p>I have a <code>bash</code> script, which I use to run several <code>Docker</code> containers. Initialization time differs on system specifications, so sometimes these cannot be started in specified order. How can I detect with use of <code>bash</code>, that a container is running, so...
0debug
AngularJS and UI-Router: 'Error: transition superseded' during angularjs unit tests : <p>I'm attempting to create an authorization package for a project of mine. I'm getting the error 'transition superseded' during my unit tests, and I can't find out where that would actually be.</p> <p>Unit test:</p> <pre><code>impo...
0debug
Kotlin: How can I create a "static" inheritable function? : <p>For example, I want to have a function <code>example()</code> on a type <code>Child</code> that extends <code>Parent</code> so that I can use the function on both.</p> <pre><code>Child.example() Parent.example() </code></pre> <p>The first "obvious" way to...
0debug
$.post function does not work, gives out no errors : <p>I want to retrieve data from a mySQL server by using jQuery, which triggers a PHP script to receive the data. However, the <code>$.post</code> function from jQuery does not work at all and corrupts all the code, and I don't understand why.</p> <p>Here is my JS co...
0debug
Insert Comma Separated String in SQLLITE : I need to insert coordinates in SQLLIte Table in Android My Query is as below . Its gives a Syntax error due to cordinates which contain string by comma separated information . INSERT INTO "tableNonOilFarmer" ("farmerId","FirstName","MiddleName","LastName","Fat...
0debug
Is there any Tool available to validate sabre production credentials : <p>Is there any tool available to check sabre production credentials - (PCC) and can check the fares which we get in response like travelport provide us demo site where we can add our custom credentials and check.</p>
0debug
How to boot an NTFS Partition in Archlinux : <p>I just did a dual boot Win10/arch, i'm currently meeting an issue where I successfully auto-mount a NTFS partition but only on Read-Only and I need to "write" permission on it, I followed this method in order to boot at the start.</p> <p><a href="https://www.youtube.com/...
0debug
static void wait_for_aio(void) { while (aio_poll(ctx, true)) { } }
1threat
int bdrv_append_temp_snapshot(BlockDriverState *bs, int flags, Error **errp) { char *tmp_filename = g_malloc0(PATH_MAX + 1); int64_t total_size; QemuOpts *opts = NULL; QDict *snapshot_options; BlockDriverState *bs_snapshot; Error *local_err; int ret; tota...
1threat
I cannot pass a (String-)value to another class's setter method : <p>I know that i have not written a catch block yet.(reason?, but i think it's actually not the problem; the attributes of the "Game" class are perfectly changeable)</p> <p>I always get an IOException when i try to call the setName method in Player (eve...
0debug
void qemu_get_guest_memory_mapping(MemoryMappingList *list, Error **errp) { CPUState *cpu, *first_paging_enabled_cpu; RAMBlock *block; ram_addr_t offset, length; first_paging_enabled_cpu = find_paging_enabled_cpu(first_cpu); if (first_paging_enabled_cpu) { for (cpu = first_paging_en...
1threat
static void m48t59_isa_class_init(ObjectClass *klass, void *data) { DeviceClass *dc = DEVICE_CLASS(klass); dc->realize = m48t59_isa_realize; dc->no_user = 1; dc->reset = m48t59_reset_isa; dc->props = m48t59_isa_properties; }
1threat
Capture UIKeyCommand for Function Keys on iOS : <p>I am trying to capture the F5 key on an external bluetooth keyboard in an iOS application. I have set up the UIKeyCommands, yet I cannot figure out how to create a UIKeyCommand that would capture the function keys. There is no option for UIKeyModifierFunction.</p>
0debug
turn warning off in a cell jupyter notebook : <p>I get some useless warnings in python 3 jupyter notebook. I want to turn off these warnings in a particular cell only, so not in the rest of the ipynb-file. Does someone know how to do this?</p>
0debug
Query decryption data SQL : It would like me know if, exists a native tool of the SQL for encryption some fields, put when making and execute a query, the SQL decrypt automatically.
0debug
static void RENAME(yuyvtoyuv420)(uint8_t *ydst, uint8_t *udst, uint8_t *vdst, const uint8_t *src, long width, long height, long lumStride, long chromStride, long srcStride) { long y; const long chromWidth= -((-width)>>1); fo...
1threat
connection.query('SELECT * FROM users WHERE username = ' + input_string)
1threat
int coroutine_fn bdrv_co_pwritev(BdrvChild *child, int64_t offset, unsigned int bytes, QEMUIOVector *qiov, BdrvRequestFlags flags) { BlockDriverState *bs = child->bs; BdrvTrackedRequest req; uint64_t align = bs->bl.request_alignment; uint8_t *head_buf = NULL; uint8_t *tail_buf = NULL...
1threat
static int os_host_main_loop_wait(uint32_t timeout) { GMainContext *context = g_main_context_default(); int select_ret, g_poll_ret, ret, i; PollingEntry *pe; WaitObjects *w = &wait_objects; gint poll_timeout; static struct timeval tv0; ret = 0; for (pe = first_polling_en...
1threat
static void vfio_msi_enable(VFIOPCIDevice *vdev) { int ret, i; vfio_disable_interrupts(vdev); vdev->nr_vectors = msi_nr_vectors_allocated(&vdev->pdev); retry: vdev->msi_vectors = g_malloc0(vdev->nr_vectors * sizeof(VFIOMSIVector)); for (i = 0; i < vdev->nr_vectors; i++) { VFIOM...
1threat
my sql query is not working i had many try : this is my sql query i wanted to store date and time whenever a user come and post comments over my website. but showing me this context "Parse error: syntax.. code'error, unexpected 'now' (T_STRING) in" $qry1='insert into life(title,quotation,photos,datetime...
0debug
What is the correct way to import and use d3 and its submodules in ES6? : <p>I'm trying to use a number of d3 packages in a Vue.js project with NPM for package management. I was trying to make a fiddle of a problem I'm having but am unable to replicate the issue there - the code works exactly as it should do.</p> <p>I...
0debug
what does the statement means in Java? : <p>I find a strange statement while reading the openjdk resources. <a href="https://i.stack.imgur.com/ElYbv.png" rel="nofollow noreferrer">enter image description here</a></p> <p>what does the "found:{}" means?</p>
0debug
static uint64_t pci_read(void *opaque, hwaddr addr, unsigned int size) { AcpiPciHpState *s = opaque; uint32_t val = 0; int bsel = s->hotplug_select; if (bsel < 0 || bsel > ACPI_PCIHP_MAX_HOTPLUG_BUS) { return 0; } switch (addr) { case PCI_UP_BASE - PCI_HOTPLUG_ADDR: ...
1threat
Google AdMob error after update to Xcode 11 Swift 5.1 : <p>Since I have updated to Xcode 11 the interstitial ads in my app won't load anymore. (Before that everything worked fine. The app was even released on the App Store. We are now creating an updated version of the app)</p> <p>I installed the Google AdMobs SDK vi...
0debug
static void intel_hda_update_int_sts(IntelHDAState *d) { uint32_t sts = 0; uint32_t i; if (d->rirb_sts & ICH6_RBSTS_IRQ) { sts |= (1 << 30); } if (d->rirb_sts & ICH6_RBSTS_OVERRUN) { sts |= (1 << 30); } if (d->state_sts & d->wake_en) { sts |= (1 << ...
1threat
static int ioreq_parse(struct ioreq *ioreq) { struct XenBlkDev *blkdev = ioreq->blkdev; uintptr_t mem; size_t len; int i; xen_be_printf(&blkdev->xendev, 3, "op %d, nr %d, handle %d, id %" PRId64 ", sector %" PRId64 "\n", ioreq->req.operation, ioreq->req.nr_segments, ioreq->req...
1threat