message
stringlengths
6
474
diff
stringlengths
8
5.22k
Trogdor: Add debug messages to show the HPD change Show the HPD change message to help debugging issues. BRANCH=Trogdor TEST=Plug and unplug a Type-C monitor and check the messages.
@@ -226,9 +226,11 @@ __override int svdm_dp_attention(int port, uint32_t *payload) usleep(svdm_hpd_deadline[port] - now); /* Generate IRQ_HPD pulse */ + CPRINTS("C%d: Recv IRQ. HPD->0", port); gpio_set_level(hpd, 0); usleep(HPD_DSTREAM_DEBOUNCE_IRQ); gpio_set_level(hpd, 1); + CPRINTS("C%d: Recv IRQ. HPD->1", port); /* Set the minimum time delay (2ms) for the next HPD IRQ */ svdm_hpd_deadline[port] = get_time().val + @@ -237,6 +239,7 @@ __override int svdm_dp_attention(int port, uint32_t *payload) CPRINTF("ERR:HPD:IRQ&LOW\n"); return 0; } else { + CPRINTS("C%d: Recv lvl. HPD->%d", port, lvl); gpio_set_level(hpd, lvl); /* Set the minimum time delay (2ms) for the next HPD IRQ */ svdm_hpd_deadline[port] = get_time().val + @@ -248,6 +251,7 @@ __override int svdm_dp_attention(int port, uint32_t *payload) __override void svdm_exit_dp_mode(int port) { + CPRINTS("%s(%d)", __func__, port); if (is_dp_muxable(port)) { /* Disconnect the DP port selection mux. */ gpio_set_level(GPIO_DP_MUX_OE_L, 1); @@ -256,6 +260,7 @@ __override void svdm_exit_dp_mode(int port) /* Signal AP for the HPD low event */ usb_mux_hpd_update(port, USB_PD_MUX_HPD_LVL_DEASSERTED | USB_PD_MUX_HPD_IRQ_DEASSERTED); + CPRINTS("C%d: DP exit. HPD->0", port); gpio_set_level(GPIO_DP_HOT_PLUG_DET, 0); } }
Docs: Add -b/--bump-version option to BuildDocs.tool
@@ -30,16 +30,7 @@ latexbuild() { done } -cd "$(dirname "$0")" || abort "Wrong directory" - -if [ "$(which latexdiff)" = "" ]; then - abort "latexdiff is missing, check your TeX Live installation" -fi - -if [ "$(which pdflatex)" = "" ]; then - abort "pdflatex is missing, check your TeX Live installation" -fi - +builddocs() { latexbuild Configuration cd Differences || abort "Unable to process annotations" @@ -69,10 +60,9 @@ if [ $err -ne 0 ]; then abort "Failed to calculate built configuration hash!" fi + OLDHASH="" if [ -f "Configuration.md5" ]; then OLDHASH=$(cat "Configuration.md5") -else - OLDHASH="" fi echo "$HASH" > "Configuration.md5" @@ -82,5 +72,34 @@ if [ "$HASH" != "$OLDHASH" ]; then echo "Please run ./Docs/BuildDocs.tool." exit 1 fi +} + +main() { + if [ "$(which latexdiff)" = "" ]; then + abort "latexdiff is missing, check your TeX Live installation" + fi + + if [ "$(which pdflatex)" = "" ]; then + abort "pdflatex is missing, check your TeX Live installation" + fi + + cd "$(dirname "$0")" || abort "Wrong directory" + + case "$1" in + -b|--bump-version ) + cd Differences || abort "Unable to enter Differences directory" + rm -f PreviousConfiguration.tex + cp ../Configuration.tex PreviousConfiguration.tex + cd .. || abort "Unable to enter parent directory" + builddocs + ;; + + * ) + builddocs + ;; + esac +} + +main "$@" exit 0
wsman-client: fix memleak, release string after usage Strings are created by strdup in wsmc_create_delivery_*_str functions. So they should be explicitely released after usage.
@@ -891,16 +891,18 @@ wsman_set_subscribe_options(WsManClient * cl, XML_NS_EVENTING, WSEVENT_SUBSCRIBE,NULL); temp = ws_xml_add_child(node, XML_NS_EVENTING, WSEVENT_DELIVERY, NULL); if(temp) { - ws_xml_add_node_attr(temp, NULL, WSEVENT_DELIVERY_MODE, - wsmc_create_delivery_mode_str(options->delivery_mode)); + char *mode = wsmc_create_delivery_mode_str(options->delivery_mode); + ws_xml_add_node_attr(temp, NULL, WSEVENT_DELIVERY_MODE, mode); + u_free(mode); if(options->delivery_uri) { node2 = ws_xml_add_child(temp, XML_NS_EVENTING, WSEVENT_NOTIFY_TO, NULL); ws_xml_add_child(node2, XML_NS_ADDRESSING, WSA_ADDRESS, options->delivery_uri); } if(options->delivery_sec_mode) { temp = ws_xml_add_child(temp, XML_NS_WS_MAN, WSM_AUTH, NULL); - ws_xml_add_node_attr(temp, NULL, WSM_PROFILE, - wsmc_create_delivery_sec_mode_str(options->delivery_sec_mode)); + char *mode = wsmc_create_delivery_sec_mode_str(options->delivery_sec_mode); + ws_xml_add_node_attr(temp, NULL, WSM_PROFILE, mode); + u_free(mode); } if(options->heartbeat_interval) { snprintf(buf, 32, "PT%fS", options->heartbeat_interval);
silenced the broken hoon tests
::++ test-04-hint-xray-add :: ~> %xray.[1 leaf+"(add 1 2)"] :: (add 1 2) -++ test-03-hint-xray-meme - ~> %xray.[1 leaf+"(meme)"] - ~> %meme - ~ -++ test-02-hint-xray-combo - ^- @ud - ~> %xray - ~>(%meme (mul 1 2)) +::++ test-03-hint-xray-meme +:: ~> %xray.[1 leaf+"(meme)"] +:: ~> %meme +:: ~ +::++ test-02-hint-xray-combo +:: ^- @ud +:: ~> %xray +:: ~>(%meme (mul 1 2)) :::: test that the hilt bout hint :::: is safe to run or ignore ++ test-01-hilt-bout
CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE on_host_queue_props for pthread I don't see why this was not advertised before.
@@ -208,6 +208,9 @@ pocl_pthread_init (unsigned j, cl_device_id device, const char* parameters) pocl_init_cpu_device_infos (device); + device->on_host_queue_props = CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE + | CL_QUEUE_PROFILING_ENABLE; + /* hwloc probes OpenCL device info at its initialization in case the OpenCL extension is enabled. This causes to printout an unimplemented property error because hwloc is used to
README: Update for native Pycopy executable names.
@@ -105,14 +105,14 @@ To build (see section below for required dependencies): Then to give it a try: - $ ./micropython + $ ./pycopy >>> list(5 * x + y for x in range(10) for y in [4, 2, 1]) Use `CTRL-D` (i.e. EOF) to exit the shell. Learn about command-line options (in particular, how to increase heap size which may be needed for larger applications): - $ ./micropython --help + $ ./pycopy --help Run complete testsuite: @@ -120,8 +120,8 @@ Run complete testsuite: Unix version comes with a builtin package manager called `upip`, e.g.: - $ ./micropython -m upip install pycopy-pystone - $ ./micropython -m pystone + $ ./pycopy -m upip install pycopy-pystone + $ ./pycopy -m pystone Browse available modules on [PyPI](https://pypi.org/search/?q=pycopy-). Standard library modules come from
Respect BSD disable flags in gen2 functions
@@ -194,6 +194,9 @@ SURVIVE_EXPORT void survive_default_sync_process(SurviveObject *so, survive_chan return; } + if (so->ctx->bsd[bsd_idx].disable) + return; + assert(channel <= NUM_GEN2_LIGHTHOUSES); survive_recording_sync_process(so, channel, timecode, ootx, gen); @@ -318,6 +321,9 @@ SURVIVE_EXPORT void survive_default_sweep_process(SurviveObject *so, survive_cha return; } + if (so->ctx->bsd[bsd_idx].disable) + return; + survive_notify_gen2(so, "sweep called"); survive_recording_sweep_process(so, channel, sensor_id, timecode, half_clock_flag);
Return empty scene object, if no scenes are in a group
@@ -1814,6 +1814,11 @@ int DeRestPluginPrivate::getAllScenes(const ApiRequest &req, ApiResponse &rsp) } } + if (rsp.map.isEmpty()) + { + rsp.str = "{}"; // return empty object + } + return REQ_READY_SEND; }
Fix bug in addition of inter scc edges in FCG
@@ -447,6 +447,7 @@ void fcg_scc_cluster_add_inter_scc_edges (Graph* fcg, int *colour, PlutoProg *pr row_offset = conflictcst->nrows-CST_WIDTH+1+inter_scc_constraints->nrows; /* Add conflict constraints at the end of inter_scc_constraints */ + /* pluto_constraints_cplex_print (stdout,conflictcst); */ pluto_constraints_add(inter_scc_constraints, conflictcst); /* Set the shifting lb of coefficient for each statement in SCC1 to 0 */ @@ -478,8 +479,8 @@ void fcg_scc_cluster_add_inter_scc_edges (Graph* fcg, int *colour, PlutoProg *pr stmt2 = sccs[scc2].vertices[j]; if(dim2<=stmts[stmt2]->dim_orig) { stmt2_offset = npar+1+(nvar+1)*stmt2; - inter_scc_constraints->val[row_offset+stmt2_offset+dim1][CST_WIDTH-1] = -1; - inter_scc_constraints->is_eq[row_offset+stmt2_offset+dim1] = 0; + inter_scc_constraints->val[row_offset+stmt2_offset+dim2][CST_WIDTH-1] = -1; + inter_scc_constraints->is_eq[row_offset+stmt2_offset+dim2] = 0; } } /* Check if fusing ith dimesion of the source with ith dimension @@ -493,7 +494,7 @@ void fcg_scc_cluster_add_inter_scc_edges (Graph* fcg, int *colour, PlutoProg *pr /* If no solutions, then dimensions are not fusable. Add an edge in the conflict graph. */ if(sol == NULL) { - IF_DEBUG(printf("Unable to fuse Dimesnion %d of scc %d with dimension %d of scc %d \n",dim1,scc1 ,dim2 ,scc2);); + IF_DEBUG(printf("Unable to fuse dimension %d of scc %d with dimension %d of scc %d \n",dim1,scc1 ,dim2 ,scc2);); IF_DEBUG(printf(" Adding edge %d to %d in fcg\n",scc1_fcg_offset+dim1,scc2_fcg_offset+dim2);); fcg->adj->val[scc1_fcg_offset+dim1][scc2_fcg_offset+dim2] = 1; } else { @@ -511,8 +512,8 @@ void fcg_scc_cluster_add_inter_scc_edges (Graph* fcg, int *colour, PlutoProg *pr stmt2 = sccs[scc2].vertices[j]; if(dim2<=stmts[stmt2]->dim_orig) { stmt2_offset = npar+1+(nvar+1)*stmt2; - inter_scc_constraints->val[row_offset+stmt2_offset+dim1][CST_WIDTH-1] = 0; - inter_scc_constraints->is_eq[row_offset+stmt2_offset+dim1] = 1; + inter_scc_constraints->val[row_offset+stmt2_offset+dim2][CST_WIDTH-1] = 0; + inter_scc_constraints->is_eq[row_offset+stmt2_offset+dim2] = 1; } } }
make sure "<param>_len" for length parameters in probes
@@ -30,7 +30,7 @@ provider quicly { struct st_quicly_address_token_plaintext_t *address_token); probe free(struct st_quicly_conn_t *conn, int64_t at); probe send(struct st_quicly_conn_t *conn, int64_t at, int state, const char *dcid); - probe receive(struct st_quicly_conn_t *conn, int64_t at, const char *dcid, const void *bytes, size_t num_bytes); + probe receive(struct st_quicly_conn_t *conn, int64_t at, const char *dcid, const void *bytes, size_t bytes_len); probe version_switch(struct st_quicly_conn_t *conn, int64_t at, uint32_t new_version); probe idle_timeout(struct st_quicly_conn_t *conn, int64_t at); probe stateless_reset_receive(struct st_quicly_conn_t *conn, int64_t at); @@ -75,9 +75,9 @@ provider quicly { probe max_stream_data_send(struct st_quicly_conn_t *conn, int64_t at, struct st_quicly_stream_t *stream, uint64_t limit); probe max_stream_data_receive(struct st_quicly_conn_t *conn, int64_t at, int64_t stream_id, uint64_t limit); - probe new_token_send(struct st_quicly_conn_t *conn, int64_t at, uint8_t *token, size_t len, uint64_t generation); + probe new_token_send(struct st_quicly_conn_t *conn, int64_t at, uint8_t *token, size_t token_len, uint64_t generation); probe new_token_acked(struct st_quicly_conn_t *conn, int64_t at, uint64_t generation); - probe new_token_receive(struct st_quicly_conn_t *conn, int64_t at, uint8_t *token, size_t len); + probe new_token_receive(struct st_quicly_conn_t *conn, int64_t at, uint8_t *token, size_t token_len); probe handshake_done_send(struct st_quicly_conn_t *conn, int64_t at); probe handshake_done_receive(struct st_quicly_conn_t *conn, int64_t at);
OcCpuLib: Do not warn about CPU freq diff when TSC based freq is 0
@@ -753,9 +753,7 @@ ScanIntelProcessor ( DEBUG (( DEBUG_INFO, - "OCCPU: %a %a %11LuHz %5LuMHz = %Lu * %u / %u\n", - "ART", - "Frequency", + "OCCPU: CPUFrequencyFromART %11LuHz %5LuMHz = %Lu * %u / %u\n", Cpu->CPUFrequencyFromART, DivU64x32 (Cpu->CPUFrequencyFromART, 1000000), Cpu->ARTFrequency, @@ -778,11 +776,11 @@ ScanIntelProcessor ( // // Verify that our two CPU frequency calculations do not differ substantially. // - if (Cpu->CPUFrequencyFromART > 0 + if (Cpu->CPUFrequencyFromART > 0 && Cpu->CPUFrequencyFromTSC > 0 && ABS((INT64) Cpu->CPUFrequencyFromART - (INT64) Cpu->CPUFrequencyFromTSC) > OC_CPU_FREQUENCY_TOLERANCE) { DEBUG (( DEBUG_WARN, - "OCCPU: ART CPU frequency differs substantially from TSC: %11LuHz != %11LuHzX\n", + "OCCPU: ART based CPU frequency differs substantially from TSC: %11LuHz != %11LuHz\n", Cpu->CPUFrequencyFromART, Cpu->CPUFrequencyFromTSC )); @@ -1055,27 +1053,21 @@ OcCpuScanProcessor ( DEBUG (( DEBUG_INFO, - "OCCPU: %a %a %11LuHz %5LuMHz\n", - "TSC", - "Frequency", + "OCCPU: CPUFrequencyFromTSC %11LuHz %5LuMHz\n", Cpu->CPUFrequencyFromTSC, DivU64x32 (Cpu->CPUFrequencyFromTSC, 1000000) )); DEBUG (( DEBUG_INFO, - "OCCPU: %a %a %11LuHz %5LuMHz\n", - "CPU", - "Frequency", + "OCCPU: CPUFrequency %11LuHz %5LuMHz\n", Cpu->CPUFrequency, DivU64x32 (Cpu->CPUFrequency, 1000000) )); DEBUG (( DEBUG_INFO, - "OCCPU: %a %a %11LuHz %5LuMHz\n", - "FSB", - "Frequency", + "OCCPU: FSBFrequency %11LuHz %5LuMHz\n", Cpu->FSBFrequency, DivU64x32 (Cpu->FSBFrequency, 1000000) ));
ExtendedTools: Fix regression disk events (partial revert 24dcd7108a1a76aeebe797a0a69cf8679fab429d)
@@ -257,11 +257,16 @@ VOID NTAPI EtEtwProcessesUpdatedCallback( PET_PROCESS_BLOCK maxNetworkBlock = NULL; PLIST_ENTRY listEntry; + // Since Windows 8, we no longer get the correct process/thread IDs in the + // event headers for disk events. We need to update our process information since + // etwmon uses our EtThreadIdToProcessId function. (wj32) + if (PhWindowsVersion >= WINDOWS_8) + EtpUpdateProcessInformation(); + // ETW is extremely lazy when it comes to flushing buffers, so we must do it manually. (wj32) //EtFlushEtwSession(); // Update global statistics. - PhUpdateDelta(&EtDiskReadDelta, EtpDiskReadRaw); PhUpdateDelta(&EtDiskWriteDelta, EtpDiskWriteRaw); PhUpdateDelta(&EtNetworkReceiveDelta, EtpNetworkReceiveRaw);
DDF gold status Wiser SMARTPLUG/1 Also removes redundant descriptions from general items.
"modelid": "SMARTPLUG/1", "product": "SMARTPLUG/1", "sleeper": false, - "status": "Silver", - "path": "/devices/schneider.json", + "status": "Gold", "subdevices": [ { "type": "$TYPE_SMART_PLUG", }, { "name": "state/alert", - "description": "The currently active alert effect.", "default": "none" }, { "name": "state/on", - "description": "True when device is on; false when off.", "refresh.interval": 5 }, { }, { "name": "state/current", - "description": "The measured current (in mA).", "refresh.interval": 300 }, { }, { "name": "state/power", - "description": "The measured power (in W).", "refresh.interval": 300 }, { "name": "state/voltage", - "description": "The measured voltage (in V).", "refresh.interval": 300 } ]
common: fix IPI buffer vaddr location There should be an offset: CONFIG_PROGRAM_MEMORY_BASE. BRANCH=none TEST=make BOARD=asurada_scp
@@ -45,7 +45,7 @@ MEMORY FLASH (rx) : ORIGIN = CONFIG_PROGRAM_MEMORY_BASE, LENGTH = CONFIG_FLASH_SIZE #ifdef CONFIG_IPI - IPI_BUFFER (rw) : ORIGIN = CONFIG_IPC_SHARED_OBJ_ADDR, + IPI_BUFFER (rw) : ORIGIN = CONFIG_PROGRAM_MEMORY_BASE + CONFIG_IPC_SHARED_OBJ_ADDR, LENGTH = (CONFIG_IPC_SHARED_OBJ_BUF_SIZE + 8) * 2 #endif #ifdef CONFIG_DRAM_BASE
Documentation: Improve wording of sentence
@@ -274,7 +274,7 @@ Note that no code should be outside of `if (DEPENDENCY_PHASE)`. It would be exec > Please note that the parameters passed to `add_plugin` need to be constant between all invocations. > Some `find_package` cache their variables, others do not, which might lead to toggling variables. -> To avoid problem, make a variable containing all `LINK_LIBRARIES` or `DEPENDENCIES` within `DEPENDENCY_PHASE`. +> To avoid problems, create a variable containing all `LINK_LIBRARIES` or `DEPENDENCIES` within `DEPENDENCY_PHASE`. If your plugin makes use of [compilation variants](/doc/tutorials/compilation-variants.md) you should also read the information there.
Clean up and const correctness
@@ -256,11 +256,21 @@ static void restart_bitmap(grib_accessor_bufr_data_array *self) self->bitmapCurrentElementsDescriptorsIndex=self->bitmapStartElementsDescriptorsIndex-1; } -static void cancel_bitmap(grib_accessor_bufr_data_array *self) { self->bitmapCurrent=-1;self->bitmapStart=-1; } +static void cancel_bitmap(grib_accessor_bufr_data_array *self) +{ + self->bitmapCurrent=-1; + self->bitmapStart=-1; +} -static int is_bitmap_start_defined(grib_accessor_bufr_data_array *self) { return self->bitmapStart==-1 ? 0 : 1; } +static int is_bitmap_start_defined(grib_accessor_bufr_data_array *self) +{ + return self->bitmapStart==-1 ? 0 : 1; +} -int accessor_bufr_data_array_create_keys(grib_accessor* a,long onlySubset,long startSubset,long endSubset) { return create_keys(a,onlySubset,startSubset,endSubset); } +int accessor_bufr_data_array_create_keys(grib_accessor* a,long onlySubset,long startSubset,long endSubset) +{ + return create_keys(a,onlySubset,startSubset,endSubset); +} int accessor_bufr_data_array_process_elements(grib_accessor* a,int flag,long onlySubset,long startSubset,long endSubset) { @@ -1003,8 +1013,9 @@ static int decode_element(grib_context* c,grib_accessor_bufr_data_array* self,in err=check_end_data(c, self, number_of_bits); /*advance bitsToEnd*/ return err; } - grib_context_log(c, GRIB_LOG_DEBUG,"BUFR data decoding: -%ld- \tcode=%6.6ld width=%ld pos=%ld -> %ld", - i,bd->code,bd->width,(long)*pos,(long)(*pos-a->offset*8)); + grib_context_log(c, GRIB_LOG_DEBUG,"BUFR data decoding: -%ld- \tcode=%6.6ld width=%ld scale=%ld ref=%ld (pos=%ld -> %ld)", + i, bd->code, bd->width, bd->scale, bd->reference, + (long)*pos, (long)(*pos-a->offset*8)); if (bd->type==BUFR_DESCRIPTOR_TYPE_STRING) { /* string */ if (self->compressedData) { @@ -1891,7 +1902,7 @@ static grib_accessor* create_accessor_from_descriptor(grib_accessor* a,grib_acce #define NUMBER_OF_QUALIFIERS_CATEGORIES 7 #define MAX_NUMBER_OF_BITMAPS 5 -static int number_of_qualifiers=NUMBER_OF_QUALIFIERS_PER_CATEGORY*NUMBER_OF_QUALIFIERS_CATEGORIES; +static const int number_of_qualifiers=NUMBER_OF_QUALIFIERS_PER_CATEGORY*NUMBER_OF_QUALIFIERS_CATEGORIES; static GRIB_INLINE int significanceQualifierIndex(int X,int Y) {
Removal of Userquestions and Removing the user question and feature requests whitelist from close bot.
@@ -27,18 +27,18 @@ issueConfigs: # Example 2: Device Request - "Device" - "Screenshots" -- content: +#- content: # Example 3: Feature Request - - "Feature request type" - - "Description" - - "Considered alternatives" - - "Additional context" -- content: + #- "Feature request type" + # - "Description" + # - "Considered alternatives" + # - "Additional context" +#- content: # Example 4: User Question - - "Describe the question or issue you are having" - - "Screenshots" - - "Environment" - - "deCONZ Logs" - - "Additional context" +# - "Describe the question or issue you are having" +#- "Screenshots" +# - "Environment" +# - "deCONZ Logs" +# - "Additional context" # The issue is judged to be legal if it includes all keywords from any of these configs. # Or it will be closed by the app.
Update default confirmation dialog icon
@@ -608,7 +608,7 @@ BOOLEAN PhShowConfirmMessage( config.hInstance = PhInstanceHandle; config.dwFlags = TDF_ALLOW_DIALOG_CANCELLATION | (IsWindowVisible(hWnd) ? TDF_POSITION_RELATIVE_TO_WINDOW : 0); config.pszWindowTitle = PhApplicationName; - config.pszMainIcon = Warning ? TD_WARNING_ICON : NULL; + config.pszMainIcon = Warning ? TD_WARNING_ICON : TD_INFORMATION_ICON; config.pszMainInstruction = PhaConcatStrings(3, L"Do you want to ", action->Buffer, L"?")->Buffer; if (Message)
Set task to all light nodes if task target is group id 0 (all groups)
@@ -6773,7 +6773,7 @@ void DeRestPluginPrivate::taskToLocalData(const TaskItem &task) for (; i != end; ++i) { LightNode *lightNode = &(*i); - if (isLightNodeInGroup(lightNode, task.req.dstAddress().group())) + if (isLightNodeInGroup(lightNode, task.req.dstAddress().group()) || group->id() == "0") { pushNodes.push_back(lightNode); }
zephyr/include/ap_power/ap_power.h: Format with clang-format BRANCH=none TEST=none
@@ -129,7 +129,8 @@ struct ap_power_ev_callback { * @param handler The function pointer to call. * @param events The bitmask of events to be called for. */ -static inline void ap_power_ev_init_callback(struct ap_power_ev_callback *cb, +static inline void +ap_power_ev_init_callback(struct ap_power_ev_callback *cb, ap_power_ev_callback_handler_t handler, enum ap_power_events events) {
[ArgoUI] 0.1.8
Pod::Spec.new do |s| s.name = 'ArgoUI' - s.version = '0.1.7' + s.version = '0.1.8' s.summary = 'A lib of Momo Lua UI.' # This description is used to generate tags and improve search results.
Initialize abs_mask1 with itself to silence a gcc warning actual initialization is via the _mm_cmpeq_ep18, which I've seen claimed to be the fastest way to set an xmm register to all 1s
@@ -15,7 +15,7 @@ static FLOAT casum_kernel(BLASLONG n, FLOAT *x) if (n2 < 64) { __m128 accum_10, accum_11, accum_12, accum_13; - __m128 abs_mask1; + __m128 abs_mask1 = abs_mask1; accum_10 = _mm_setzero_ps(); accum_11 = _mm_setzero_ps();
Restoring apps in case of reconfiguration error.
@@ -705,6 +705,7 @@ nxt_router_temp_conf(nxt_task_t *task) nxt_queue_init(&tmcf->updating); nxt_queue_init(&tmcf->pending); nxt_queue_init(&tmcf->creating); + nxt_queue_init(&tmcf->apps); nxt_queue_init(&tmcf->previous); @@ -834,6 +835,8 @@ nxt_router_conf_error(nxt_task_t *task, nxt_router_temp_conf_t *tmcf) nxt_queue_add(&router->sockets, &tmcf->keeping); nxt_queue_add(&router->sockets, &tmcf->deleting); + nxt_queue_add(&router->apps, &tmcf->previous); + // TODO: new engines and threads nxt_mp_destroy(tmcf->conf->mem_pool);
docs/conf: Version 2.11.0.9.
@@ -74,7 +74,7 @@ copyright = '2014-2019, Damien P. George, Paul Sokolovsky, and contributors' # # We don't follow "The short X.Y version" vs "The full version, including alpha/beta/rc tags" # breakdown, so use the same version identifier for both to avoid confusion. -version = release = '1.11' +version = release = '2.11.0.9' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages.
crypto_botan: fix encryption The last commit broke the encryption in crypto_botan. The issues is related to .
@@ -224,9 +224,10 @@ int elektraCryptoBotanEncrypt (KeySet * pluginConfig, Key * k, Key * errorKey, K memcpy (&buffer[bufferIndex], &saltLen, sizeof (kdb_unsigned_long_t)); bufferIndex += sizeof (kdb_unsigned_long_t); memcpy (&buffer[bufferIndex], salt, saltLen); + bufferIndex += saltLen; - const size_t buffered = encryptor.read (&buffer[sizeof (kdb_unsigned_long_t) + saltLen], msgLength); - keySetBinary (k, &buffer[0], buffered + sizeof (kdb_unsigned_long_t) + saltLen); + const size_t buffered = encryptor.read (&buffer[bufferIndex], msgLength); + keySetBinary (k, &buffer[0], buffered + bufferIndex); } } catch (std::exception & e)
0.3.0; more readme fixes
## The CLI project is a small and simple REPL and CLI tool for running Wren scripts. -It is backed by [libuv][http://libuv.org/] to implement IO functionality, and is a work in progress. +It is backed by [libuv](http://libuv.org/) to implement IO functionality, and is a work in progress. For documentation and usage, see http://wren.io/cli For more information about Wren, the language used by the CLI, see http://wren.io -Like with Wren, we welcome [contributions][contribute]. +Like with Wren itself, we welcome [contributions][contribute]. [contribute]: http://wren.io/contributing.html
Include community board oxygen in select
@@ -69,7 +69,8 @@ foreach(SRC_FILE ${CHIBIOS_PORT_SRCS}) ${CHIBIOS_BOARD} STREQUAL "ST_STM32F4_DISCOVERY" OR ${CHIBIOS_BOARD} STREQUAL "MBN_QUAIL" OR ${CHIBIOS_BOARD} STREQUAL "NETDUINO3_WIFI" OR - ${CHIBIOS_BOARD} STREQUAL "I2M_ELECTRON_NF") + ${CHIBIOS_BOARD} STREQUAL "I2M_ELECTRON_NF" OR + ${CHIBIOS_BOARD} STREQUAL "I2M_OXYGEN_NF") ${PROJECT_BINARY_DIR}/ChibiOS_Source/os/hal/ports/STM32/LLD/I2Cv1 else() ${PROJECT_BINARY_DIR}/ChibiOS_Source/os/hal/ports/STM32/LLD/I2Cv2 @@ -104,7 +105,8 @@ if(${CHIBIOS_BOARD} STREQUAL "ST_STM32F429I_DISCOVERY" OR ${CHIBIOS_BOARD} STREQUAL "ST_STM32F4_DISCOVERY" OR ${CHIBIOS_BOARD} STREQUAL "MBN_QUAIL" OR ${CHIBIOS_BOARD} STREQUAL "NETDUINO3_WIFI" OR - ${CHIBIOS_BOARD} STREQUAL "I2M_ELECTRON_NF") + ${CHIBIOS_BOARD} STREQUAL "I2M_ELECTRON_NF" OR + ${CHIBIOS_BOARD} STREQUAL "I2M_OXYGEN_NF") list(APPEND CHIBIOS_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/os/hal/ports/STM32/LLD/I2Cv1) else() list(APPEND CHIBIOS_INCLUDE_DIRS ${PROJECT_BINARY_DIR}/ChibiOS_Source/os/hal/ports/STM32/LLD/I2Cv2)
nimble/fem: Reset SKY66112 to defaults on HCI reset Make sure we set all configuration to defaults when HCI reset is issued.
@@ -43,7 +43,11 @@ sky66112_bypass(uint8_t enabled) void ble_fem_pa_init(void) { - /* Nothing to do here */ + sky66112_tx_hp_mode(MYNEWT_VAL(SKY66112_TX_HP_MODE)); + sky66112_tx_bypass(0); +#if MYNEWT_VAL(BLE_FEM_ANTENNA) + ble_fem_antenna(MYNEWT_VAL(SKY66112_ANTENNA_PORT)); +#endif } void @@ -65,7 +69,10 @@ ble_fem_pa_disable(void) void ble_fem_lna_init(void) { - /* Nothing to do here */ + sky66112_rx_bypass(0); +#if MYNEWT_VAL(BLE_FEM_ANTENNA) + ble_fem_antenna(MYNEWT_VAL(SKY66112_ANTENNA_PORT)); +#endif } void
Fix id generation issues when creating sensors
@@ -262,22 +262,9 @@ int DeRestPluginPrivate::createSensor(const ApiRequest &req, ApiResponse &rsp) QVariantMap rspItemState; // create a new sensor id - sensor.setId("1"); - - do { - ok = true; - std::vector<Sensor>::const_iterator i = sensors.begin(); - std::vector<Sensor>::const_iterator end = sensors.end(); - - for (; i != end; ++i) - { - if (i->id() == sensor.id()) - { - sensor.setId(QString::number(i->id().toInt() + 1)); - ok = false; - } - } - } while (!ok); + openDb(); + sensor.setId(QString::number(getFreeSensorId())); + closeDb(); sensor.setName(map["name"].toString()); sensor.setManufacturer(map["manufacturername"].toString());
Add test of ALPN check.
@@ -1631,9 +1631,24 @@ int tls_api_sni_test() return tls_api_test_with_loss(NULL, 0, PICOQUIC_TEST_SNI, PICOQUIC_TEST_ALPN); } +/* The ALPN test checks that the connection fails if no ALPN is specified. + */ + int tls_api_alpn_test() { - return tls_api_test_with_loss(NULL, 0, PICOQUIC_TEST_SNI, PICOQUIC_TEST_ALPN); + int ret = tls_api_test_with_loss(NULL, 0, PICOQUIC_TEST_SNI, NULL); + + if (ret == PICOQUIC_ERROR_NO_ALPN_PROVIDED) { + ret = 0; + } else if (ret == 0) { + DBG_PRINTF("ALPN test succeeds while no ALPN is specified, ret = 0x%x", ret); + ret = -1; + } + else { + DBG_PRINTF("ALPN test does not return expected error code, ret = 0x%x", ret); + ret = -1; + } + return ret; } int tls_api_wrong_alpn_test()
fix possible segfault if a file does not exist
@@ -43,6 +43,9 @@ char* decryptOidcFile(const char* filename, const char* password) { */ char* decryptFile(const char* filepath, const char* password) { list_t* lines = getLinesFromFile(filepath); + if (lines == NULL) { + return NULL; + } char* promptedPassword = NULL; char* ret = NULL; if (password) { @@ -113,6 +116,10 @@ char* decryptHexFileContent(const char* cipher, const char* password) { * usage. */ char* decryptLinesList(list_t* lines, const char* password) { + if (lines == NULL) { + oidc_setArgNullFuncError(__func__); + return NULL; + } list_node_t* node = list_at(lines, 0); char* cipher = node ? node->val : NULL; node = list_at(lines, -1);
Fix for IOT_SERIALIZER_SCALAR_NULL datatype. The length of "null" element isn't included into container's offset calculation logic.
@@ -463,6 +463,7 @@ static void _appendData( _jsonContainer_t * pContainer, case IOT_SERIALIZER_SCALAR_NULL: strncpy( ( char * ) _jsonContainerPointer( pContainer ), _JSON_NULL_VALUE, _JSON_NULL_VALUE_LENGTH ); + pContainer->offset += _JSON_NULL_VALUE_LENGTH; break; default:
CMake: update for SSL
CMAKE_MINIMUM_REQUIRED(VERSION 3.0.0) INCLUDE(GNUInstallDirs) +PROJECT(hiredis) + +OPTION(HIREDIS_SSL "Link against OpenSSL" ON) MACRO(getVersionBit name) SET(VERSION_REGEX "^#define ${name} (.+)$") @@ -27,7 +30,8 @@ ADD_LIBRARY(hiredis SHARED hiredis.c net.c read.c - sds.c) + sds.c + sslio.c) SET_TARGET_PROPERTIES(hiredis PROPERTIES @@ -44,9 +48,22 @@ INSTALL(FILES hiredis.h read.h sds.h async.h INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/hiredis.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) +IF(HIREDIS_SSL) + IF (NOT OPENSSL_ROOT_DIR) + IF (APPLE) + SET(OPENSSL_ROOT_DIR "/usr/local/opt/openssl") + ENDIF() + ENDIF() + FIND_PACKAGE(OpenSSL REQUIRED) + ADD_DEFINITIONS(-DHIREDIS_SSL) + INCLUDE_DIRECTORIES("${OPENSSL_INCLUDE_DIR}") + TARGET_LINK_LIBRARIES(hiredis ${OPENSSL_LIBRARIES}) +ENDIF() + ENABLE_TESTING() -ADD_EXECUTABLE(hiredis-test - test.c) +ADD_EXECUTABLE(hiredis-test test.c) + + TARGET_LINK_LIBRARIES(hiredis-test hiredis) ADD_TEST(NAME hiredis-test COMMAND ${CMAKE_CURRENT_SOURCE_DIR}/test.sh)
Mark testkdb_contracts as requiring error plugin
@@ -96,7 +96,7 @@ add_kdb_test (conflict REQUIRED_PLUGINS error) add_kdb_test (error REQUIRED_PLUGINS error list spec) add_kdb_test (nested REQUIRED_PLUGINS error) add_kdb_test (simple REQUIRED_PLUGINS error) -add_kdb_test (contracts REQUIRED_PLUGINS gopts list) +add_kdb_test (contracts REQUIRED_PLUGINS error list gopts) check_xcode () if ("${XCODE_VERSION}" VERSION_EQUAL 10.1)
doc: review changes and res. merge conflicts
# Contributing We use [GitHub](https://github.com/ElektraInitiative/libelektra/) to maintain this project. First of all you will need a GitHub account and [Git](https://www.git-scm.com/). -If you are looking for a IDE you can use [CLion](https://www.jetbrains.com/clion/) ([setup tutorial](/doc/tutorials/contributing-clion.md)) or [Visual Studio Code](https://code.visualstudio.com/). +If you are interested to use an IDE, there are two IDEs which Elektra developers currently use: + +- [CLion](https://www.jetbrains.com/clion/) with a [setup tutorial](/doc/tutorials/contributing-clion.md) +- [Visual Studio Code](https://code.visualstudio.com/) ## Configure Git @@ -26,7 +29,7 @@ $ git push origin master --force ## Issues -Check the [Ideas](/doc/IDEAS.md) page if you are searching for a good topic to start with. You can also visit the [issue-tracker](https://github.com/ElektraInitiative/libelektra/issues) and filter the list by pre-defined labels like _good first issue_ or _help wanted_.Do not hesitate to open a new issue if you want to ask a question, report or fix a bug or approach new topics. +Check the [Ideas](/doc/IDEAS.md) page if you are searching for a good topic to start with. You can also visit the [issue-tracker](https://github.com/ElektraInitiative/libelektra/issues) and filter the list by pre-defined labels like [good first issue](https://github.com/ElektraInitiative/libelektra/labels/good%20first%20issue).Do not hesitate to open a new issue if you want to ask a question, report or fix a bug or approach new topics. ## Creating a Pull-Request
common/switch.c: Format with clang-format BRANCH=none TEST=none
@@ -105,12 +105,8 @@ static int command_mmapinfo(int argc, char **argv) uint8_t val = *memmap_switches; int i; const char *explanation[] = { - "lid_open", - "powerbtn", - "wp_off", - "kbd_rec", - "gpio_rec", - "fake_dev", + "lid_open", "powerbtn", "wp_off", + "kbd_rec", "gpio_rec", "fake_dev", }; ccprintf("memmap switches = 0x%x\n", val); for (i = 0; i < ARRAY_SIZE(explanation); i++) @@ -119,7 +115,6 @@ static int command_mmapinfo(int argc, char **argv) return EC_SUCCESS; } -DECLARE_CONSOLE_COMMAND(mmapinfo, command_mmapinfo, - NULL, +DECLARE_CONSOLE_COMMAND(mmapinfo, command_mmapinfo, NULL, "Print memmap switch state"); #endif
input: changed the value for FLB_INPUT_NET_SERVER because it overlapped with FLB_IO_ASYNC
#define FLB_INPUT_PRIVATE 256 /* plugin is not published/exposed */ #define FLB_INPUT_NOTAG 512 /* plugin might don't have tags */ #define FLB_INPUT_THREADED 1024 /* plugin must run in a separate thread */ -#define FLB_INPUT_NET_SERVER 8 /* Input address may set host and port. +#define FLB_INPUT_NET_SERVER 2048 /* Input address may set host and port. * In addition, if TLS is enabled then a * private key and certificate are required. */
esp_prov : Support new JSON format of version string while maintaining backward compatibility Other changes: * Version check only happens if command line argument is specified * Minor bugfix in processing apply_config response
@@ -20,6 +20,7 @@ import argparse import time import os import sys +import json try: import security @@ -81,13 +82,26 @@ def get_transport(sel_transport, softap_endpoint=None, ble_devname=None): return None -def version_match(tp, protover): +def version_match(tp, protover, verbose=False): try: response = tp.send_data('proto-ver', protover) - if response != protover: - return False + + if verbose: + print("proto-ver response : ", response) + + # First assume this to be a simple version string + if response.lower() == protover.lower(): return True - except RuntimeError as e: + + # Else interpret this as JSON structure containing + # information with versions and capabilities of both + # provisioning service and application + info = json.loads(response) + if info['prov']['ver'].lower() == protover.lower(): + return True + + return False + except Exception as e: on_except(e) return None @@ -132,7 +146,7 @@ def apply_wifi_config(tp, sec): try: message = prov.config_apply_config_request(sec) response = tp.send_data('prov-config', message) - return (prov.config_set_config_response(sec, response) == 0) + return (prov.config_apply_config_response(sec, response) == 0) except RuntimeError as e: on_except(e) return None @@ -159,7 +173,7 @@ if __name__ == '__main__': parser.add_argument("--sec_ver", dest='secver', type=int, help="Security scheme version", default=1) parser.add_argument("--proto_ver", dest='protover', type=str, - help="Protocol version", default='V0.1') + help="Protocol version", default='') parser.add_argument("--pop", dest='pop', type=str, help="Proof of possession", default='') @@ -182,6 +196,7 @@ if __name__ == '__main__': parser.add_argument("-v","--verbose", help="increase output verbosity", action="store_true") args = parser.parse_args() + if args.protover != '': print("==== Esp_Prov Version: " + args.protover + " ====") obj_security = get_security(args.secver, args.pop, args.verbose) @@ -194,8 +209,9 @@ if __name__ == '__main__': print("---- Invalid provisioning mode ----") exit(2) + if args.protover != '': print("\n==== Verifying protocol version ====") - if not version_match(obj_transport, args.protover): + if not version_match(obj_transport, args.protover, args.verbose): print("---- Error in protocol version matching ----") exit(3) print("==== Verified protocol version successfully ====")
BugID:16760137 : modify linkkit_gateway.mk for gateway new api
NAME := linkkit_gateway -$(NAME)_SOURCES := linkkit_example_gateway.c \ - app_entry.c +$(NAME)_SOURCES := app_entry.c $(NAME)_COMPONENTS += network/netmgr \ @@ -11,14 +10,20 @@ $(NAME)_COMPONENTS += network/netmgr \ $(NAME)_COMPONENTS += feature.linkkit-gateway GLOBAL_CFLAGS += -DCONFIG_DM_DEVTYPE_GATEWAY \ - -DMQTT_DIRECT \ - -DDEPRECATED_LINKKIT + -DMQTT_DIRECT ifeq ($(LWIP),1) $(NAME)_COMPONENTS += protocols.net no_with_lwip := 0 endif +ifeq ($(newapi),1) +$(NAME)_SOURCES += newapi/gateway.c +else +$(NAME)_SOURCES += linkkit_example_gateway.c +GLOBAL_CFLAGS += -DDEPRECATED_LINKKIT +endif + ifeq ($(print_heap),1) $(NAME)_DEFINES += CONFIG_PRINT_HEAP endif @@ -32,8 +37,8 @@ GLOBAL_DEFINES += ESP8266_CHIPSET endif #for test command -GLOBAL_CFLAGS += -DLINKKIT_GATEWAY_TEST_CMD -$(NAME)_SOURCES += simulate_subdev/testcmd.c simulate_subdev/testcmd_lock.c +#GLOBAL_CFLAGS += -DLINKKIT_GATEWAY_TEST_CMD +#$(NAME)_SOURCES += simulate_subdev/testcmd.c simulate_subdev/testcmd_lock.c #end GLOBAL_INCLUDES += ./
Only call `h2o_url_parse` if we know the path isn't absolute
@@ -354,10 +354,11 @@ static ssize_t fixup_request(struct st_h2o_http1_conn_t *conn, struct phr_header entity_header_index = init_headers(&conn->req.pool, &conn->req.headers, headers, num_headers, &connection, &host, &upgrade, expect); - if (h2o_url_parse(conn->req.input.path.base, conn->req.input.path.len, &url) == 0) + if (conn->req.input.path.len > 0 && conn->req.input.path.base[0] != '/' && h2o_url_parse(conn->req.input.path.base, conn->req.input.path.len, &url) == 0) conn->req.input.path = h2o_strdup(&conn->req.pool, url.path.base, url.path.len); else conn->req.input.path = h2o_strdup(&conn->req.pool, conn->req.input.path.base, conn->req.input.path.len); + /* copy the values to pool, since the buffer pointed by the headers may get realloced */ if (entity_header_index != -1) { size_t i;
Range: Fix warning about discarded qualifiers
@@ -106,7 +106,7 @@ int main (int argc, char ** argv) init (argc, argv); - const char * old_locale = elektraStrDup (setlocale (LC_ALL, NULL)); + char * old_locale = elektraStrDup (setlocale (LC_ALL, NULL)); setlocale (LC_ALL, "C"); testInt ("5", 1, "1-10");
upstream: remove double check of tls_session
@@ -340,11 +340,9 @@ static int prepare_destroy_conn(struct flb_upstream_conn *u_conn) static int destroy_conn(struct flb_upstream_conn *u_conn) { #ifdef FLB_HAVE_TLS - if (u_conn->tls_session) { if (u_conn->tls_session) { flb_tls_session_destroy(u_conn->tls, u_conn); } - } #endif mk_list_del(&u_conn->_head); flb_free(u_conn);
tools: xxd-c: fix leak on open file on error (CID 184253)
@@ -108,6 +108,9 @@ static int xxdc_convert(char *in, char *out, char *name) if (!f_in) { perror("fopen"); fprintf(stderr, "error opening input file: %s\n", in); + if (out) { + fclose(f_out); + } return -1; }
Fix non-windows build break in PAL.cpp
@@ -512,7 +512,7 @@ namespace PAL_NS_BEGIN { } #ifndef HAVE_MAT_UTC - bool PlatformAbstractionLayer::IsUtcRegistrationEnabledinWindows() + bool PlatformAbstractionLayer::IsUtcRegistrationEnabledinWindows() const noexcept { return false; }
[Components][WINUSB]Fix USB_VENDOR_ID and USB_PRODUCT_ID Macro
@@ -181,10 +181,10 @@ menu "Using USB" default n if RT_USING_USB_DEVICE - config CONFIG_USB_VENDOR_ID + config USB_VENDOR_ID hex "USB Vendor ID" default 0x0FFE - config CONFIG_USB_PRODUCT_ID + config USB_PRODUCT_ID hex "USB Product ID" default 0x0001
drivers/audio/cs4344: add txchannels method and fix supported data width
****************************************************************************/ static int cs4344_setmclkfrequency(FAR struct cs4344_dev_s *priv); +static void cs4344_settxchannels(FAR struct cs4344_dev_s *priv); static void cs4344_setdatawidth(FAR struct cs4344_dev_s *priv); static void cs4344_setbitrate(FAR struct cs4344_dev_s *priv); @@ -287,11 +288,26 @@ static int cs4344_setmclkfrequency(FAR struct cs4344_dev_s *priv) return ret > 0 ? OK : ret; } +/**************************************************************************** + * Name: cs4344_settxchannels + * + * Description: + * Set the number of channels + * + ****************************************************************************/ + +static void cs4344_settxchannels(FAR struct cs4344_dev_s *priv) +{ + DEBUGASSERT(priv); + + I2S_TXCHANNELS(priv->i2s, priv->nchannels); +} + /**************************************************************************** * Name: cs4344_setdatawidth * * Description: - * Set the 8- or 16-bit data modes + * Set the 16 or 24-bit data modes * ****************************************************************************/ @@ -301,13 +317,13 @@ static void cs4344_setdatawidth(FAR struct cs4344_dev_s *priv) { /* Reset default default setting */ - priv->i2s->ops->i2s_txdatawidth(priv->i2s, 16); + I2S_TXDATAWIDTH(priv->i2s, 16); } else { - /* This should select 8-bit with no companding */ + /* This should select 24-bit with no companding */ - priv->i2s->ops->i2s_txdatawidth(priv->i2s, 8); + I2S_TXDATAWIDTH(priv->i2s, 24); } } @@ -320,7 +336,7 @@ static void cs4344_setbitrate(FAR struct cs4344_dev_s *priv) { DEBUGASSERT(priv); - priv->i2s->ops->i2s_txsamplerate(priv->i2s, priv->samprate); + I2S_TXSAMPLERATE(priv->i2s, priv->samprate); audinfo("sample rate=%u nchannels=%u bpsamp=%u\n", priv->samprate, priv->nchannels, priv->bpsamp); @@ -553,7 +569,7 @@ cs4344_configure(FAR struct audio_lowerhalf_s *dev, break; } - if (caps->ac_controls.b[2] != 8 && caps->ac_controls.b[2] != 16) + if (caps->ac_controls.b[2] != 16 && caps->ac_controls.b[2] != 24) { auderr("ERROR: Unsupported bits per sample: %d\n", caps->ac_controls.b[2]); @@ -589,6 +605,7 @@ cs4344_configure(FAR struct audio_lowerhalf_s *dev, } } + cs4344_settxchannels(priv); cs4344_setdatawidth(priv); cs4344_setbitrate(priv); }
BugID:18115181:fix mqtt topic/payload handler error
@@ -184,7 +184,18 @@ static void iotx_cloud_conn_mqtt_event_handle(void *pcontext, void *pclient, iot CM_ERR("sub handle is null!"); return; } - topic_handle_func(_mqtt_conncection->fd, topic_info->ptopic, topic_info->payload, topic_info->payload_len, NULL); + + char *topic = cm_malloc(topic_info->topic_len + 1); + if (topic == NULL) { + CM_ERR("topic malloc failed"); + return; + } + memset(topic,0,topic_info->topic_len + 1); + memcpy(topic,topic_info->ptopic,topic_info->topic_len); + + topic_handle_func(_mqtt_conncection->fd, topic, topic_info->payload, topic_info->payload_len, NULL); + + cm_free(topic); } break;
YAML: Move plugin contract into separate function
/* -- Imports --------------------------------------------------------------------------------------------------------------------------- */ #include "yaml.h" + #include <kdbhelper.h> +#include <kdblogger.h> /* -- Functions ------------------------------------------------------------------------------------------------------------------------- */ +// =========== +// = Private = +// =========== + +/** + * @brief This function returns a key set containing the contract of this plugin. + * + * @return A contract describing the functionality of this plugin. + */ +static inline KeySet * contractYaml () +{ + return ksNew (30, keyNew ("system/elektra/modules/yaml", KEY_VALUE, "yaml plugin waits for your orders", KEY_END), + keyNew ("system/elektra/modules/yaml/exports", KEY_END), + keyNew ("system/elektra/modules/yaml/exports/get", KEY_FUNC, elektraYamlGet, KEY_END), + keyNew ("system/elektra/modules/yaml/exports/set", KEY_FUNC, elektraYamlSet, KEY_END), +#include ELEKTRA_README (yaml) + keyNew ("system/elektra/modules/yaml/infos/version", KEY_VALUE, PLUGINVERSION, KEY_END), KS_END); +} + // ==================== // = Plugin Interface = // ==================== @@ -23,13 +44,8 @@ int elektraYamlGet (Plugin * handle ELEKTRA_UNUSED, KeySet * returned ELEKTRA_UN { if (!elektraStrCmp (keyName (parentKey), "system/elektra/modules/yaml")) { - KeySet * contract = - ksNew (30, keyNew ("system/elektra/modules/yaml", KEY_VALUE, "yaml plugin waits for your orders", KEY_END), - keyNew ("system/elektra/modules/yaml/exports", KEY_END), - keyNew ("system/elektra/modules/yaml/exports/get", KEY_FUNC, elektraYamlGet, KEY_END), - keyNew ("system/elektra/modules/yaml/exports/set", KEY_FUNC, elektraYamlSet, KEY_END), -#include ELEKTRA_README (yaml) - keyNew ("system/elektra/modules/yaml/infos/version", KEY_VALUE, PLUGINVERSION, KEY_END), KS_END); + ELEKTRA_LOG_DEBUG ("Retrieve plugin contract"); + KeySet * contract = contractYaml (); ksAppend (returned, contract); ksDel (contract);
Add a DYNAMIC_ARCH build on Neoverse using older gcc8
@@ -285,6 +285,25 @@ matrix: - gfortran script: - travis_wait 45 make && make lapack-test + env: + - TARGET_BOX=NEOVERSE_N1 + + - &test-neon1-gcc8 + os: linux + arch: arm64 + dist: focal + group: edge + virt: lxd + compiler: gcc + addons: + apt: + packages: + - gcc-8 + - gfortran-8 + script: + - travis_wait 45 make CC=gcc-8 FC=gfortran-8 DYNAMIC_ARCH=1 + env: + - TARGET_BOX=NEOVERSE_N1-GCC8 # whitelist branches:
Add some text highlights
@@ -117,7 +117,7 @@ for table in hlir16.tables: #[ table_entry_${table.name}_t* entry = (table_entry_${table.name}_t*)${lookupfun[table.match_type]}(tables[TABLE_${table.name}], (uint8_t*)key); #[ bool hit = entry != NULL && entry->is_entry_valid; - #[ dbg_bytes(key, hit ? ${table.key_length_bytes} : 0, "Lookup %s on table ${table.name}: action %s%s", hit ? "HIT" : "MISS", hit ? action_names[entry->action.action_id] : "default", hit ? ", data " : ""); + #[ debug("Lookup " T4ON "%s" T4OFF " on table " T4ON "${table.name}" T4OFF ": " T4ON "%s" T4OFF "\n", hit ? "HIT" : "MISS", hit ? action_names[entry->action.action_id] : "default"); #{ if (hit) { for smem in table.meters + table.counters:
fixed big endian issue in rariotap header
@@ -5272,11 +5272,6 @@ else if(linktype == DLT_IEEE802_11_RADIO) rth->it_len = byte_swap_16(rth->it_len); rth->it_present = byte_swap_32(rth->it_present); #endif - if(endianess == 1) - { - rth->it_len = byte_swap_16(rth->it_len); - rth->it_present = byte_swap_32(rth->it_present); - } if(rth->it_len > caplen) { pcapreaderrors++;
fix index out of range when map has no break
@@ -146,12 +146,13 @@ def main(): beatmap = read_file(beatmap_file, playfield_scale, skin.colours, hr) - print("Timing:", beatmap.timing_point[0]["Offset"]) replay_event, cur_time = setupReplay(replay_file, beatmap) start_index, end_index = findTime(start_time, end_time, replay_event, cur_time) endtime_fp = beatmap.hitobjects[-1]["time"] + 800 + beatmap.breakperiods.append({"Start": endtime_fp, "End": endtime_fp}) + beatmap.hitobjects.append({"x": 0, "y": 0, "time": endtime_fp, "end time": endtime_fp, "combo_number": 0, "type": ["end"]}) # to avoid index out of range resultinfo = checkmain(beatmap, replay_info, replay_event, cur_time)
changed error msg in function that calls dcmp_compare_data
@@ -749,7 +749,7 @@ static void dcmp_strmap_compare_data( * they could be the same, but we'll draw attention to them this way */ rc = 1; MFU_LOG(MFU_LOG_ERR, - "Failed to read. Asumming contents are different."); + "Failed to open, lseek, or read. Asumming contents are different."); /* consider this to be a fatal error if syncing */ if (mfu_copy_opts->do_sync) {
differentiate +pfix and +sfix
:: ++ pfix :: discard first rule ~/ %pfix + |* sam=* + %. sam (comp |*({a/* b/*} b)) :: ++ plug :: first then second :: ++ sfix :: discard second rule ~/ %sfix + |* sam=* + %. sam (comp |*({a/* b/*} a)) :: :::: 4f: parsing (rule builders)
shell_recorder: mention TEST_README
@@ -44,7 +44,10 @@ comment `# STDERR:`. ## Add a test -To add a Markdown Shell Recorder test for a certain Markdown file, use the CMake function `add_msr_test`: +If you want to add a Markdown Shell Recorder tests for the README.md of your plugin, you can simply pass +`TEST_README` as argument to `add_plugin`. + +To add other Markdown Shell Recorder tests for a certain Markdown file (such as an tutorial), use the CMake function `add_msr_test`: ``` add_msr_test (name file)
Fix aliasing problem.
@@ -686,7 +686,7 @@ get_next(index_iterator_t *iterator) uint8_t next_free_slot; heap = (heap_t *)iterator->index->opaque_data; - key = *(maxheap_key_t *)&iterator->min_value; + key = VALUE_INT(&iterator->min_value); if(cache.index_iterator != iterator || iterator->next_item_no == 0) { /* Initialize the cache for a new search. */
VERSION bump to version 1.3.47
@@ -31,7 +31,7 @@ endif() # micro version is changed with a set of small changes or bugfixes anywhere in the project. set(SYSREPO_MAJOR_VERSION 1) set(SYSREPO_MINOR_VERSION 3) -set(SYSREPO_MICRO_VERSION 46) +set(SYSREPO_MICRO_VERSION 47) set(SYSREPO_VERSION ${SYSREPO_MAJOR_VERSION}.${SYSREPO_MINOR_VERSION}.${SYSREPO_MICRO_VERSION}) # Version of the library
v2.0.11 landed
-ejdb2 (2.0.11) UNRELEASED; urgency=medium +ejdb2 (2.0.11) testing; urgency=medium * Upgraded to iowow_1.3.15 with critical fixes - -- Anton Adamansky <[email protected]> Wed, 01 May 2019 23:31:45 +0700 + -- Anton Adamansky <[email protected]> Wed, 01 May 2019 23:34:20 +0700 ejdb2 (2.0.10) testing; urgency=medium
build: change mbedtls cmake path
@@ -6,7 +6,7 @@ set(FLB_PATH_LIB_CHUNKIO "lib/chunkio") set(FLB_PATH_LIB_LUAJIT "lib/LuaJIT-2.1.0-beta3") set(FLB_PATH_LIB_MONKEY "lib/monkey") set(FLB_PATH_LIB_JSMN "lib/jsmn") -set(FLB_PATH_LIB_MBEDTLS "lib/mbedtls-2.16.1") +set(FLB_PATH_LIB_MBEDTLS "lib/mbedtls-2.16.3") set(FLB_PATH_LIB_SQLITE "lib/sqlite-amalgamation-3240000") set(FLB_PATH_LIB_ONIGMO "lib/onigmo") set(FLB_PATH_LIB_MPACK "lib/mpack-amalgamation-1.0")
Escape quotes with \042 oct code. Escape any chars over 0x7f the same
@@ -127,11 +127,6 @@ type VariablesLookup = { [name: string]: Variable | undefined }; // - Helpers -------------- -const delimiters = ['"', "'", "`", "|"].concat( - // Printable ascii characters from 0 to z - Array.from(Array(75)).map((_, a) => String.fromCharCode(a + 48)) -); - const getActorIndex = (actorId: string, scene: ScriptBuilderScene) => { return scene.actors.findIndex((a) => a.id === actorId) + 1; }; @@ -528,8 +523,22 @@ class ScriptBuilder { _string = (str: string) => { // .asciz can use any printable paired character as delimiter // try to match a character not already used in the string - const delimiter = delimiters.find((d) => str.indexOf(d) === -1); - this._addCmd(`.asciz ${delimiter}${str.replace(/\n/g, "\\n")}${delimiter}`); + const prepareString = (inStr: string) => { + let output = ""; + const nlStr = inStr.replace(/\n/g, "\\n"); + for (let i = 0; i < nlStr.length; i++) { + const code = nlStr.charCodeAt(i); + console.log(code); + if (code > 127 || code === 34) { + output += "\\" + (code & 0xff).toString(8).padStart(3, "0"); + } else { + output += String.fromCharCode(code); + } + } + return output; + }; + + this._addCmd(`.asciz "${prepareString(str)}"`); }; _importFarPtrData = (farPtr: string) => {
Case mismatch
@@ -176,7 +176,7 @@ char* gl4es_convertARB(const char* const code, int vertex, char **error_msg, int // Add a structure (for addresses) with only an 'x' component APPEND_OUTPUT("#version 120\n\nstruct _structOnlyX { int x; };\n\nvoid main() {\n", 61) if (hasFogFragCoord) { - APPEND_OUTPUT("\tvec4 gl4es_fogFragCoordTemp = vec4(gl_FogFragCoord);\n", 54) + APPEND_OUTPUT("\tvec4 gl4es_FogFragCoordTemp = vec4(gl_FogFragCoord);\n", 54) } } else { // No address @@ -248,7 +248,7 @@ char* gl4es_convertARB(const char* const code, int vertex, char **error_msg, int } if (hasFogFragCoord) { - APPEND_OUTPUT("\tgl_FogFragCoord = gl4es_fogFragCoordTemp.x;\n", 45) + APPEND_OUTPUT("\tgl_FogFragCoord = gl4es_FogFragCoordTemp.x;\n", 45) } APPEND_OUTPUT("}\n", 2) } while (0);
Fix cols/rows mixup in omatcopy 2nd step for BlasTrans cases Equivalent of (issue for the non-complex cases. Fixes
@@ -121,7 +121,7 @@ void CNAME( enum CBLAS_ORDER CORDER, enum CBLAS_TRANSPOSE CTRANS, blasint crows, return; } #ifdef NEW_IMATCOPY - if ( *lda == *ldb && *cols == *rows ) { + if ( *lda == *ldb && *rows == *cols) { if ( order == BlasColMajor ) { if ( trans == BlasNoTrans ) @@ -171,7 +171,7 @@ void CNAME( enum CBLAS_ORDER CORDER, enum CBLAS_TRANSPOSE CTRANS, blasint crows, else { OMATCOPY_K_CT(*rows, *cols, *alpha, a, *lda, b, *ldb ); - OMATCOPY_K_CN(*rows, *cols, (FLOAT) 1.0, b, *ldb, a, *ldb ); + OMATCOPY_K_CN(*cols, *rows, (FLOAT) 1.0, b, *ldb, a, *ldb ); } } else @@ -184,7 +184,7 @@ void CNAME( enum CBLAS_ORDER CORDER, enum CBLAS_TRANSPOSE CTRANS, blasint crows, else { OMATCOPY_K_RT(*rows, *cols, *alpha, a, *lda, b, *ldb ); - OMATCOPY_K_RN(*rows, *cols, (FLOAT) 1.0, b, *ldb, a, *ldb ); + OMATCOPY_K_RN(*cols, *rows, (FLOAT) 1.0, b, *ldb, a, *ldb ); } }
fix crash triggered in release mode with windows dynamic overriding
@@ -333,7 +333,9 @@ void mi_thread_init(void) mi_attr_noexcept pthread_setspecific(mi_pthread_key, (void*)(_mi_thread_id()|1)); // set to a dummy value so that `mi_pthread_done` is called #endif + #if (MI_DEBUG>0) // not in release mode as that leads to crashes on Windows dynamic override _mi_verbose_message("thread init: 0x%zx\n", _mi_thread_id()); + #endif } void mi_thread_done(void) mi_attr_noexcept { @@ -346,9 +348,11 @@ void mi_thread_done(void) mi_attr_noexcept { // abandon the thread local heap if (_mi_heap_done()) return; // returns true if already ran + #if (MI_DEBUG>0) if (!_mi_is_main_thread()) { _mi_verbose_message("thread done: 0x%zx\n", _mi_thread_id()); } + #endif }
[swig] fix 'code will never be executed' clang error.
@@ -483,7 +483,6 @@ struct IsDense : public Question<bool> { return SP_SiconosVector_from_numpy(vec, array_p, is_new_object); } - return SP::SiconosVector(); } SiconosVector* SiconosVector_in(PyObject* vec, PyArrayObject** array_p, int* is_new_object, std::vector<SP::SiconosVector>& keeper)
crash_test; list wdog2 option in cli help.
@@ -41,7 +41,7 @@ crash_cli_cmd(int argc, char **argv) if (argc >= 2 && crash_device(argv[1]) == 0) { return 0; } - console_printf("Usage crash [div0|jump0|ref0|assert|wdog]\n"); + console_printf("Usage crash [div0|jump0|ref0|assert|wdog|wdog2]\n"); return 0; }
tests: runtime: filter_kubernetes: validate merge key usage on unstructured message
@@ -323,6 +323,20 @@ void flb_test_apache_logs() kube_test_destroy(ctx); } +void flb_test_apache_logs_merge() +{ + struct kube_test *ctx; + + ctx = kube_test_create(T_APACHE_LOGS, KUBE_TAIL, + "Merge_Log", "On", + "Merge_Log_Key", "merge", + NULL); + if (!ctx) { + exit(EXIT_FAILURE); + } + kube_test_destroy(ctx); +} + void flb_test_apache_logs_annotated() { struct kube_test *ctx; @@ -415,6 +429,7 @@ void flb_test_systemd_logs() TEST_LIST = { {"kube_apache_logs", flb_test_apache_logs}, + {"kube_apache_logs_merge", flb_test_apache_logs_merge}, {"kube_apache_logs_annotated", flb_test_apache_logs_annotated}, {"kube_apache_logs_annotated_invalid", flb_test_apache_logs_annotated_invalid}, {"kube_apache_logs_annotated_merge_log", flb_test_apache_logs_annotated_merge},
vppinfra: Fix bihash coverity warning Type: fix Hitting a code not reachable when setting BIHASH_KVP_AT_BUCKET_LEVEL = 1
@@ -368,9 +368,9 @@ BV (clib_bihash_get_bucket) (BVT (clib_bihash) * h, u64 hash) offset = offset * (sizeof (BVT (clib_bihash_bucket)) + (BIHASH_KVP_PER_PAGE * sizeof (BVT (clib_bihash_kv)))); return ((BVT (clib_bihash_bucket) *) (((u8 *) h->buckets) + offset)); -#endif - +#else return h->buckets + (hash & (h->nbuckets - 1)); +#endif } static inline int BV (clib_bihash_search_inline_with_hash)
move ava & chai to dev deps
], "revision": "@GIT_REVISION@", "dependencies": { - "ava": "^2.1.0", - "chai": "^4.2.0", "extract-zip": "^1.6.7", "gauge": "^2.7.4", "request": "^2.88.0", "rimraf": "^2.6.3" }, "devDependencies": { - "@types/node": "^12.0.10" + "@types/node": "^12.0.10", + "ava": "^2.1.0", + "chai": "^4.2.0" }, "keywords": [ "ejdb",
avx: simplify some broadcast functions This uses set1 functions to implement broadcast functions which accept a pointer to a single value so we are able to better take advantage of fast set1 implementations (e.g., vdup_n on NEON).
@@ -1938,14 +1938,7 @@ simde_mm256_broadcast_sd (simde_float64 const * a) { #if defined(SIMDE_X86_AVX_NATIVE) return _mm256_broadcast_sd(a); #else - simde__m256d_private r_; - - SIMDE_VECTORIZE - for (size_t i = 0 ; i < (sizeof(r_.f64) / sizeof(r_.f64[0])) ; i++) { - r_.f64[i] = *a; - } - - return simde__m256d_from_private(r_); + return simde_mm256_set1_pd(*a); #endif } #if defined(SIMDE_X86_AVX_ENABLE_NATIVE_ALIASES) @@ -1959,14 +1952,7 @@ simde_mm_broadcast_ss (simde_float32 const * a) { #if defined(SIMDE_X86_AVX_NATIVE) return _mm_broadcast_ss(a); #else - simde__m128_private r_; - - SIMDE_VECTORIZE - for (size_t i = 0 ; i < (sizeof(r_.f32) / sizeof(r_.f32[0])) ; i++) { - r_.f32[i] = *a; - } - - return simde__m128_from_private(r_); + return simde_mm_set1_ps(*a); #endif } #if defined(SIMDE_X86_AVX_ENABLE_NATIVE_ALIASES) @@ -1980,14 +1966,7 @@ simde_mm256_broadcast_ss (simde_float32 const * a) { #if defined(SIMDE_X86_AVX_NATIVE) return _mm256_broadcast_ss(a); #else - simde__m256_private r_; - - SIMDE_VECTORIZE - for (size_t i = 0 ; i < (sizeof(r_.f32) / sizeof(r_.f32[0])) ; i++) { - r_.f32[i] = *a; - } - - return simde__m256_from_private(r_); + return simde_mm256_set1_ps(*a); #endif } #if defined(SIMDE_X86_AVX_ENABLE_NATIVE_ALIASES)
dockerfiles: add extra debug tools
@@ -194,7 +194,16 @@ RUN apt-get update && \ libatomic1 \ libgcrypt20 \ libyaml-0-2 \ + # build/code bash gdb valgrind build-essential \ + git bash-completion vim tmux jq \ + # network + dnsutils iputils-ping iputils-arping iputils-tracepath iputils-clockdiff \ + tcpdump curl nmap tcpflow iftop \ + net-tools mtr netcat-openbsd bridge-utils iperf ngrep \ + openssl \ + # processes/io + htop atop strace iotop sysstat ltrace ncdu logrotate hdparm pciutils psmisc tree pv \ && apt-get clean \ && rm -rf /var/lib/apt/lists/*
[mod_deflate] mark input bytes const
@@ -924,11 +924,12 @@ static int stream_deflate_init(handler_ctx *hctx) { return 0; } -static int stream_deflate_compress(handler_ctx * const hctx, unsigned char * const start, off_t st_size) { +static int stream_deflate_compress(handler_ctx * const hctx, const unsigned char * const start, off_t st_size) { z_stream * const z = &(hctx->u.z); size_t len; - z->next_in = start; + /*(unknown whether or not linked zlib was built with ZLIB_CONST defined)*/ + *((const unsigned char **)&z->next_in) = start; z->avail_in = st_size; hctx->bytes_in += st_size; @@ -1039,7 +1040,7 @@ static int stream_bzip2_init(handler_ctx *hctx) { return 0; } -static int stream_bzip2_compress(handler_ctx * const hctx, unsigned char * const start, off_t st_size) { +static int stream_bzip2_compress(handler_ctx * const hctx, const unsigned char * const start, off_t st_size) { bz_stream * const bz = &(hctx->u.bz); size_t len; @@ -1162,7 +1163,7 @@ static int stream_br_init(handler_ctx *hctx) { return 0; } -static int stream_br_compress(handler_ctx * const hctx, unsigned char * const start, off_t st_size) { +static int stream_br_compress(handler_ctx * const hctx, const unsigned char * const start, off_t st_size) { const uint8_t *in = (uint8_t *)start; BrotliEncoderState * const br = hctx->u.br; hctx->bytes_in += st_size; @@ -1250,7 +1251,7 @@ static int stream_zstd_init(handler_ctx *hctx) { return 0; } -static int stream_zstd_compress(handler_ctx * const hctx, unsigned char * const start, off_t st_size) { +static int stream_zstd_compress(handler_ctx * const hctx, const unsigned char * const start, off_t st_size) { ZSTD_CStream * const cctx = hctx->u.cctx; ZSTD_inBuffer zib = { start, (size_t)st_size, 0 }; ZSTD_outBuffer zob = { hctx->output->ptr, @@ -1335,7 +1336,7 @@ static int mod_deflate_stream_init(handler_ctx *hctx) { } } -static int mod_deflate_compress(handler_ctx * const hctx, unsigned char * const start, off_t st_size) { +static int mod_deflate_compress(handler_ctx * const hctx, const unsigned char * const start, off_t st_size) { if (0 == st_size) return 0; switch(hctx->compression_type) { #ifdef USE_ZLIB
core/host/timer.c: Format with clang-format BRANCH=none TEST=none
@@ -90,15 +90,12 @@ int timestamp_expired(timestamp_t deadline, const timestamp_t *now) void timer_init(void) { - if (!time_set) { /* * Start the timer just before the 64-bit rollover to try * and catch 32-bit rollover/truncation bugs. */ - timestamp_t ts = { - .val = 0xFFFFFFF0 - }; + timestamp_t ts = { .val = 0xFFFFFFF0 }; force_time(ts); }
OcAppleKernelLib: Fix return type BOOLEAN->EFI_STATUS.
@@ -393,7 +393,7 @@ InternalScanBuildLinkedVtables ( + (NumEntries * sizeof (*LinkedVtables->Entries)) ); if (LinkedVtables == NULL) { - return FALSE; + return EFI_OUT_OF_RESOURCES; } Result = InternalCreateVtablesPrelinked64 (
Bugfix favorites
@@ -66,16 +66,16 @@ AjaxFranceLabs.LikesAndFavoritesWidget = AjaxFranceLabs.SubClassResultWidget.ext .append('<div class="metadonne"><span class="liker">Like</span> <i class="fa fa-thumbs-up"></i><span class="likes">0</span></div>'); $(".doc_list > div").data("isLiked",false).data("isFavorite",false); $.each(docs,function(index,doc){ - if ($.inArray(docs[index].id,window.globalVariableLikes)!==-1){ + if ($.inArray(doc.id,window.globalVariableLikes)!==-1){ // the document is liked - $($('.doc_list > div')[index]).data("isLiked",true).find('.liker').text('Unlike'); + $(document.getElementById(doc.id)).data("isLiked",true).find('.liker').text('Unlike'); } if ($.inArray(docs[index].id,window.globalVariableFavorites)!==-1){ // the document is saved as favorite - $($('.doc_list > div')[index]).data("isFavorite",true).find('.favorite i').removeClass('fa-bookmark-o').addClass('fa-bookmark'); + $(document.getElementById(doc.id)).data("isFavorite",true).find('.favorite i').removeClass('fa-bookmark-o').addClass('fa-bookmark'); } // save the number of likes of a document gotten from Solr - $($('.doc_list > div')[index]).data('likes',doc.nbLikes).find('.likes').text(doc.nbLikes); + $(document.getElementById(doc.id)).data('likes',doc.nbLikes).find('.likes').text(doc.nbLikes); }); } $(".favorite").off("click").on("click",function(){
Make it two minimal calls
@@ -918,8 +918,8 @@ int hunt_memory_leak_test() { /* picoquic_init_openssl(); */ ERR_load_crypto_strings(); -#if 0 OpenSSL_add_all_algorithms(); +#if 0 #if !defined(LIBRESSL_VERSION_NUMBER) && OPENSSL_VERSION_NUMBER >= 0x30000000L /* OSSL_PROVIDER *dflt = */(void)OSSL_PROVIDER_load(NULL, "default"); #else @@ -944,8 +944,8 @@ int hunt_memory_leak_test() ENGINE_cleanup(); #endif #endif +endif EVP_cleanup(); -#endif ERR_free_strings(); return(0); }
svml: trivial style fix in preamble
* * Copyright: * 2020 Evan Nemerson <[email protected]> - 2020 Himanshi Mathur <[email protected]> + * 2020 Himanshi Mathur <[email protected]> */ #if !defined(SIMDE_X86_SVML_H)
Fix issue where some numeric data in banks was being stored as strings and getting compiled as zero because of bank mutation function
@@ -298,7 +298,12 @@ const compile = async ( return lo(stringPtrs[index].offset); } } - return 0; + const value = parseInt(data, 10); + if(!isNaN(value)) { + return value; + } + warnings(`Non numeric data found while processing banked data "${data}".`); + return data; }) let startSceneIndex = precompiled.sceneData.findIndex(
Remove updated callback
@@ -88,26 +88,12 @@ static bool le_param_req(struct bt_conn *conn, struct bt_le_conn_param *param) { return true; } -static void le_param_updated(struct bt_conn *conn, u16_t interval, - u16_t latency, u16_t timeout) { - static struct bt_conn_info info; - - bt_conn_get_info(conn, &info); - - if (info.role == BT_CONN_ROLE_MASTER && (interval != 6 || latency != 30)) { - bt_conn_le_param_update(conn, BT_LE_CONN_PARAM(0x0006, 0x0006, 30, 400)); - } - - LOG_DBG("Params updated: Interval: %d, Latency: %d", interval, latency); -}; - static struct bt_conn_cb conn_callbacks = { .connected = connected, .disconnected = disconnected, .security_changed = security_changed, #if !IS_ENABLED(CONFIG_ZMK_SPLIT_BLE_ROLE_PERIPHERAL) .le_param_req = le_param_req, - .le_param_updated = le_param_updated, #endif };
Netconn debug added
@@ -94,6 +94,7 @@ esp_cb(esp_cb_t* cb) { } } else if (esp_conn_is_server(conn) && listen_api) { /* Is the connection server type and we have known listening API? */ nc = esp_netconn_new(ESP_NETCONN_TYPE_TCP); /* Create new API */ + ESP_DEBUGW(ESP_DBG_NETCONN, nc == NULL, "NETCONN: Cannot create new structure for incoming server connection!\r\n"); if (nc) { nc->conn = conn; /* Set connection callback */ esp_conn_set_arg(conn, nc); /* Set argument for connection */ @@ -103,12 +104,14 @@ esp_cb(esp_cb_t* cb) { close = 1; } } else { + ESP_DEBUGF(ESP_DBG_NETCONN, "NETCONN: Invalid accept mbox\r\n"); close = 1; } } else { close = 1; } } else { + ESP_DEBUGW(ESP_DBG_NETCONN, nc == NULL, "NETCONN: Closing connection as there is no listening API in netconn!\r\n"); close = 1; /* Close the connection at this point */ } if (close) { @@ -250,6 +253,11 @@ esp_netconn_bind(esp_netconn_p nc, uint16_t port) { ESP_ASSERT("nc != NULL", nc != NULL); /* Assert input parameters */ + /** + * First try to enable server on user selected PORT + * and in case it is successful, + * set default callback for server in netconn mode + */ if ((res = esp_set_server(port, 1)) == espOK) { /* Enable server on selected port */ ESP_CORE_PROTECT(); esp_set_default_server_callback(esp_cb); /* Set callback function for server connections */ @@ -266,7 +274,7 @@ esp_netconn_bind(esp_netconn_p nc, uint16_t port) { espr_t esp_netconn_listen(esp_netconn_p nc) { ESP_ASSERT("nc != NULL", nc != NULL); /* Assert input parameters */ - ESP_ASSERT("nc->type must be TCP\r\n", nc->type != ESP_NETCONN_TYPE_TCP); /* Assert input parameters */ + ESP_ASSERT("nc->type must be TCP\r\n", nc->type == ESP_NETCONN_TYPE_TCP); /* Assert input parameters */ ESP_CORE_PROTECT(); listen_api = nc; /* Set current main API in listening state */ @@ -284,7 +292,7 @@ espr_t esp_netconn_accept(esp_netconn_p nc, esp_netconn_p* new_nc) { ESP_ASSERT("nc != NULL", nc != NULL); /* Assert input parameters */ ESP_ASSERT("new_nc != NULL", new_nc != NULL); /* Assert input parameters */ - ESP_ASSERT("nc->type must be TCP\r\n", nc->type != ESP_NETCONN_TYPE_TCP); /* Assert input parameters */ + ESP_ASSERT("nc->type must be TCP\r\n", nc->type == ESP_NETCONN_TYPE_TCP); /* Assert input parameters */ esp_netconn_t* tmp; uint32_t time;
VERSION bump to version 1.3.65
@@ -31,7 +31,7 @@ endif() # micro version is changed with a set of small changes or bugfixes anywhere in the project. set(SYSREPO_MAJOR_VERSION 1) set(SYSREPO_MINOR_VERSION 3) -set(SYSREPO_MICRO_VERSION 64) +set(SYSREPO_MICRO_VERSION 65) set(SYSREPO_VERSION ${SYSREPO_MAJOR_VERSION}.${SYSREPO_MINOR_VERSION}.${SYSREPO_MICRO_VERSION}) # Version of the library
docs: updated link to partition table docs
@@ -136,7 +136,7 @@ In ``native_ota_example``, ``$PROJECT_PATH/version.txt`` is used to define the a ### Error "ota_begin error err=0x104" -If you see this error, check that the configured (and actual) flash size is large enough for the partitions in the partition table. The default "two OTA slots" partition table requires at least 4MB flash size. To use OTA with smaller flash sizes, create a custom partition table CSV (for details see [components/partition_table](../../../compenents/partition_table)) and configure it in menuconfig. +If you see this error, check that the configured (and actual) flash size is large enough for the partitions in the partition table. The default "two OTA slots" partition table requires at least 4MB flash size. To use OTA with smaller flash sizes, create a custom partition table CSV (for details see [Partition Tables](https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/partition-tables.html)) and configure it in menuconfig. Make sure to run "idf.py erase_flash" after making changes to the partition table.
ci: fix typo: unconditionally
@@ -17,7 +17,7 @@ runs: steps: - name: Build the ${{ inputs.docker_image }} docker image shell: bash - # We run this unconditinally even if the change doesn't touch the + # We run this unconditionally even if the change doesn't touch the # relevant docker files because there is a chance that another PR (or # something else) rebuilt the local image. For example if the first # version of the PR included change for the relevant docker image but a
doc/opal-flash: fix typo Fixes: Suggested-by: Joel Nider
@@ -8,7 +8,7 @@ There are three OPAL calls for interacting with flash devices: :: #define OPAL_FLASH_ERASE 112 Multiple flash devices are supported by OPAL - each of these calls takes an id -parameter, which much match an ID found in the corresponding ``ibm,opal/flash@n`` +parameter, which must match an ID found in the corresponding ``ibm,opal/flash@n`` device tree node. See :ref:`device-tree/ibm,opal/flash` for details of the device tree bindings.
docket: show error msgs earlier during glob upload The error could mean that we don't have a valid `desk`. We want to show that message, instead of trying to `(~(got by charges) desk)`. Fixes
[[404^~ ~] [~ state]] :: =; [desk=@ta =glob err=(list @t)] + =* error-result + :_ [~ state] + [[400 ~] `(upload-page err)] + :: + ?. =(~ err) error-result + :: =* cha ~(. ch desk) =/ =charge (~(got by charges) desk) :: =? err !?=(%glob -.href.docket.charge) ['desk does not use glob' err] :: - ?. =(~ err) - :_ [~ state] - [[400 ~] `(upload-page err)] + ?. =(~ err) error-result :- [[200 ~] `(upload-page 'successfully globbed' ~)] ?> ?=(%glob -.href.docket.charge) ::
Add `Walker.exhaust`
@@ -35,11 +35,25 @@ class Walker { return [current, dirs, files]; } + // Convenience method to perform a full traversal. Be careful with this, as it can infinitely + // loop if there are cycles in the file system (e.g. with symbolic links), and consume a large + // amount of time and memory. + exhaust() { + var results = []; + while { + var x = this.next(); + if (!x) break; + results.push(x); + } + return results; + } } -// Traverse the file system starting from the current directory. Prune every directory named 'docs' +var dictuDir = Path.join(Path.dirname(__file__), '..'); + +// Traverse the file system starting from the project directory. Prune every directory named 'docs' // from the tree. -var walker = Walker('.', ['docs']); +var walker = Walker(dictuDir, ['docs']); while { var tmp = walker.next(); @@ -58,3 +72,7 @@ while { if (dirnames.contains(prune[j])) dirnames.remove(prune[j]); } + + +print('Example using `Walker.exhaust`:'); +print(Walker(Path.join(dictuDir, '.github'), []).exhaust());
Update header guards iphc.h + linter pass
-#ifndef __IPHC_H -#define __IPHC_H +#ifndef OPENWSN_IPHC_H +#define OPENWSN_IPHC_H /** \addtogroup LoWPAN @@ -308,9 +308,7 @@ void iphc_retrieveIPv6DeadlineHeader( deadline_option_ht* deadline_option ); -void iphc_getDeadlineInfo( - monitor_expiration_vars_t* stats -); +void iphc_getDeadlineInfo(monitor_expiration_vars_t* stats); #endif /** @@ -318,4 +316,4 @@ void iphc_getDeadlineInfo( \} */ -#endif +#endif /* OPENWSN_IPHC_H */
fix build rhodes as lib
@@ -80,10 +80,10 @@ ANDROID_CAPS_ALWAYS_ENABLED = ['network_state'] def set_app_icon_android - if $rhodes_as_lib - puts "Skip building copy resources (not needed for aar library)" - return - end + #if $rhodes_as_lib + # puts "Skip building copy resources (not needed for aar library)" + # return + #end res_path = File.join($app_path, 'resources', 'android', 'res') if File.exists? res_path
I updated build_visit for 2.12.3.
#5 bv_<module>_depends_on [not implemented yet], also may be removed in favor of xml structure #6. bv_<module>_build builds the module -export VISIT_VERSION=${VISIT_VERSION:-"2.12.2"} +export VISIT_VERSION=${VISIT_VERSION:-"2.12.3"} #### # Trunk:
spec: remove unreachable code
@@ -738,10 +738,6 @@ static int processSpecKey (Key * specKey, Key * parentKey, KeySet * ks, const Co { Key * newKey = keyNew (strchr (keyName (specKey), '/'), KEY_CASCADING_NAME, KEY_END); copyMeta (newKey, specKey); - if (!isKdbGet) - { - keySetMeta (newKey, "internal/spec/remove", ""); - } ksAppendKey (ks, newKey); } else if (keyGetMeta (specKey, "default") != NULL) @@ -749,10 +745,6 @@ static int processSpecKey (Key * specKey, Key * parentKey, KeySet * ks, const Co Key * newKey = keyNew (strchr (keyName (specKey), '/'), KEY_CASCADING_NAME, KEY_VALUE, keyString (keyGetMeta (specKey, "default")), KEY_END); copyMeta (newKey, specKey); - if (!isKdbGet) - { - keySetMeta (newKey, "internal/spec/remove", ""); - } ksAppendKey (ks, newKey); } }
sdcard_image-rpi.bbclass: Fix when RPI_SDIMG_EXTRA_DEPENDS not defined If the variable is not defined, bitbake will fail: [...] Task 'depends' should be specified in the form 'packagename:task' [...] This is because not expanding the variable leaves an invalid entry.
@@ -49,6 +49,8 @@ SDIMG_ROOTFS = "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${SDIMG_ROOTFS_TYPE}" # For the names of kernel artifacts inherit kernel-artifact-names +RPI_SDIMG_EXTRA_DEPENDS ?= "" + do_image_rpi_sdimg[depends] = " \ parted-native:do_populate_sysroot \ mtools-native:do_populate_sysroot \
Preserve current verbosity behavior before merge w/master.
@@ -139,36 +139,36 @@ setVerbosity(rtconfig* c, unsigned verbosity) summarize->net.error = 1; summarize->net.dnserror = 1; } else if (verbosity == 13) { - summarize->fs.open_close = 0; - summarize->fs.read_write = 0; - summarize->fs.seek = 0; - summarize->fs.stat = 0; - summarize->fs.error = 1; - summarize->net.open_close = 0; - summarize->net.rx_tx = 0; - summarize->net.dns = 0; - summarize->net.error = 0; - summarize->net.dnserror = 0; - } else if (verbosity == 14) { - summarize->fs.open_close = 0; - summarize->fs.read_write = 0; - summarize->fs.seek = 0; - summarize->fs.stat = 0; + summarize->fs.open_close = 1; + summarize->fs.read_write = 1; + summarize->fs.seek = 1; + summarize->fs.stat = 1; summarize->fs.error = 0; - summarize->net.open_close = 0; - summarize->net.rx_tx = 0; - summarize->net.dns = 0; + summarize->net.open_close = 1; + summarize->net.rx_tx = 1; + summarize->net.dns = 1; summarize->net.error = 1; summarize->net.dnserror = 1; + } else if (verbosity == 14) { + summarize->fs.open_close = 1; + summarize->fs.read_write = 1; + summarize->fs.seek = 1; + summarize->fs.stat = 1; + summarize->fs.error = 1; + summarize->net.open_close = 1; + summarize->net.rx_tx = 1; + summarize->net.dns = 1; + summarize->net.error = 0; + summarize->net.dnserror = 0; } else if (verbosity == 15) { - summarize->fs.open_close = 0; - summarize->fs.read_write = 0; - summarize->fs.seek = 0; - summarize->fs.stat = 0; + summarize->fs.open_close = 1; + summarize->fs.read_write = 1; + summarize->fs.seek = 1; + summarize->fs.stat = 1; summarize->fs.error = 0; - summarize->net.open_close = 0; - summarize->net.rx_tx = 0; - summarize->net.dns = 0; + summarize->net.open_close = 1; + summarize->net.rx_tx = 1; + summarize->net.dns = 1; summarize->net.error = 0; summarize->net.dnserror = 0; }
CMake: rename target `doc` -> `ZydisDoc` Both the documentation target in zycore and zydis were previously called "doc" which caused a CMake error in zydis complaining about the same name being used twice.
@@ -457,7 +457,7 @@ if (DOXYGEN_FOUND) set(DOXYGEN_WARN_IF_UNDOCUMENTED NO) set(DOXYGEN_HTML_EXTRA_STYLESHEET "${DOXYGEN_AWESOME_CSS}" "${DOXYGEN_AWESOME_SIDEBAR_ONLY_CSS}") - doxygen_add_docs(doc ${DOC_PATHS} ALL) + doxygen_add_docs(ZydisDoc ${DOC_PATHS} ALL) install( DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/html/"
link-store: always mark our own submission as seen
=. by-group (~(put by by-group) path links) :: do generic submission logic :: - =^ cards state + =^ submission-cards state (hear-submission path [our.bowl page]) + :: mark page as seen (because we submitted it ourselves) + :: + =^ seen-cards state + (seen-submission path `url) :: send updates to subscribers :: :_ state - :_ cards + :_ (weld submission-cards seen-cards) :+ %give %fact :+ :~ /local-pages [%local-pages path]
Make comment in fmgr.h match the one in fmgr.c. Incompletely quoting an API spec does nobody any good. Noted by Paul Jungwirth. Looks like the discrepancy was my fault originally :-( Discussion:
@@ -489,7 +489,8 @@ extern int no_such_variable /* These are for invocation of a specifically named function with a * directly-computed parameter list. Note that neither arguments nor result - * are allowed to be NULL. + * are allowed to be NULL. Also, the function cannot be one that needs to + * look at FmgrInfo, since there won't be any. */ extern Datum DirectFunctionCall1Coll(PGFunction func, Oid collation, Datum arg1);
Fix memleak of public_key_out When s2n_x509_validator_validate_cert_chain fails after pulling public_key_out, it previously leaked memory.
@@ -234,6 +234,9 @@ s2n_cert_validation_code s2n_x509_validator_validate_cert_chain(struct s2n_x509_ s2n_cert_validation_code err_code = S2N_CERT_ERR_INVALID; X509 *server_cert = NULL; + struct s2n_pkey public_key; + s2n_pkey_zero_init(&public_key); + while (s2n_stuffer_data_available(&cert_chain_in_stuffer) && certificate_count < validator->max_chain_depth) { uint32_t certificate_size = 0; @@ -271,7 +274,7 @@ s2n_cert_validation_code s2n_x509_validator_validate_cert_chain(struct s2n_x509_ /* Pull the public key from the first certificate */ if (certificate_count == 0) { /* Assume that the asn1cert is an RSA Cert */ - if (s2n_asn1der_to_public_key(public_key_out, &asn1cert) < 0) { + if (s2n_asn1der_to_public_key(&public_key, &asn1cert) < 0) { goto clean_up; } *cert_type = S2N_CERT_TYPE_RSA_SIGN; @@ -333,6 +336,7 @@ s2n_cert_validation_code s2n_x509_validator_validate_cert_chain(struct s2n_x509_ } + *public_key_out = public_key; err_code = S2N_CERT_OK; clean_up: @@ -340,6 +344,10 @@ clean_up: X509_STORE_CTX_cleanup(ctx); } + if (err_code != S2N_CERT_OK) { + s2n_pkey_free(&public_key); + } + s2n_stuffer_free(&cert_chain_in_stuffer); return err_code; }
[CUDA] Unregister memory for CL_MEM_USE_HOST_PTR buffer
@@ -351,6 +351,11 @@ pocl_cuda_free (cl_device_id device, cl_mem mem_obj) cuMemFreeHost (mem_obj->mem_host_ptr); mem_obj->mem_host_ptr = NULL; } + else if (mem_obj->flags & CL_MEM_USE_HOST_PTR) + { + cuMemHostUnregister (mem_obj->mem_host_ptr); + mem_obj->mem_host_ptr = NULL; + } else { void *ptr = mem_obj->device_ptrs[device->dev_id].mem_ptr;
Probably better like this
@@ -345,7 +345,7 @@ static bool releaseSprite(Sprite* sprite) return FALSE; } -#if LIB_DEBUG +#if (LIB_LOG_LEVEL >= LOG_LEVEL_ERROR) static bool isSpriteValid(Sprite* sprite) { return sprite->status & ALLOCATED;
Add arccos md functions
@@ -2970,6 +2970,28 @@ float md_asum2(unsigned int D, const long dims[D], const long strs[D], const flo } +/** + * Calculate arccos of real part. + * + */ +void md_zacos2(unsigned int D, const long dims[D], const long ostr[D], complex float* optr, + const long istr[D], const complex float* iptr) +{ + MAKE_Z2OP(zacos, D, dims, ostr, optr, istr, iptr); +} + + + +/** + * Calculate arccos of real part. + * + */ +void md_zacos(unsigned int D, const long dims[D], complex float* optr, const complex float* iptr) +{ + make_z2op_simple(md_zacos2, D, dims, optr, iptr); +} + + /** * Calculate sum of absolute values.
Allow wrap around on u64. This lets some math work as expected.
@@ -134,7 +134,7 @@ int64_t janet_unwrap_s64(Janet x) { break; } } - janet_panic("bad s64 initializer"); + janet_panicf("bad s64 initializer: %t", x); return 0; } @@ -144,7 +144,9 @@ uint64_t janet_unwrap_u64(Janet x) { break; case JANET_NUMBER : { double dbl = janet_unwrap_number(x); - if ((dbl >= 0) && (dbl <= MAX_INT_IN_DBL)) + /* Allow negative values to be cast to "wrap around". + * This let's addition and subtraction work as expected. */ + if (fabs(dbl) <= MAX_INT_IN_DBL) return (uint64_t)dbl; break; } @@ -163,7 +165,7 @@ uint64_t janet_unwrap_u64(Janet x) { break; } } - janet_panic("bad u64 initializer"); + janet_panicf("bad u64 initializer: %t", x); return 0; } @@ -197,15 +199,14 @@ static Janet cfun_it_u64_new(int32_t argc, Janet *argv) { return janet_wrap_u64(janet_unwrap_u64(argv[0])); } -// Code to support polymorphic comparison. -// -// int/u64 and int/s64 support a "compare" method that allows -// comparison to each other, and to Janet numbers, using the -// "compare" "compare<" ... functions. -// -// In the following code explicit casts are sometimes used to help -// make it clear when int/float conversions are happening. -// +/* + * Code to support polymorphic comparison. + * int/u64 and int/s64 support a "compare" method that allows + * comparison to each other, and to Janet numbers, using the + * "compare" "compare<" ... functions. + * In the following code explicit casts are sometimes used to help + * make it clear when int/float conversions are happening. + */ static int compare_double_double(double x, double y) { return (x < y) ? -1 : ((x > y) ? 1 : 0); } @@ -242,7 +243,6 @@ static int compare_uint64_double(uint64_t x, double y) { } } - static Janet cfun_it_s64_compare(int32_t argc, Janet *argv) { janet_fixarity(argc, 2); if (janet_is_int(argv[0]) != JANET_INT_S64)
Fix the problem of stm32f746-st-nucleo that env cannot be configured with menuconfig
@@ -242,7 +242,7 @@ menu "On-chip Peripheral Drivers" int "USB PULL UP STATUS" default 0 endif - source "libraries/HAL_Drivers/Kconfig" + source "../libraries/HAL_Drivers/Kconfig" endmenu