problem
stringlengths
26
131k
labels
class label
2 classes
ASP.NET Core 2.0 Could not load file or assembly System.ServiceModel : <p>I am working on porting an "ASP.NET Core Web Application" that was compiling under the .NET Framework 4.6.1 (i.e. full framework) over to compiling against .NET Core 2.0. I have some dependencies which still require the full framework but with ....
0debug
What is the difference between C.UTF-8 and en_US.UTF-8 locales? : <p>I'm migrating a python application from an ubuntu server with locale en_US.UTF-8 to a new debian server which comes with C.UTF-8 already set by default. I'm trying to understand if there would be any impact but couldn't find good resources on the inte...
0debug
What is the recommended way to update project.pbxproj file for the app while upgrading react-native version : <p>I am using <a href="https://github.com/ncuillery/rn-diff" rel="noreferrer">rn-diff</a> to upgrade <code>react-native</code> version for my app. Sometimes, the project.pbxproj is updated to contain some new d...
0debug
static void dec10_reg_scc(DisasContext *dc) { int cond = dc->dst; LOG_DIS("s%s $r%u\n", cc_name(cond), dc->src); if (cond != CC_A) { int l1; gen_tst_cc (dc, cpu_R[dc->src], cond); l1 = gen_new_label(); tcg_gen_brcondi_tl(TCG_COND_EQ, cpu_R[dc->src], 0, l1);...
1threat
static int get_riff(AVFormatContext *s, AVIOContext *pb) { AVIContext *avi = s->priv_data; char header[8]; int i; avio_read(pb, header, 4); avi->riff_end = avio_rl32(pb); avi->riff_end += avio_tell(pb); avio_read(pb, header + 4, 4); for (i = 0; avi_headers[i][0]; i+...
1threat
Python min value in nested lists : <pre><code>a_list = [['2', 0.5], ['2', 0.5], ['2', 1.0], ['1', 2.0], ['1', 3.5], ['1', 2.5]] b_list = {'1', '2'} </code></pre> <p>What is the most pythonic way of calculating the min value from a_list for each value in b_list?</p>
0debug
Uniqueness with a combination of numbers regardless of sequence : <p>I am working on a feature that requires me to arrive at a unique string. There are 2 attributes for every person in the data model - Company Id and Person Id. The combination of the Co and Person Id will always be unique. When 1 person initiates a con...
0debug
How do I make a program know where it is? : <p>I want to add a picture to my program but you need the directory for the picture for that (by my understanding). How do I make the program know where it self is and find the picture that I want to add. Note I can't set the directory to where it is on my computer as I want ...
0debug
How do I call activity method from Adaptor class : I have three Class mainActivity.java public class mainactivity extends AppCompatActivity{ @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layou...
0debug
Do importable libraries exist for common mathematical operations (e.g. min, max and mean) in C or C++? : <p>I'm a Python programmer starting to learn C / C++. One issue I'm finding, however, is that the C languages seem to lack a lot of "basic" mathematical operations. For example, even finding the min, max or mean of ...
0debug
START_TEST(qdict_iterapi_test) { int count; const QDictEntry *ent; fail_unless(qdict_first(tests_dict) == NULL); qdict_put(tests_dict, "key1", qint_from_int(1)); qdict_put(tests_dict, "key2", qint_from_int(2)); qdict_put(tests_dict, "key3", qint_from_int(3)); count = 0; fo...
1threat
static int run_test(AVCodec *enc, AVCodec *dec, AVCodecContext *enc_ctx, AVCodecContext *dec_ctx) { AVPacket enc_pkt; AVFrame *in_frame, *out_frame; uint8_t *raw_in = NULL, *raw_out = NULL; int in_offset = 0, out_offset = 0; int frame_data_size = 0; int result = 0; ...
1threat
Recursion why is return necessary? : Recursion why is "return" necessary? DO I NEED "RETURN X" STATEMENT HERE?? BECAUSE Result is the same thing whether with or without. package RecursionTry1; public class RecursionTry { public int run(int x) { if(x<5) { System...
0debug
my html form doesn't work with my php code : if i make insert_teacher('bla bla','bla bla','dqsd') in php file , but when i want to make it with html form it doesn't show me anything, and nothing inserted in my db ==== if i make insert_teacher('bla bla','bla bla','dqsd') in php file , but when i want to make it with h...
0debug
static inline void RENAME(bgr24ToUV)(uint8_t *dstU, uint8_t *dstV, uint8_t *src1, uint8_t *src2, long width) { #ifdef HAVE_MMX asm volatile( "mov %4, %%"REG_a" \n\t" "movq "MANGLE(w1111)", %%mm5 \n\t" "movq "MANGLE(bgr2UCoeff)", %%mm6 \n\t" "pxor %%mm7, %%mm7 \n\t" "lea (%%"REG_a", %%"REG_a", 2),...
1threat
Open file on IntelliJ from iTerm 2 : <p>I have output in my iTerm like:</p> <pre><code> File project/path/path/file.py:56:54 extra text information </code></pre> <p>How I can open this file in IntelliJ with a single click?</p>
0debug
How can I read the Ids on of Div elemnt for LI tag : I want the Ids of all the li elemnt under div text. <div id="editSortable"> <ul class="sortable-list ui-sortable"> <li id="id1">Test 1</li> <li id="id2">Test 2</li> <li id="id3">Test 3</li> </ul> </div> I need ou...
0debug
Pandas - find first non-null value in column : <p>If I have a series that has either NULL or some non-null value. How can I find the 1st row where the value is not NULL so I can report back the datatype to the user. If the value is non-null all values are the same datatype in that series.</p> <p>Thanks</p>
0debug
static Visitor *validate_test_init_internal(TestInputVisitorData *data, const char *json_string, va_list *ap) { Visitor *v; data->obj = qobject_from_jsonv(json_string, ap); g_assert(data->obj); data->qiv = qmp_input_...
1threat
WPF Programmatically Enable TextBox Scrolling/Panning for Tablets : <p>I am working with a WPF application that will be used on Windows tablets. The issue I am having is that I cannot scroll through a large multi-line TextBox on a tablet by pressing and dragging the content. However, it still scrolls on a desktop with ...
0debug
Flutter & Firebase: Compression before upload image : <p>I want to send photo selected by user in my app to Firebase Storage. I have a simple class with property <code>_imageFile</code> which is set like this:</p> <pre><code>File _imageFile; _getImage() async { var fileName = await ImagePicker.pickImage(); se...
0debug
static int mov_read_mvhd(MOVContext *c, AVIOContext *pb, MOVAtom atom) { int i; int64_t creation_time; int version = avio_r8(pb); avio_rb24(pb); if (version == 1) { creation_time = avio_rb64(pb); avio_rb64(pb); } else { creation_time = avio_rb32(pb); ...
1threat
How to set unselected Text Color for TabLayout.Tab - Android : <p>How do you set text-color for a tab that's not selected? I know you can set the text-color for the TabLayout by doing: <strong>setTabTextColors</strong></p>
0debug
Given a string of letters, how can I count the occurrences of every letter? : <p>Given a string of letters, I'm looking to create an object containing key value pairs with the letter as the key and the number of occurrences within the string as the value. </p> <p>So given "aabccc", the function should return: { a: ...
0debug
c# Login form with User Authentication with sql database : I am new to SQL and C#. I am working on a login form that checks if the user is an admin or a basic user. In my SQL I created a table that stores username, password, and role (admin or basic user). The saved data are the following: For admin: username = admin...
0debug
Function sum of square python : Im trying to code the sum of squares in python and i'm pretty new to this this is what i have for now, n=int(input("n=")) def sumsquare(n): sum=0 i=0 while(n<=i): sum= sum + i**2 Basically what i'm trying to do is to make t...
0debug
static int decode_ext_header(Wmv2Context *w){ MpegEncContext * const s= &w->s; GetBitContext gb; int fps; int code; if(s->avctx->extradata_size<4) return -1; init_get_bits(&gb, s->avctx->extradata, s->avctx->extradata_size*8); fps = get_bits(&gb, 5); s->bit_r...
1threat
static int skip_check(MpegEncContext *s, Picture *p, Picture *ref) { int x, y, plane; int score = 0; int64_t score64 = 0; for (plane = 0; plane < 3; plane++) { const int stride = p->f.linesize[plane]; const int bw = plane ? 1 : 2; for (y = 0; y < s->mb_height * bw; y++)...
1threat
static void dec_sr(DisasContext *dc) { if (dc->format == OP_FMT_RI) { LOG_DIS("sri r%d, r%d, %d\n", dc->r1, dc->r0, dc->imm5); } else { LOG_DIS("sr r%d, r%d, r%d\n", dc->r2, dc->r0, dc->r1); } if (dc->format == OP_FMT_RI) { if (!(dc->features & LM32_FEATURE_SHIF...
1threat
Java DateFormat for UTC : <p>I have a DateFormat like</p> <pre><code>DateFormat format = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSS"); </code></pre> <p>I have a date like this:</p> <pre><code>2017-02-23T11:00:04.072625 </code></pre> <p>This "date" is a UTC date (Z is null). This parses fine. However, it seems ...
0debug
static kbd_layout_t *parse_keyboard_layout(const name2keysym_t *table, const char *language, kbd_layout_t * k) { FILE *f; char * filename; char line[1024]; int len; filename = qemu_find_file(QEMU_FILE_TYPE_KEYMAP, language); if (!k) k = g_malloc0(sizeof(kbd_layout_...
1threat
static int vp3_decode_init(AVCodecContext *avctx) { Vp3DecodeContext *s = avctx->priv_data; int i; s->avctx = avctx; s->width = avctx->width; s->height = avctx->height; avctx->pix_fmt = PIX_FMT_YUV420P; avctx->has_b_frames = 0; dsputil_init(&s->dsp, avctx); s->q...
1threat
static int url_alloc_for_protocol(URLContext **puc, struct URLProtocol *up, const char *filename, int flags, const AVIOInterruptCB *int_cb) { URLContext *uc; int err; #if CONFIG_NETWORK if (up->flags & URL_PROTOCOL_FLAG_NETWORK && ...
1threat
int bdrv_open_backing_file(BlockDriverState *bs) { char backing_filename[PATH_MAX]; int back_flags, ret; BlockDriver *back_drv = NULL; if (bs->backing_hd != NULL) { return 0; } bs->open_flags &= ~BDRV_O_NO_BACKING; if (bs->backing_file[0] == '\0') { return 0; ...
1threat
Get status bar height dynamically from XML : <p>I need to optimize my Android app to look good on phones with a notch, like the Essential Phone.</p> <p>This phones have different status bar heights than the standard 25dp value, so you can't hardcode that value.</p> <p>The Android P developer preview released yesterda...
0debug
Prepared statement does not match bind variables even tho it do? : As far as i can tell i select 6 columns from the table, and i bind 6 variables so why does it tell me that it does not match? This is for a rating script where people can vote cars This script works with the Insert/Select/Union but i noticed that ...
0debug
How to get control info of Notepad write by python language : I have code bellow copy from website : https://pywinauto.github.io/ : ``` from pywinauto.application import Application app = Application().start("notepad.exe") app.UntitledNotepad.menu_select("Help->About Notepad") app.AboutNotepad.OK.click() app.Unti...
0debug
static inline void tcg_out_sety(TCGContext *s, tcg_target_long val) { if (val == 0 || val == -1) tcg_out32(s, WRY | INSN_IMM13(val)); else fprintf(stderr, "unimplemented sety %ld\n", (long)val); }
1threat
write_f(int argc, char **argv) { struct timeval t1, t2; int Cflag = 0, pflag = 0, qflag = 0, bflag = 0; int c, cnt; char *buf; int64_t offset; int count; int total = 0; int pattern = 0xcd; while ((c = getopt(argc, argv, "bCpP:q")) != EOF) { switch (c) { case 'b': bflag = ...
1threat
Xamp is not start Apache, Mysql is working fine : I was working on my PHP project yesterday and it was working fine, but today morning after the restart xamp is not starting Apache for some reason. Can someone suggest how can I work around it: Error: Apache shutdown unexpectedly. 1:17:04 PM [Apache] This ...
0debug
alert('Hello ' + user_input);
1threat
The project system has encountered an error When trying to load project : <p>In Visual Studio 2017 v15.7.1 I am getting the following error window when trying to load one of my projects:</p> <p><a href="https://i.stack.imgur.com/jl3rY.png" rel="noreferrer"><img src="https://i.stack.imgur.com/jl3rY.png" alt="VS error w...
0debug
void aio_set_fd_handler(AioContext *ctx, int fd, IOHandler *io_read, IOHandler *io_write, AioFlushHandler *io_flush, void *opaque) { AioHandler *node; node = find_aio_handler(ctx, fd...
1threat
static BlockDriverAIOCB *curl_aio_readv(BlockDriverState *bs, int64_t sector_num, QEMUIOVector *qiov, int nb_sectors, BlockDriverCompletionFunc *cb, void *opaque) { CURLAIOCB *acb; acb = qemu_aio_get(&curl_aiocb_info, bs, cb, opaque); acb->qiov = qiov; acb->sector_num = sector...
1threat
Replace in angularJS : This is string: 1<div>2</div><div>3</div><div>4</div> After replace var descriptionVal = desc.replace('<div>', '-').replace('</div>', '-'); only replace first div! 1-2</div><div>3</div><div>4</div> how replace all div?
0debug
R - here() function, what's a .here file? : <p>I'm struggling to find the answer to this very basic question and to make the here() function work (from the here package). I'd be glad if someone could help me with that.</p> <p>What's a file .here mentionned in this <a href="https://github.com/jennybc/here_here" rel="no...
0debug
Python- In nested function, I want to call inner function. PFB details : ** I have a class called IrisData. I have defined One function in that as description. * description has multiple sub-function inside which I want to access. * I want my function to be like 1. It should return every function defined within ...
0debug
static void scsi_dma_complete_noio(void *opaque, int ret) { SCSIDiskReq *r = (SCSIDiskReq *)opaque; SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, r->req.dev); if (r->req.aiocb != NULL) { r->req.aiocb = NULL; block_acct_done(bdrv_get_stats(s->qdev.conf.bs), &r->acct); } ...
1threat
static void test_tco_second_timeout_shutdown(void) { TestData td; const uint16_t ticks = TCO_SECS_TO_TICKS(128); QDict *ad; td.args = "-watchdog-action shutdown"; td.noreboot = false; test_init(&td); stop_tco(&td); clear_tco_status(&td); reset_on_second_timeout(true); ...
1threat
Max arc4random() value : For some reason I'm not able to find any sort of official doc telling me what the maximum range is for arc4random. I've seen in some non-authoritarian sources that it's 2^32 - 1, a little over 4 billion. Can anyone confirm this? If so, can you link to an official doc showing this number som...
0debug
(php,mysqli,phpmyadmin) Can I enter my data this way? : Please, I cant find the mistake but it doesn't work. Always shows "error de envio"(sending error) ...or die("error de envio"); [Myphpadmin data][1] <- Link img. My php code: $link =mysqli_connect("localhost","my_user","my_password",...
0debug
static inline int bidir_refine(MpegEncContext * s, int mb_x, int mb_y) { MotionEstContext * const c= &s->me; const int mot_stride = s->mb_stride; const int xy = mb_y *mot_stride + mb_x; int fbmin; int pred_fx= s->b_bidir_forw_mv_table[xy-1][0]; int pred_fy= s->b_bidir_forw_mv_table[xy-1][...
1threat
How do I use transaction with oracle SQL? : <p>I am trying to use transaction blocks on a SQL-Console with an Oracle DB. I'm used to use transaxction blocks in PostgreSQL like</p> <pre><code>BEGIN; &lt;simple sql statement&gt; END; </code></pre> <p>but in oracle it seems that this is not possible. I'm always getting ...
0debug
MySQL fails on: mysql "ERROR 1524 (HY000): Plugin 'auth_socket' is not loaded" : <p>My local environment is:</p> <ul> <li>fresh Ubuntu 16.04</li> <li>with PHP 7</li> <li><p>with installed MySQL 5.7</p> <pre><code>sudo apt-get install mysql-common mysql-server </code></pre></li> </ul> <hr> <p>When I tried to login t...
0debug
How do I get my Eclipse-Maven project to automatically update its classpath when I change a dependency in my pom.xml file? : <p>I’m using Eclipse Mars with Maven (v 3.3). When I update a dependency in my pom (change the version), my Eclipse-Maven project doesn’t pick it up, even when I right click my project, and sele...
0debug
How do I save the output of this code into a file? (PHP) : <p>This code that loops through some mysql tables:</p> <pre><code>foreach($tables as $table) { echo "&lt;h2&gt;" . $table[0] . "&lt;/h2&gt;"; $query = "DESCRIBE " . $table[0]; $result = $mysqli-&gt;query($query); $columns = $result-&gt;fetch_all(); foreach($...
0debug
Heroku - No web process running : <p>I made a twitter bot using tweepy in Python and tried deploying it using Heroku. The Bot just tweets after certain intervals. After deploying it, the Python program just doesn't run and Heroku log shows the following error : </p> <pre><code>at=error code=H14 desc="No web process...
0debug
Can't reference system.drawing.dll plz help me : When I create the code that continuously executes the function, it works normally for 4 minutes, but the error "Can not reference system.drawing.dll" appears and it can not be executed. I've tried Googleing a couple of times to solve it, but I have not had the same ex...
0debug
How to properly include a library from node_modules into your project? : <p>the question can maybe be stupid but did not find the answer till now.<br> I'm trying to include a library from <strong>node_modules</strong>, from what I've learn since yesterday we should include like that with <strong>asset</strong>:</p> <p...
0debug
SQLite Error 14: 'unable to open database file' with EF Core code first : <p>I am getting an</p> <p>SQLite Error 14: 'unable to open database file'</p> <p>with EF Core code first, no idea why. I worked fine the first time, the database file got created in c:\users\username\AppData\Local\Packages\PackageId\LocalState....
0debug
How to programming Xor calculator hex base 16 in java? : How to programming Xor calculator java for hexadecimal base 16 in java like in the screenshot shown below. The first input is the key and thee second input is the string, the third one is the output. Actually I tried a lot of scripts and I googled the issue but t...
0debug
AddfdInfo *qmp_add_fd(bool has_fdset_id, int64_t fdset_id, bool has_opaque, const char *opaque, Error **errp) { int fd; Monitor *mon = cur_mon; MonFdset *mon_fdset = NULL; MonFdsetFd *mon_fdset_fd; AddfdInfo *fdinfo; fd = qemu_chr_fe_get_msgfd(mon->chr); if (...
1threat
static void dca_init_vlcs(void) { static int vlcs_inited = 0; int i, j; if (vlcs_inited) return; dca_bitalloc_index.offset = 1; dca_bitalloc_index.wrap = 2; for (i = 0; i < 5; i++) init_vlc(&dca_bitalloc_index.vlc[i], bitalloc_12_vlc_bits[i], 12, bi...
1threat
how to read nextline of textfile in java : import java.io.*; import java.util.*; public class stringstore { public static void main(String[] args) { File file = new File("C:\\a.txt"); try { String strIP=""; Scanner sc = new Scanner(file); while(sc.hasNext())...
0debug
Logistic regression R-predict : No of rows error : <p>I am trying to use the predict function to predict the values of a logistic regression and I am getting the incorrect number of rows. This question has already been asked <a href="https://stackoverflow.com/questions/40978688/r-warning-newdata-had-15-rows-but-variab...
0debug
static int mxf_write_footer(AVFormatContext *s) { MXFContext *mxf = s->priv_data; AVIOContext *pb = s->pb; int err = 0; mxf->duration = mxf->last_indexed_edit_unit + mxf->edit_units_count; mxf_write_klv_fill(s); mxf->footer_partition_offset = avio_tell(pb); if (mxf->edit_unit_byte_count && s...
1threat
are sas procedures source code available : <p>I understand SAS is proprietary software. I am wondering if the procedures that ships with it also ship without source code. For example, I see a PROC ANOVA in the user guide; is there anyway to look at the source code to see exactly how this procedure computes anovas?</p> ...
0debug
TextBox Value Disappears VB6 : I my case I am having two form Form 1 and Form 2. Form 1 having two Buttons and Form 2 is having one textbox. On Button 1 Click event I am writing "My Text" in my Form 2 TextBox and on button 2 I am showing Form 2. What is happening is When I close my Form 2 using close [X] button and ...
0debug
static void xhci_kick_ep(XHCIState *xhci, unsigned int slotid, unsigned int epid, unsigned int streamid) { XHCIStreamContext *stctx; XHCIEPContext *epctx; XHCIRing *ring; USBEndpoint *ep = NULL; uint64_t mfindex; int length; int i; trace_usb_xhci_ep_k...
1threat
What's Object Oriented Programming? : <p>I'm pretty new to programming with Object Oriented Programming Languages. So please how do you explain the concept of object oriented programming to a kid?</p>
0debug
static int encode_picture(MpegEncContext *s, int picture_number) { int i; int bits; s->picture_number = picture_number; s->me.mb_var_sum_temp = s->me.mc_mb_var_sum_temp = 0; if (s->codec_id == CODEC_ID_MPEG1VIDEO || s->codec_id == CODEC_ID_MPEG2VIDEO || (s->h263...
1threat
how to use radio buttons in xamarin forms : <p>Creating a Registration page i need to get following data from user. -First Name -Last Name -Username -Email -Password -Date of Birth -<strong>Gender</strong> -<strong>User Role</strong></p> <p>For Last to parameters I am unable to find how to use radio buttons in xamarin...
0debug
Suppress SQL Queries logging in Entity Framework core : <p>I have a console .net core app that uses entity framework core. The app uses logging framework to write to file and console:</p> <pre><code> serviceProvider = new ServiceCollection() .AddLogging() .AddDbContext&lt;DataStoreContext&gt;(options =...
0debug
Vuex 2.0 Dispatch versus Commit : <p>Can someone explain when you would use a dispatch versus a commit?</p> <p>I understand a commit triggers mutation, and a dispatch triggers an action.</p> <p>However, isn't a dispatch also a type of action? </p>
0debug
Take right selected value from select options from multiple select tables generated thro for loop : I've tried to get solutions from Google and earlier asked questions but questions and answers relate to only one select having multiple options. To clarify more, when I generate code thro for loop to create multiple sel...
0debug
Return to readline version 6.x in Homebrew to fix Postgresql? : <p>I'm no Homebrew expert but I think it has "upgraded" me from readline version 6.x to 7.0 sometime after <a href="http://ftp.gnu.org/gnu/readline/">9/15/16</a>:</p> <pre><code>eat@eric-macbook:Homebrew$ brew info readline readline: stable 7.0 (bottled) ...
0debug
C++, Sort One Vector Based On Another One : <p>The best example I've got is that I want to sort Names based on their Score.</p> <pre><code>vector &lt;string&gt; Names {"Karl", "Martin", "Paul", "Jennie"}; vector &lt;int&gt; Score{45, 5, 14, 24}; </code></pre> <p>So if I sort the score to {5, 14, 24, 45}, the names sh...
0debug
Haskell: app build troubleshooting : How am I supposed to go about troubleshooting if an imported library won't build? $ stack new any-tool simple $ cd any-tool/ $ stack build The boilerplate builds. Adding `import Turtle` to `Main.hs`: {-# LANGUAGE OverloadedStrings #-} module Main w...
0debug
static void get_slice_data(ProresContext *ctx, const uint16_t *src, int linesize, int x, int y, int w, int h, DCTELEM *blocks, uint16_t *emu_buf, int mbs_per_slice, int blocks_per_mb, int is_chroma) { const uint16_t *esrc; co...
1threat
Middle function on pthon : Write a function middle which takes a list L as its argument, and returns the item in the middle position of L, when L has an odd length. Otherwise, middle should return 999999. For example, calling middle([8, 0, 100, 12, 1]) should return 100.
0debug
sqlzoo:what's wrong with the answer for 'The award for the first time (Economics) who is the winner?' : here is my answer,but the result shows wrong,i want to know why and the correct answer!! SELECT winner FROM nobel WHERE subject='Economics' AND yr IN (SELECT min('yr') FROM nobel WHERE subject='Economics');
0debug
Can anyone help me? It's always showing "-----WELCOME----- ENTER TOTAL PERSON COUNT: Exception in thread "main" java.util.InputMismatchException " : import java.util.Scanner; public class Main { public static void main(String[] args) { System.out.println("-----WELCOME-----"); Scanner input ...
0debug
static int block_save_setup(QEMUFile *f, void *opaque) { int ret; DPRINTF("Enter save live setup submitted %d transferred %d\n", block_mig_state.submitted, block_mig_state.transferred); qemu_mutex_lock_iothread(); init_blk_migration(f); set_dirty_tracking(); qemu_...
1threat
Setting up stylesheet for mobile in wordpress : I use WP 4.9.2 and Leto theme from aThemes. The site that I built on it looks great on bigger screens, but is really screwed up in mobile. I checked the stylesheet - the problem is related to the @media queries. I just don't seem to be setting in the right way ( the css)....
0debug
Branching solution : <p>I'm working with visual studio and TFS and currently exploring the idea of branching and merging. To give a general overview of how I'm organizing one solution:</p> <pre><code>MySolution - MyProject 1 MyProject1TestBranch - MyProject 2 - MyProject 3 </code></pre> <p>I have been playing ...
0debug
How to check for command line arguments in GO : <p>I am writing a program that makes a simple web server in GO. The program should check for a port passed in the command line. If no port is given, I want to panic and exit the program. I thought this should work:</p> <pre><code>if len(os.Args &lt; 1) { panic("No po...
0debug
AES 256 from Java : I'm trying to reproduce an encryption/decryption done in `Java` to a `Ruby` one. `Java` code comes from [here][1] I have a problem with the decryption. Here is my ruby code: key = Digest::SHA256.digest(key) aes = OpenSSL::Cipher.new('AES-256-CBC') aes.decrypt aes.key = D...
0debug
How is it possible to have two variables with same names - one is global and another one is local? : <p>I understand that two variable can be declared of same name in two distinct function. how can we declare a variable within a function which is already declared in the global scope?</p>
0debug
void cpu_dump_state (CPUState *env, FILE *f, fprintf_function cpu_fprintf, int flags) { #define RGPL 4 #define RFPL 4 int i; cpu_fprintf(f, "NIP " TARGET_FMT_lx " LR " TARGET_FMT_lx " CTR " TARGET_FMT_lx " XER " TARGET_FMT_lx "\n", env->nip, e...
1threat
VS used to open browser in new tab, now opens new browser : <p>I've been updating to the latest version of Visual Studio Preview and I think a setting has been changed.</p> <p>When I start debugging an ASP.NET web app in Visual Studio 2017 15.7.0 Preview 4, VS opens a new browser.</p> <p>I've had a similar issue befo...
0debug
concat ' ands string : At mssql I want concat ' and 1 string Example: Concat ('My name',''') Ouput : My name' pls me, Thanks
0debug
uint32_t HELPER(xc)(CPUS390XState *env, uint32_t l, uint64_t dest, uint64_t src) { int i; unsigned char x; uint32_t cc = 0; HELPER_LOG("%s l %d dest %" PRIx64 " src %" PRIx64 "\n", __func__, l, dest, src); #ifndef CONFIG_USER_ONLY if ((l > 32) &&...
1threat
void bdrv_eject(BlockDriverState *bs, int eject_flag) { BlockDriver *drv = bs->drv; int ret; if (!drv || !drv->bdrv_eject) { ret = -ENOTSUP; } else { ret = drv->bdrv_eject(bs, eject_flag); } if (ret == -ENOTSUP) { if (eject_flag) bdrv_close(bs); ...
1threat
static char *spapr_vio_get_dev_name(DeviceState *qdev) { VIOsPAPRDevice *dev = VIO_SPAPR_DEVICE(qdev); VIOsPAPRDeviceClass *pc = VIO_SPAPR_DEVICE_GET_CLASS(dev); char *name; name = g_strdup_printf("%s@%x", pc->dt_name, dev->reg); return name; }
1threat
static void store_slice_c(uint8_t *dst, const int16_t *src, int dst_stride, int src_stride, int width, int height, int log2_scale) { int y, x; #define STORE(pos) do { \ temp = ((src[x + y * src_stride...
1threat
Swift sometimes calls wrong method : <p>I noticed strange behaviour during working with Swift projects. I can't explain it other than Swift sometimes calls wrong method. It is very rare and even adding blank lines to the code could lead that this error is gone.</p> <p>Let me explain in screenshots what I mean, next I ...
0debug
void ff_print_debug_info(MpegEncContext *s, AVFrame *pict) { if ( s->avctx->hwaccel || !pict || !pict->mb_type || (s->avctx->codec->capabilities&CODEC_CAP_HWACCEL_VDPAU)) return; if (s->avctx->debug & (FF_DEBUG_SKIP | FF_DEBUG_QP | FF_DEBUG_MB_TYPE)) { int x,y; av_...
1threat
static void vt82c686b_pm_realize(PCIDevice *dev, Error **errp) { VT686PMState *s = DO_UPCAST(VT686PMState, dev, dev); uint8_t *pci_conf; pci_conf = s->dev.config; pci_set_word(pci_conf + PCI_COMMAND, 0); pci_set_word(pci_conf + PCI_STATUS, PCI_STATUS_FAST_BACK | PCI_STATUS_...
1threat
static int get_port(const struct sockaddr_storage *ss) { sockaddr_union ssu = (sockaddr_union){.storage = *ss}; if (ss->ss_family == AF_INET) return ntohs(ssu.in.sin_port); #if HAVE_STRUCT_SOCKADDR_IN6 if (ss->ss_family == AF_INET6) return ntohs(ssu.in6.sin6_port); #endif return...
1threat
SearchView hints not showing for single character typed : <p>I'm working on an Android application written in Scala that uses <code>android.support.v7.widget.SearchView</code> inside the action bar that's overridden by <code>android.support.v7.widget.Toolbar</code>.</p> <p>In the app, I need to enable search suggestio...
0debug