problem
stringlengths
26
131k
labels
class label
2 classes
Given a key value string values, how to encode a key and not the content (Python 3) : <p>Given a key: value (name="My name is Bill"), in Python 3, I am trying to encode the key (that's name). Standard approaches like name.encode etc end up encoding the content. Need to encode it to bytes as next step </p>
0debug
void *cpu_physical_memory_map(target_phys_addr_t addr, target_phys_addr_t *plen, int is_write) { return address_space_map(&address_space_memory, addr, plen, is_write); }
1threat
static int mcf_fec_can_receive(void *opaque) { mcf_fec_state *s = (mcf_fec_state *)opaque; return s->rx_enabled; }
1threat
static void do_acpitable_option(const char *optarg) { if (acpi_table_add(optarg) < 0) { fprintf(stderr, "Wrong acpi table provided\n"); exit(1); } }
1threat
db.execute('SELECT * FROM products WHERE product_id = ' + product_input)
1threat
How to chain match and replace in JavaScript : str="abc { return false;}" I just want to get the word "false" from the string "str", as follows, str.match(/return \w+;/g).replace(/return/,"") It 's wrong ! How can I correct this expression to get the desired word?
0debug
Material UI doesn't select a SelectField on hitting 'tab' : <p>Using <a href="http://www.material-ui.com/" rel="noreferrer">Material UI</a> for some components in my app. I added a <code>&lt;SelectField /&gt;</code> <a href="http://www.material-ui.com/#/components/select-field" rel="noreferrer">select field</a> in a f...
0debug
static void do_eject(int argc, const char **argv) { BlockDriverState *bs; const char **parg; int force; parg = argv + 1; if (!*parg) { fail: help_cmd(argv[0]); return; } force = 0; if (!strcmp(*parg, "-f")) { force = 1; parg++; } ...
1threat
Should I use React.PureComponent everywhere? : <p>React says pure render can optimize performance. And now React has PureComponent. Should I use React.PureComponent everywhere? Or when to use React.PureComponent and where is the most proper postion to use React.PureComponent?</p>
0debug
Does Microsoft provide a swagger file for Graph? : <p>I've crawled though as much documentation as I can find but I'm unable to find a swagger file for <a href="https://graph.microsoft.io/" rel="noreferrer">https://graph.microsoft.io/</a></p> <p>There appear to be a couple of variations on this API and I've seen refer...
0debug
I am trying to build a tree in php from an xml file : I am trying to read this xml file, but the code I am trying to make should work for any xml-file: [xml-file][1] I am using these two [functions][2] to turn the xml-file into an array and turn that array into a tree. I am trying to keep the parent child relationsh...
0debug
Java: 2-dimensional char Array : <p>i've been trying to programm a game called Sokoban the last few days. The levels of the game are simple .txt files you can swap. I've already read the .txt file by using BufferedReader but have problems with saving it to an 2-dimensional char array because the number of rows and colu...
0debug
Notice "Undifined Variable" : <p>I am running a PHP script, and keep getting errors like: <a href="http://i.stack.imgur.com/89eot.png" rel="nofollow">this is my error</a></p> <p><a href="http://i.stack.imgur.com/YTYKT.png" rel="nofollow">this is script</a></p>
0debug
Unpacking tuples of pixels : I've been trying to solve this textbook question for a while but am a bit stuck. Question: We have provided a module image with a procedure file2image(filename) that reads in an image stored in a file in the .png format. Import this procedure and invoke it, providing as argument the...
0debug
NOTE or WARNING from package check when README.md includes images : <p>I have a package with a <code>README.Rmd</code> that I pass to <code>rmarkdown::render()</code> producing <code>README.md</code> and a directory <code>README_files</code>, which contains images in <code>README.md</code>. This looks like the tree be...
0debug
static void usbredir_interrupt_packet(void *priv, uint32_t id, struct usb_redir_interrupt_packet_header *interrupt_packet, uint8_t *data, int data_len) { USBRedirDevice *dev = priv; uint8_t ep = interrupt_packet->endpoint; DPRINTF("interrupt-in status %d ep %02X len %d id %u\n", ...
1threat
static int load_input_picture(MpegEncContext *s, AVFrame *pic_arg){ AVFrame *pic=NULL; int64_t pts; int i; const int encoding_delay= s->max_b_frames; int direct=1; if(pic_arg){ pts= pic_arg->pts; pic_arg->display_picture_number= s->input_picture_number++; if(...
1threat
how can merge two Expression<Func<T, T> : i have two expression like this : Expression<Func<T, T> exp1 = x => new T { Id = 1 , Name = "string"} Expression<Func<T, T> exp1 = x => new T { Age = 21 } how can merge them : result : Expression<Func<T, T> exp1 = x => new T { Id = 1 , Name = "string" ...
0debug
static uint32_t nabm_readb (void *opaque, uint32_t addr) { PCIAC97LinkState *d = opaque; AC97LinkState *s = &d->ac97; AC97BusMasterRegs *r = NULL; uint32_t index = addr - s->base[1]; uint32_t val = ~0U; switch (index) { case CAS: dolog ("CAS %d\n", s->cas); val = ...
1threat
What's difference between NSPhotoLibraryAddUsageDescription and NSPhotoLibraryUsageDescription? : <p>My app get crashed today while updating on Xcode9, testing on iOS11. After adding <code>NSPhotoLibraryAddUsageDescription</code> then it works, even i already had <code>NSPhotoLibraryUsageDescription</code>.</p> <p>Ive...
0debug
static uint32_t phys_map_node_alloc(void) { unsigned i; uint32_t ret; ret = next_map.nodes_nb++; assert(ret != PHYS_MAP_NODE_NIL); assert(ret != next_map.nodes_nb_alloc); for (i = 0; i < P_L2_SIZE; ++i) { next_map.nodes[ret][i].skip = 1; next_map.nodes[ret][i].ptr = PH...
1threat
IntelliJ: activate Maven profile when running Junit tests : <p>I have declared some properties that are specific to Maven profiles. A part of my pom.xml:</p> <pre><code>&lt;profiles&gt; &lt;profile&gt; &lt;id&gt;release&lt;/id&gt; &lt;activation&gt; &lt;a...
0debug
int nbd_init(int fd, QIOChannelSocket *sioc, NBDExportInfo *info, Error **errp) { unsigned long sectors = info->size / BDRV_SECTOR_SIZE; if (info->size / BDRV_SECTOR_SIZE != sectors) { error_setg(errp, "Export size %" PRIu64 " too large for 32-bit kernel", info->siz...
1threat
Jenkins High CPU Usage Khugepageds : <p><a href="https://i.stack.imgur.com/MCvXn.png" rel="noreferrer"><img src="https://i.stack.imgur.com/MCvXn.png" alt="enter image description here"></a></p> <p>So the picture above shows a command <code>khugepageds</code> that is using <code>98</code> to <code>100</code> <code>%</c...
0debug
How to Display ajax responseText? : <p>Hi friends How do I get only the main message here is to show my j44?</p> <pre><code>error: function (xhr, status, errorThrown) { alert(xhr.responseText); } </code></pre> <p><a href="https://i.stack.imgur.com/gxTid.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.c...
0debug
List that shows the students that study more than two subjects (I need this query) : TABLES IN SQL SERVER create table Estudiante ( id int primary key not null, nombre varchar(50) ) insert into Estudiante (id, nombre) values ('1','Maria'), ('2','Juan'), ('3','Yarlin'), ('4','Ana'), ('5','Marcos'), ('...
0debug
Video don`t open on browser of cell phone : (Using WordPress 4.7.3) I have a video on my header background and it run normally on browse of desktop but when I open in browse of cell phone, the video disappear. I checked the medias queries in order to know if it is the problem, but apparently no. Site URL: http://...
0debug
REST API Security Issues : <p>I have an html5 webapp that fetches data using jquery from rest java api. I have two questions:</p> <ol> <li>How can I encrypt data on server and decrypt it locally with different key for each user. Where can I store this key in client side? Does it needed, or it is just enough to secure ...
0debug
Which Design pattern should i use to maintain pre initialized set of objects? : <p>I have some pre initialized objects of some class. These objects are heavy weight objects and each correspond to some configuration options specified by user. There will be exactly one instance corresponding to one configuration and same...
0debug
String equals in andriod studio : Was just wondering why I get "Cannot resolve symbol 'equals'" on the string.equals. Im using andriod studio. public class Transaction { String type; double amount; if(type.equals("Deposit"){ }; }
0debug
static ssize_t mcf_fec_receive(NetClientState *nc, const uint8_t *buf, size_t size) { mcf_fec_state *s = qemu_get_nic_opaque(nc); mcf_fec_bd bd; uint32_t flags = 0; uint32_t addr; uint32_t crc; uint32_t buf_addr; uint8_t *crc_ptr; unsigned int buf_len; size_t retsize; ...
1threat
Cloud connectivity for MQTT and AMQP? : <p>What is the difference between MQTT and AMQP in terms of cloud connectivity? I need to compare these two protocols in terms of connecting to the cloud and I found more evidence that AMQP works better but I am still need to find out the differences.</p>
0debug
Doesn't exit after the "exit" command : <p>I'm programming and I'm having an issue.</p> <pre><code>if exist savefile.climax ( echo It appears you have one... echo Checking your data... ( set /p name= set /p level= )&lt;savefile.climax ) else ( echo Oh man, you don't have one. echo Would you like to create it? choice /...
0debug
IOException was unhandled C# : <pre><code>static void Main(string[] args) { File.Create("Script.txt"); execute(); Console.ReadKey(); } static void execute() { if (File.Exists("Script.txt")) { string[] codex = System.IO.File.ReadAllLines("Script.txt"); ...
0debug
Automatically use secret when pulling from private registry : <p>Is it possible to globally (or at least per namespace), configure kubernetes to always use an image pull secret when connecting to a private repo? There are two use cases: </p> <ol> <li>when a user specifies a container in our private registry in a depl...
0debug
Python Iteration Homework : <p>I have 2 questions I need to ask for help with. One question I don't entirely understand so if someone could help me to that would be great. </p> <p>Question One (the one I don't entirely understand):</p> <blockquote> <p>One definition of e is</p> </blockquote> <p><a href="http://i.s...
0debug
Ruby on rails toggling favourite button using jquery and ajax comes with "rendering head :no_content Completed 204 No Content' : I am trying to create a favourite button where users will be able to use toggle button to 'favourite' a post and 'unfavourite' same depending on what they like. So far if I 'unfavourite' the ...
0debug
static void icp_set_cppr(struct icp_state *icp, int server, uint8_t cppr) { struct icp_server_state *ss = icp->ss + server; uint8_t old_cppr; uint32_t old_xisr; old_cppr = CPPR(ss); ss->xirr = (ss->xirr & ~CPPR_MASK) | (cppr << 24); if (cppr < old_cppr) { if (XISR(ss) && (cpp...
1threat
static void hevc_await_progress(HEVCContext *s, HEVCFrame *ref, const Mv *mv, int y0, int height) { int y = FFMAX(0, (mv->y >> 2) + y0 + height + 9); if (s->threads_type == FF_THREAD_FRAME ) ff_thread_await_progress(&ref->tf, y, 0); }
1threat
3 x 3 cell with large center layout with flexbox simple implementation ideas needed : <p>With CSS Grid, it's pretty easy to implement something like this <a href="https://codepen.io/anon/pen/VOLPRV" rel="nofollow noreferrer">3 x 3 cell with large center with css grid</a></p> <pre><code>.container { display: grid; ...
0debug
static int pci_pbm_init_device(SysBusDevice *dev) { APBState *s; int pci_mem_config, pci_mem_data, apb_config, pci_ioport; s = FROM_SYSBUS(APBState, dev); apb_config = cpu_register_io_memory(apb_config_read, apb_config_write, s); sysbus_init_m...
1threat
Java - SQL - Getting everything from the database and outputting it : <p>I'm trying to get everything I have in my database <em>(see below for a picture of it)</em> and output it out the the user.</p> <p><a href="http://i.stack.imgur.com/G6PmK.png" rel="nofollow">PICTURE OF HOW MY DATABASE LOOKS!</a></p> <h2>For exam...
0debug
Need a parameter based 'Ranking Algorithm' like University ranking : <p><strong>I need a ranking algorithm which is recognized and generally accepted.</strong> I am trying to develop a simple algorithm to rating Doctor for my thesis paper. My algorithm is work with different parameter/criteria like patient review, he/h...
0debug
Is it possible to restrict typescript object to contain only properties defined by its class ? : <p>Here is my code</p> <pre><code>async getAll(): Promise&lt;GetAllUserData[]&gt; { return await dbQuery(); // dbQuery returns User[] } class User { id: number; name: string; } class GetAllUserData{ id: n...
0debug
void ppc_store_sr (CPUPPCState *env, int srnum, target_ulong value) { LOG_MMU("%s: reg=%d " TARGET_FMT_lx " " TARGET_FMT_lx "\n", __func__, srnum, value, env->sr[srnum]); #if defined(TARGET_PPC64) if (env->mmu_model & POWERPC_MMU_64) { uint64_t rb = 0, rs = 0; rb |...
1threat
How to try Android development as an older programmer in 2020? : <p>Given a person who has been programming for embedded industrial systems for a few decades now. </p> <p><strong>How can I make it easy for an older programmer to try mobile development (Android)?</strong></p> <p>I’m asking because the amount of inform...
0debug
Is it possible to PASTE image into Jupyter Notebook? : <p>It is possible to include images in Jupyter notebook with various markup.</p> <p>But is it possible to AUTOMATE this? I.e. I have image in clipboard, then I just press <code>Ctrl-V</code> and Jupyter server automatically takes this image, creates file in approp...
0debug
map.end() error "iterator not dereferenceable" c++ : <pre><code>//Works cout &lt;&lt; "map[0] value is " &lt;&lt; doubleStatsMap.begin()-&gt;first&lt;&lt; endl; //gives error cout &lt;&lt; "map[last value is " &lt;&lt; doubleStatsMap.end()-&gt;first &lt;&lt; endl; </code></pre> <p>Im simply trying to get the value...
0debug
UI design - simple struct - how to implement : <p>How can I create the next (and simple) structure? Is it just a tableView? or is it require assets ? (I'm asking about the squares only, not about the text and icon at each row) <a href="https://i.stack.imgur.com/O9vKf.png" rel="nofollow noreferrer"><img src="https://i.s...
0debug
How to debug java source code when I implement a custom Detector for Lint? : <p>I am a Android developer. I have already design my own lint rules by implementing new XXXDetector and XXXIssueRegistry, here is my source code snip:</p> <p>My XXXIssueRegistry file:</p> <pre><code>public class MyIssueRegistry extends Issu...
0debug
static int av_encode(AVFormatContext **output_files, int nb_output_files, AVFormatContext **input_files, int nb_input_files, AVStreamMap *stream_maps, int nb_stream_maps) { int ret, i, j, k, n, nb_istreams = 0, nb_ostreams = 0...
1threat
static void prop_get_fdt(Object *obj, Visitor *v, const char *name, void *opaque, Error **errp) { sPAPRDRConnector *drc = SPAPR_DR_CONNECTOR(obj); Error *err = NULL; int fdt_offset_next, fdt_offset, fdt_depth; void *fdt; if (!drc->fdt) { visit_type_null(v, ...
1threat
static int dfa_probe(AVProbeData *p) { if (p->buf_size < 4 || AV_RL32(p->buf) != MKTAG('D', 'F', 'I', 'A')) return 0; return AVPROBE_SCORE_MAX; }
1threat
LDAP queries using UWP on Windows 10 IoT : <p>After several hours of searching it appears that there is no way to query a local LDAP directory (Microsoft Active Directory or otherwise) from a UWP app.</p> <p>This seems like a rather bizarre hole in the UWP offering, and so I'm hopeful that I'm just missing the obvious...
0debug
Right to Left in react-native : <p>By using this code(in below),The App has been RTL but location of Right &amp; Left changed(So things must be shown in Right are turned to Left).I did it via <a href="https://facebook.github.io/react-native/blog/2016/08/19/right-to-left-support-for-react-native-apps.html" rel="noreferr...
0debug
Why the Loaded event of UserControl has not called, while making the UserControl visible dynamically from collapsed state : <p>I am having an usercontrol.Intially i am collapsing the visibilty of that control.Once I make the control visible , the loaded event of the control is not getting called</p>
0debug
Angular 1.x/2 Hybrid, karma tests not bootstrapping ng1 app : <p>I currently have a Hybrid Angular app (2.4.9 and 1.5.0) using angular-cli. Currently, when running our application, we are able to bootstrap the 1.5 app correctly:</p> <pre class="lang-js prettyprint-override"><code>// main.ts import ... platformBrowser...
0debug
Python - merge sub lists that match certain pattern in another list? : <p>Don't know how to name such pattern, but by examples I think it is easier to explain.</p> <p>For example let say I have this list:</p> <pre><code>lst = [1, 2, 3, 5, 6, 7, 8, 10, 11, 15] </code></pre> <p>So Now I need to merge part of list that...
0debug
static int hpet_init(SysBusDevice *dev) { HPETState *s = FROM_SYSBUS(HPETState, dev); int i, iomemtype; HPETTimer *timer; if (hpet_cfg.count == UINT8_MAX) { hpet_cfg.count = 0; } if (hpet_cfg.count == 8) { fprintf(stderr, "Only 8 instances of HPET is allowe...
1threat
What is the max number of rows one should pull at once from a database? : <p>I have a process that iterates through thousands of database tables and aggregates data, and I want to set a threshold limit <code>N</code> where if the row count is larger than N my process will dump the data to a file.</p> <p>I'm wondering ...
0debug
static av_cold void alloc_temp(HYuvContext *s) { int i; if (s->bitstream_bpp<24) { for (i=0; i<3; i++) { s->temp[i]= av_malloc(s->width + 16); } } else { s->temp[0]= av_mallocz(4*s->width + 16); } }
1threat
Finding an object in array and taking values from that to present in a select list : <p>I have a string value (e.g. "Table 1") that I need to use to find a specific object in an array that looks like so:</p> <pre><code>[ { lookups: [], rows: [{data: {a: 1, b: 2}}, {data: {a: 3, b: 4}}], title: "Table 1", c...
0debug
adding firebase to flutter project and getting FAILURE: Build failed with an exception error : <p>for [this flutter library][1] as <code>barcode scanner</code> i should to adding <code>firebase</code> to project, but after doing that i get this error and i cant fix that yet</p> <blockquote> <p>Launching lib\main.dar...
0debug
How to create Cocoa GUI application with SwiftPM : <p>I want to split my codebase into a library which I want to upload to github and an GUI application. I hope that using recently introduced SwiftPM is a good idea.</p> <p>But all examples I've been able to find show creating a console application with <code>swift pac...
0debug
I have installed extension for sorting product by quantity, it show above mention error? : <p>Fatal error: Uncaught Error: Call to a member function setStoreId() on boolean in /home/zohaibs4/public_html/includes/src/__default.php:7032 </p>
0debug
My PWA web app keep showing old version after a new release on Safari (but works fine on chrome)? : <p>I added PWA and service worker to my existing web app based on Angular 5. Everything looks fine on first release. However, when I try to release updates, something strange is happening.</p> <p>On PC using Chrome, I d...
0debug
How to have text in center and image around it as shown in screenshot? (Image attached) : <p>I am converting an Illustrator design into HTML and CSS using Bootstrap framework. I am stuck on the part of design shown below: </p> <p><a href="https://i.stack.imgur.com/GlHjD.png" rel="nofollow noreferrer"><img src="https:/...
0debug
JavaScript Mini-Max Sum - Returns 0 : <p>I'm trying to resolve the Mini-Max Sum Challenge from HackerRank. Why my code returns 0? <a href="https://www.hackerrank.com/challenges/mini-max-sum/problem" rel="nofollow noreferrer">https://www.hackerrank.com/challenges/mini-max-sum/problem</a></p> <p>Been trying different co...
0debug
onFocus bubble in React : <p>jsfiddle : <a href="https://jsfiddle.net/leiming/5e6rtgwd/" rel="noreferrer">https://jsfiddle.net/leiming/5e6rtgwd/</a></p> <p><div class="snippet" data-lang="js" data-hide="false"> <div class="snippet-code"> <pre class="snippet-code-js lang-js prettyprint-override"><code>class Sample ex...
0debug
static uint32_t arm_ldl_ptw(CPUState *cs, hwaddr addr, bool is_secure, ARMMMUIdx mmu_idx, ARMMMUFaultInfo *fi) { ARMCPU *cpu = ARM_CPU(cs); CPUARMState *env = &cpu->env; MemTxAttrs attrs = {}; AddressSpace *as; attrs.secure = is_secure; as = arm_addressspace...
1threat
c; how to write a program that makes the user input a lot of strings as much and count the occurences? : I need to write a program that makes the user input a string, then the program asks the user to continue to input more strings or not. After that, the program should count all the occurrences of the words in all th...
0debug
Using Android Studio, how can I create a value which will increase its value by 1 every time a button is clicked? : <p>I am currently working on an app for a project in University and am seeking to find out how to increase a variable value by 1 when a button is clicked. The app I am building is a sports app, and my ide...
0debug
String equation seperation : String Str = new String("(300+23)*(43-21)/(84+7)"); System.out.println("Return Value :" ); String[] a=Str.split(Str); String a="(" String b="300" String c="+" I want to convert this single stri...
0debug
static void test_validate_fail_list(TestInputVisitorData *data, const void *unused) { UserDefOneList *head = NULL; Error *err = NULL; Visitor *v; v = validate_test_init(data, "[ { 'string': 'string0', 'integer': 42 }, { 'string': 'string1', 'integer': 43 }, {...
1threat
static void kvm_arm_machine_init_done(Notifier *notifier, void *data) { KVMDevice *kd, *tkd; memory_listener_unregister(&devlistener); QSLIST_FOREACH_SAFE(kd, &kvm_devices_head, entries, tkd) { if (kd->kda.addr != -1) { if (kvm_vm_ioctl(kvm_state, KVM_ARM_SET_DEVICE_ADDR, ...
1threat
Difference between hyperledger composer and hyperledger fabric? : <p>I am java developer and new to hyperledger. I am interested in learning it and need to know where to start . fabric vs composer?</p>
0debug
static int usbredir_handle_iso_data(USBRedirDevice *dev, USBPacket *p, uint8_t ep) { int status, len; if (!dev->endpoint[EP2I(ep)].iso_started && !dev->endpoint[EP2I(ep)].iso_error) { struct usb_redir_start_iso_stream_header start_iso = { ...
1threat
Syntax error in MySQL INSERT INTO statement : <p>there is some problem with my code. Everytime I try to insert something into the database, I get the syntax error.</p> <p>Here is my database structure:</p> <pre class="lang-sql prettyprint-override"><code>CREATE TABLE `notes` ( `id` int(12) NOT NULL, `type` varcha...
0debug
How can I use tensorboard with tf.estimator.Estimator : <p>I am considering to move my code base to <a href="https://www.tensorflow.org/api_docs/python/tf/estimator/Estimator" rel="noreferrer">tf.estimator.Estimator</a>, but I cannot find an example on how to use it in combination with tensorboard summaries.</p> <p>MW...
0debug
int do_subchannel_work_passthrough(SubchDev *sch) { int ret; SCSW *s = &sch->curr_status.scsw; if (s->ctrl & SCSW_FCTL_CLEAR_FUNC) { sch_handle_clear_func(sch); ret = 0; } else if (s->ctrl & SCSW_FCTL_HALT_FUNC) { sch_handle_halt_func(sch); ...
1threat
easy_install pip fails on MAC OSX : <p>I am running OSX Sierra 10.12.6 on a macbook pro</p> <p>There's known bug in pip 10.0.0b1 that causes a Trap: 5 when you try to install anything. This also prevents you from updating pip itself to 10.0.0b2, which supposedly fixes this bug.</p> <p>So - I uninstalled pip, thinkin...
0debug
static void eth_receive(void *opaque, const uint8_t *buf, size_t size) { mv88w8618_eth_state *s = opaque; uint32_t desc_addr; mv88w8618_rx_desc desc; int i; for (i = 0; i < 4; i++) { desc_addr = s->cur_rx[i]; if (!desc_addr) continue; do { ...
1threat
void commit_start(const char *job_id, BlockDriverState *bs, BlockDriverState *base, BlockDriverState *top, int64_t speed, BlockdevOnError on_error, const char *backing_file_str, Error **errp) { CommitBlockJob *s; BlockReopenQueue *reopen_queue = NULL; ...
1threat
Array of objects initialization - Java Android : I want to create an array of objects as mentioned in this answer: https://stackoverflow.com/questions/5364278/creating-an-array-of-objects-in-java i.e initialize one at a time like A[] a = new A[4]; a[0] = new A(); My class definition: ...
0debug
Transfer content of one array to another, removing duplicates : <p>I have an array of about 1000 words. I want to transfer them to another array while removing any duplicates. How can I do this in C# ? </p>
0debug
Incrementing Click Redux Function in an array : <p>I am working with some svg elements and i have built an increment button.</p> <p>The increment button takes the the <code>path d</code> values converts it into an array and sums <code>5</code> from the third element of the array. If the element is <code>'L'</code> or ...
0debug
Why is correct id is not inserting into table : I want the following code to insert the cars id in customer_payment table but it only select 477 id. I don't know why. As it can be seen in image bellow only product_id 477 is inserted not any other if I select 500 it still inserts 477. Please help me on this help will be...
0debug
static struct dirent *local_readdir(FsContext *ctx, V9fsFidOpenState *fs) { struct dirent *entry; again: entry = readdir(fs->dir.stream); if (!entry) { return NULL; } if (ctx->export_flags & V9FS_SM_MAPPED) { entry->d_type = DT_UNKNOWN; } else if (ctx->export_flags ...
1threat
Indexoutboundexception error for arraylist : Can someone help me explain why this piece of code is throwing an indexoutbound error public static Hull merging(Hull HullA, Hull HullB) { Hull finalHull = new Hull(); int i=0; int j=0; if (HullA.list.get(i) >= HullB.list.get(j)) { ...
0debug
SwiftUI: Forcing an Update : <p>Normally, we're restricted from discussing Apple prerelease stuff, but I've already seen plenty of SwiftUI discussions, so I suspect that it's OK; just this once.</p> <p>I am in the process of driving into the weeds on one of the tutorials (I do that).</p> <p>I am adding a pair of butt...
0debug
Pygame: Rect that is different sized than image : this is my first post on here just created my first account. :D I am a beginner coder and learned python just 2 weeks ago, but I wanted to try something new and found [this tutorial](https://www.youtube.com/watch?v=VO8rTszcW4s&list=PLsk-HSGFjnaH5yghzu7PcOzm9NhsW0Urw&in...
0debug
static int kvm_sclp_service_call(S390CPU *cpu, struct kvm_run *run, uint16_t ipbh0) { CPUS390XState *env = &cpu->env; uint64_t sccb; uint32_t code; int r = 0; cpu_synchronize_state(CPU(cpu)); if (env->psw.mask & PSW_MASK_PSTATE) { enter_pgmchec...
1threat
Is it safe to compile againts later JDK? : <p>I have some big projects running on Java 6. But I plan to start building them in Java 8 since a lot of build tools have moved away from Java 6.</p> <p>Is it safe for me to simply compile them with Java 8 and then deploy them in a web container running Java 8? If not, what ...
0debug
Duplicate 'Content' items were included. The .NET SDK includes 'Content' items from your project directory by default : <p>Whenever I add a javascript or css file to my asp.net core project and I execute <code>dotnet run</code> in my bash terminal, I get the following error:</p> <blockquote> <p>/usr/share/dotnet/sdk...
0debug
Scanning integers in C in xCode : so I am trying to scan some integers in C (so taking in the user's first and last name, departure and arrival locations) but I am getting this error that the type of declaration I've made is inconsistent. I'm a little new to C still so bear with me as this may be a trivial thing. Thank...
0debug
Cross Domain Image upload Angular+laravel : <p>I have been struggling with image upload on server. I am using <a href="https://github.com/danialfarid/ng-file-upload">ngFileUpload</a> on front end. But I always get </p> <p>"Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin...
0debug
static int theora_decode_header(AVCodecContext *avctx, GetBitContext *gb) { Vp3DecodeContext *s = avctx->priv_data; int visible_width, visible_height, colorspace; int offset_x = 0, offset_y = 0; AVRational fps, aspect; s->theora = get_bits_long(gb, 24); av_log(avctx, AV_LOG_DEBUG, "Theo...
1threat
static void dxva2_uninit(AVCodecContext *s) { InputStream *ist = s->opaque; DXVA2Context *ctx = ist->hwaccel_ctx; ist->hwaccel_uninit = NULL; ist->hwaccel_get_buffer = NULL; ist->hwaccel_retrieve_data = NULL; if (ctx->decoder_service) IDirectXVideoDecoderService_Re...
1threat
int spapr_tce_dma_read(VIOsPAPRDevice *dev, uint64_t taddr, void *buf, uint32_t size) { #ifdef DEBUG_TCE fprintf(stderr, "spapr_tce_dma_write taddr=0x%llx size=0x%x\n", (unsigned long long)taddr, size); #endif if (dev->flags & VIO_PAPR_FLAG_DMA_BYPASS) { ...
1threat
What is the difference between `declare namespace` and `declare module` : <p>After reading <a href="https://www.typescriptlang.org/docs/handbook/namespaces-and-modules.html" rel="noreferrer">this manual</a> and this quote:</p> <blockquote> <p>It’s important to note that in TypeScript 1.5, the nomenclature has chan...
0debug