message
stringlengths 6
474
| diff
stringlengths 8
5.22k
|
---|---|
Fixed %app speeches to look identical to the way they do in old talk. | ::> renders just the most important data of the
::> message. if possible, these stay within a single
::> line.
+ ::TODO this should probably be redone someday.
::
- ::> pre: line prefix
- =| pre/(unit tape)
+ ::> pre: replace/append line prefix
+ =| pre/(unit (pair ? tape))
|= wyd/@ud
^- (list tape)
?- -.sep
~(ram re (snag 0 `(list tank)`res.sep))
::
$ire
- $(sep sep.sep, pre `"^ ")
+ $(sep sep.sep, pre `[| "^ "])
::
$url
:_ ~
=+ ful=(apix:en-purl:html url.sep)
- =+ pef=(fall pre "")
+ =+ pef=q:(fall pre [p=| q=""])
:: clean up prefix if needed.
=? pef =((scag 1 (flop pef)) " ")
(scag (dec (lent pef)) pef)
$lin
:: glyph prefix
=/ pef/tape
+ ?: &(?=(^ pre) p.u.pre) q.u.pre
?: pat.sep " "
- =- (weld - (fall pre " "))
+ =- (weld - q:(fall pre [p=| q=" "]))
%~ ar-glyf ar
?: =(who our.bol) aud
(~(del in aud) [who %inbox])
~(cr-phat cr cir.sep)
::
$app
- $(sep sep.sep, pre `"[{(trip app.sep)}]:")
+ $(sep sep.sep, pre `[& "[{(trip app.sep)}]: "])
==
--
::
|
Fix recursive post-deps. | @@ -757,7 +757,7 @@ int main(int argc, const char **argv) {
(os/execute [(git-path) "reset" "--hard" tag] :p))
(unless (dyn :offline)
(os/execute [(git-path) "submodule" "update" "--init" "--recursive"] :p))
- (import-rules "./project.janet")
+ (import-rules "./project.janet" true)
(unless no-deps (do-rule "install-deps"))
(do-rule "build")
(do-rule "install"))
@@ -1182,7 +1182,7 @@ Flags are:
(defn list-rules
[&opt ctx]
- (import-rules "./project.janet" true)
+ (import-rules "./project.janet")
(def ks (sort (seq [k :keys (dyn :rules)] k)))
(each k ks (print k)))
|
move snap_example_set to snap_maint to prevent unwritten addresses with all actions | step "$SNAP_ROOT/software/tools/snap_maint -m1 -c1 -vvv"
t="$SNAP_ROOT/software/tools/snap_peek 0x18 "; r=$($t|grep ']'|awk '{print $2}');echo -e "$t result=$r # statusreg 0x100=exploration done 1action, 0x111=2action"
fi
+ if (( dram > 0 ));then echo -e "write FPGA memory to prevent reading unwritten adr 0"
+ step "$ACTION_ROOT/sw/snap_example_set -F -b0x0 -s0x100 -p0x5 -t50"
+ fi
fi
if (( numact > 0 ));then
t="$SNAP_ROOT/software/tools/snap_peek 0x100 "; r=$($t|grep ']'|awk '{print $2}');echo -e "$t result=$r # action0 type 0.0.0.shrt.4B_long"
t0s=${r:7:1};t0l=${r:8:8};
case $t0l in
- "10140000") a0="hdl_example"
-# if [[ "$SDRAM_USED" == "TRUE" ]];then echo -e "write FPGA memory to prevent reading unwritten adr 0"
- if (( dram > 0 ));then echo -e "write FPGA memory to prevent reading unwritten adr 0"
-# step "$ACTION_ROOT/sw/snap_example_set -h"
- step "$ACTION_ROOT/sw/snap_example_set -F -b0x0 -s0x100 -p0x5 -t50"
- fi
- ;;
+ "10140000") a0="hdl_example";;
"10141000") a0="hls_memcopy";;
"10141001") a0="hls_sponge";;
"10141002") a0="hls_hashjoin";;
|
OcConfigurationLib: Fix Booter patcher Identifier to be Any for failsafe | _(UINT32 , Count , , 0 , () ) \
_(BOOLEAN , Enabled , , FALSE , () ) \
_(OC_DATA , Find , , OC_EDATA_CONSTR (_, __) , OC_DESTR (OC_DATA) ) \
- _(OC_STRING , Identifier , , OC_STRING_CONSTR ("", _, __), OC_DESTR (OC_STRING) ) \
+ _(OC_STRING , Identifier , , OC_STRING_CONSTR ("Any", _, __), OC_DESTR (OC_STRING) ) \
_(OC_DATA , Mask , , OC_EDATA_CONSTR (_, __) , OC_DESTR (OC_DATA) ) \
_(OC_DATA , Replace , , OC_EDATA_CONSTR (_, __) , OC_DESTR (OC_DATA) ) \
_(OC_DATA , ReplaceMask , , OC_EDATA_CONSTR (_, __) , OC_DESTR (OC_DATA) ) \
|
LICENSE: add license for wapi
document the license in the LICENSE file | @@ -1643,3 +1643,48 @@ apps/include/gpsutils/minmea.h
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
+
+apps/include/wireless/wapi.h
+=============================
+
+ Copyright (C) 2017, 2019 Gregory Nutt. All rights reserved.
+
+ Adapted for NuttX from WAPI:
+
+ Copyright (c) 2010, Volkan YAZICI <[email protected]>
+ All rights reserved.
+
+ And includes WPA supplicant logic contributed by:
+
+ Author: Simon Piriou <[email protected]>
+
+ Which was adapted to NuttX from driver_ext.h
+
+ Copyright (c) 2003-2005, Jouni Malinen <[email protected]>
+
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions
+ are met:
+
+ 1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in
+ the documentation and/or other materials provided with the
+ distribution.
+ 3. Neither the name NuttX nor the names of its contributors may be
+ used to endorse or promote products derived from this software
+ without specific prior written permission.
+
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
+ FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
+ COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+ BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
+ AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
+ ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ POSSIBILITY OF SUCH DAMAGE.
|
CLEANUP: Fix compile error of kv mget operation. | @@ -496,7 +496,11 @@ struct conn {
void *coll_eitem;
char *coll_resps;
int coll_ecount;
+#ifdef SUPPORT_KV_MGET
+ int coll_op;
+#else
ENGINE_COLL_OPERATION coll_op;
+#endif
char *coll_key;
int coll_nkey;
int coll_index; /* the list index of lop insert */
|
Fixed some typos in the f08 interface and added standardize_cell to the available functions | @@ -317,7 +317,7 @@ module spglib_f08
integer(c_int), intent(in), value :: num_atom
integer(c_int), intent(in), value :: to_primitive, no_idealize
real(c_double), intent(in), value :: symprec
- integer(c_int) :: spg_refine_cell
+ integer(c_int) :: spg_standardize_cell
end function spg_standardize_cell
@@ -329,7 +329,7 @@ module spglib_f08
integer(c_int), intent(in), value :: num_atom
integer(c_int), intent(in), value :: to_primitive, no_idealize
real(c_double), intent(in), value :: symprec, angle_tolerance
- integer(c_int) :: spgat_refine_cell
+ integer(c_int) :: spgat_standardize_cell
end function spgat_standardize_cell
@@ -384,6 +384,7 @@ module spglib_f08
& spg_get_international, spgat_get_international, &
& spg_get_schoenflies, spgat_get_schoenflies, &
& spg_get_pointgroup, spg_refine_cell, spgat_refine_cell, &
+ & spg_standardize_cell, spgat_standardize_cell, &
& spg_get_ir_reciprocal_mesh, &
& spg_get_stabilized_reciprocal_mesh, &
& spg_get_error_code, spg_get_error_message, &
|
Adding api compilation unit; must have gotten dropped in a merge | @@ -32,7 +32,7 @@ endif
SBA:=redist/sba/sba_chkjac.c redist/sba/sba_crsm.c redist/sba/sba_lapack.c redist/sba/sba_levmar.c redist/sba/sba_levmar_wrap.c redist/minimal_opencv.c src/poser_epnp.c src/poser_sba.c src/epnp/epnp.c src/poser_general_optimizer.c
-LIBSURVIVE_CORE+=src/survive.c src/survive_process.c src/ootx_decoder.c src/survive_driverman.c src/survive_default_devices.c src/survive_playback.c src/survive_config.c src/survive_cal.c src/poser.c src/survive_sensor_activations.c src/survive_disambiguator.c src/survive_imu.c src/survive_kalman.c
+LIBSURVIVE_CORE+=src/survive.c src/survive_process.c src/ootx_decoder.c src/survive_driverman.c src/survive_default_devices.c src/survive_playback.c src/survive_config.c src/survive_cal.c src/poser.c src/survive_sensor_activations.c src/survive_disambiguator.c src/survive_imu.c src/survive_kalman.c src/survive_api.c
MINIMAL_NEEDED+=src/survive_usb.c src/survive_charlesbiguator.c src/survive_vive.c src/survive_reproject.c
AUX_NEEDED+=src/survive_turveybiguator.c src/survive_statebased_disambiguator.c src/survive_driver_dummy.c src/survive_driver_udp.c
POSERS:=src/poser_dummy.c src/poser_imu.c src/poser_charlesrefine.c
|
apps/testbench: Support multiple BLE connections | @@ -184,10 +184,9 @@ tbb_gap_event(struct ble_gap_event *event, void *arg)
}
MODLOG_DFLT(INFO, "\n");
- if (event->connect.status != 0) {
- /* Connection failed; resume advertising. */
+ /* Try to advertise again. */
tbb_advertise();
- }
+
return 0;
case BLE_GAP_EVENT_DISCONNECT:
|
OpenCorePlatform: Sanitize definitions across libs | @@ -325,6 +325,12 @@ OcPlatformUpdateSmbios (
Data.FirmwareFeatures = MacInfo->Smbios.FirmwareFeatures;
Data.FirmwareFeaturesMask = MacInfo->Smbios.FirmwareFeaturesMask;
Data.ProcessorType = NULL;
+
+ OC_INLINE_STATIC_ASSERT (
+ MAC_INFO_PLATFORM_FEATURE_MISSING == PLATFORM_FEATURE_MISSING,
+ "MacInfoPkg and OcSupportPkg have inconsistent data!"
+ );
+
Data.PlatformFeature = MacInfo->Smbios.PlatformFeature;
}
|
saddr should be addrlen bytes
Not sizeof saddr. | @@ -402,7 +402,7 @@ addrretry:
if (c->saddr) {
free(c->saddr);
}
- c->saddr = malloc(sizeof(*p->ai_addr));
+ c->saddr = malloc(p->ai_addrlen);
memcpy(c->saddr, p->ai_addr, p->ai_addrlen);
c->addrlen = p->ai_addrlen;
|
fix test_tool peerdir for go tests | @@ -3572,6 +3572,10 @@ module GO_TEST: GO_PROGRAM {
PEERDIR(${GOSTD}/testing)
ADD_YTEST($REALPRJNAME go.test)
+
+ when ($TESTS_REQUESTED && $NEED_PLATFORM_PEERDIRS == "yes") {
+ PEERDIR+=build/platform/test_tool
+ }
}
JAVA_IGNORE_CLASSPATH_CLASH_VALUE=
|
Work CI-CD
Add tag to code style comments to allow nfbot to remove them after the branches are merged.
***NO_CI*** | @@ -130,7 +130,8 @@ steps:
'OK' | Write-Host -ForegroundColor Green
# PR submitted, add a comment
- $codeStyleFixesComment = @{body="@$($pr.user.login) there are issues with the code style on the source files.`nA PR was submitted with the code style fixes. Please click $($result.html_url), review the changes if you want and merge it.`n`nMake sure to follow the project code style. Check the details [here](https://docs.nanoframework.net/content/contributing/cxx-coding-style.html) on how it works and the tools required to help you with that."} | ConvertTo-Json
+ # include TAG comment that allows github nfbot to remove it after branch is merged
+ $codeStyleFixesComment = @{body="@$($pr.user.login) there are issues with the code style on the source files.`nA PR was submitted with the code style fixes. Please click $($result.html_url), review the changes if you want and merge it.`n`nMake sure to follow the project code style. Check the details [here](https://docs.nanoframework.net/content/contributing/cxx-coding-style.html) on how it works and the tools required to help you with that.`n`n<!-- nfbot fix request DO NOT REMOVE -->"} | ConvertTo-Json
Invoke-RestMethod -Method Post -UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::InternetExplorer -Uri $($pr.comments_url) -Header @{"Authorization"="$auth"} -ContentType "application/json" -Body $codeStyleFixesComment
}
catch
@@ -147,7 +148,8 @@ steps:
# most likely this is a permissions issue because the base repo is read only or protected
# report to user
- $codeStyleFixesComment = @{body="@$($pr.user.login) there are issues with the code style on the source files.`n`n:warning:Couldn't submit a PR with the fixes against your repo.:warning:`n`nPlease merge the changes from https://github.com/$env:Build_Repository_Name/tree/$branchName."} | ConvertTo-Json
+ # include TAG comment that allows github nfbot to remove it after branch is merged
+ $codeStyleFixesComment = @{body="@$($pr.user.login) there are issues with the code style on the source files.`n`n:warning:Couldn't submit a PR with the fixes against your repo.:warning:`n`nPlease merge the changes from https://github.com/$env:Build_Repository_Name/tree/$branchName.`n`n<!-- nfbot fix request DO NOT REMOVE -->"} | ConvertTo-Json
$result = Invoke-RestMethod -Method Post -UserAgent [Microsoft.PowerShell.Commands.PSUserAgent]::InternetExplorer -Uri $($pr.comments_url) -Header @{"Authorization"="$auth"} -ContentType "application/json" -Body $codeStyleFixesComment
throw "Error starting PR: $responseBody"
|
Updated linking of library with test | @@ -25,7 +25,7 @@ add_celix_bundle(bundle_with_exception SOURCES src/nop_activator.c VERSION 1.0.0
add_subdirectory(subdir) #simple_test_bundle4, simple_test_bundle5 and sublib
add_celix_bundle(unresolveable_bundle SOURCES src/nop_activator.c VERSION 1.0.0)
-target_link_libraries(unresolveable_bundle PRIVATE "-L${CMAKE_CURRENT_BINARY_DIR}/subdir -lsublib")
+target_link_libraries(unresolveable_bundle PRIVATE sublib)
if(NOT APPLE)
set_target_properties(unresolveable_bundle PROPERTIES LINK_FLAGS -Wl,--no-as-needed)
endif()
|
hv: nested: redundant permission check on nested_vmentry()
check_vmx_permission() is called in vmresume_vmexit_handler() and
vmlaunch_vmexit_handler() already. | @@ -1409,7 +1409,6 @@ static void nested_vmentry(struct acrn_vcpu *vcpu, bool is_launch)
{
struct acrn_vmcs12 *vmcs12 = &vcpu->arch.nested.vmcs12;
- if (check_vmx_permission(vcpu)) {
if (vcpu->arch.nested.current_vmcs12_ptr == INVALID_GPA) {
nested_vmx_result(VMfailInvalid, 0);
} else if (is_launch && (vmcs12->launch_state != VMCS12_LAUNCH_STATE_CLEAR)) {
@@ -1456,7 +1455,6 @@ static void nested_vmentry(struct acrn_vcpu *vcpu, bool is_launch)
vcpu->launched = false;
}
}
-}
/*
* @pre vcpu != NULL
|
Bump version 1.6.6 | @@ -31,7 +31,7 @@ APP_LOAD_PARAMS += --path "45'"
APPVERSION_M=1
APPVERSION_N=6
APPVERSION_P=6
-APPVERSION=$(APPVERSION_M).$(APPVERSION_N).$(APPVERSION_P)-dvf2
+APPVERSION=$(APPVERSION_M).$(APPVERSION_N).$(APPVERSION_P)
APP_LOAD_FLAGS= --appFlags 0x240 --dep Ethereum:$(APPVERSION)
ifeq ($(CHAIN),)
|
fixed action frame payloadptr | @@ -2942,7 +2942,7 @@ static inline void process80211action()
static actf_t *actf;
if(payloadlen < ACTIONFRAME_SIZE) return;
-actf = (actf_t*)packetptr;
+actf = (actf_t*)payloadptr;
if(actf->categoriecode == CAT_VENDOR)
{
if(fd_pcapng > 0)
|
bq27z561: Fix buffer overrun
Each write is prefaced by a three byte header (checksum ID, checksum,
length). We were only allocating two extra bytes.
The fix is to allocate three extra bytes instead. | @@ -590,7 +590,7 @@ err:
bq27z561_err_t
bq27z561_wr_flash(struct bq27z561 *dev, uint16_t addr, uint8_t *buf, int buflen)
{
- uint8_t tmpbuf[BQ27Z561_MAX_FLASH_RW_LEN + 2];
+ uint8_t tmpbuf[BQ27Z561_MAX_FLASH_RW_LEN + 3];
uint8_t chksum;
bq27z561_err_t ret;
int rc;
|
stm32/mboot: Add support for 4th board LED. | @@ -280,11 +280,17 @@ void mp_hal_pin_config_speed(uint32_t port_pin, uint32_t speed) {
#define LED0 MICROPY_HW_LED1
#define LED1 MICROPY_HW_LED2
#define LED2 MICROPY_HW_LED3
+#ifdef MICROPY_HW_LED4
+#define LED3 MICROPY_HW_LED4
+#endif
void led_init(void) {
mp_hal_pin_output(LED0);
mp_hal_pin_output(LED1);
mp_hal_pin_output(LED2);
+ #ifdef LED3
+ mp_hal_pin_output(LED3);
+ #endif
}
void led_state(int led, int val) {
@@ -302,6 +308,9 @@ void led_state_all(unsigned int mask) {
led_state(LED0, mask & 1);
led_state(LED1, mask & 2);
led_state(LED2, mask & 4);
+ #ifdef LED3
+ led_state(LED3, mask & 8);
+ #endif
}
/******************************************************************************/
@@ -1089,7 +1098,11 @@ static int pyb_usbdd_shutdown(void) {
#define RESET_MODE_NUM_STATES (4)
#define RESET_MODE_TIMEOUT_CYCLES (8)
+#ifdef LED3
+#define RESET_MODE_LED_STATES 0x8421
+#else
#define RESET_MODE_LED_STATES 0x7421
+#endif
static int get_reset_mode(void) {
usrbtn_init();
|
Add custom print if echo is disabled | @@ -55,6 +55,18 @@ static size_t
send_data(const void* data, size_t len) {
DWORD written;
if (com_port != NULL) {
+#if !ESP_CFG_AT_ECHO
+ const uint8_t* d = data;
+ HANDLE hConsole;
+
+ hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
+ SetConsoleTextAttribute(hConsole, FOREGROUND_RED);
+ for (DWORD i = 0; i < len; i++) {
+ printf("%c", d[i]);
+ }
+ SetConsoleTextAttribute(hConsole, FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE);
+#endif /* !ESP_CFG_AT_ECHO */
+
WriteFile(com_port, data, len, &written, NULL);
FlushFileBuffers(com_port);
return written;
|
more formatting changes
also trying to kick off the builders :P | @@ -33,6 +33,7 @@ should never go to disk, or you've lost the whole point of it)
## Build status
[](https://build.memcached.org/#/builders)
+
[](https://build.memcached.org/#/builders)
## Bug reports
|
[apps] Adjust systolic matmul to use CSR dump for benchmarks | @@ -40,7 +40,14 @@ uint32_t bm_v_push_cnt[SYSTOLIC_SIZE][SYSTOLIC_SIZE];
queue_t *queues_vert[SYSTOLIC_SIZE - 1][SYSTOLIC_SIZE];
queue_t *queues_horz[SYSTOLIC_SIZE][SYSTOLIC_SIZE - 1];
+// Define dump functions via CSR writes
+dump(horz_pop, 0x7D1);
+dump(vert_pop, 0x7D2);
+dump(horz_push, 0x7D3);
+dump(vert_push, 0x7D4);
+
void systolic_init(uint32_t const *grid_mapping) {
+ // Create systolic array via queues
uint32_t grid_pos = 0;
alloc_t *alloc;
for (uint32_t y = 0; y < SYSTOLIC_SIZE; ++y) {
@@ -252,8 +259,13 @@ void systolic_rcp_pe(const uint32_t rep_count,
}
}
+ // Store benchmark results
bm_h_push_cnt[0][0] = h_push_cnt;
bm_v_push_cnt[0][0] = v_push_cnt;
+
+ // Dump benchmark results
+ dump_horz_push(h_push_cnt);
+ dump_vert_push(v_push_cnt);
}
// column producing processing element
@@ -362,9 +374,15 @@ void systolic_cp_pe(const uint32_t col_idx, const uint32_t rep_count,
}
}
+ // Store benchmark results
bm_h_pop_cnt[0][col_idx] = h_pop_cnt;
bm_h_push_cnt[0][col_idx] = h_push_cnt;
bm_v_push_cnt[0][col_idx] = v_push_cnt;
+
+ // Dump benchmark results
+ dump_horz_pop(h_pop_cnt);
+ dump_horz_push(h_push_cnt);
+ dump_vert_push(v_push_cnt);
}
// row producing processing element
@@ -473,9 +491,15 @@ void systolic_rp_pe(const uint32_t row_idx, const uint32_t rep_count,
}
}
+ // Store benchmark results
bm_h_push_cnt[row_idx][0] = h_push_cnt;
bm_v_pop_cnt[row_idx][0] = v_pop_cnt;
bm_v_push_cnt[row_idx][0] = v_push_cnt;
+
+ // Dump benchmark results
+ dump_vert_pop(v_pop_cnt);
+ dump_horz_push(h_push_cnt);
+ dump_vert_push(v_push_cnt);
}
// non-producing processing element
@@ -594,8 +618,15 @@ void systolic_np_pe(const uint32_t row_idx, const uint32_t col_idx,
}
}
+ // Store benchmark results
bm_h_pop_cnt[row_idx][col_idx] = h_pop_cnt;
bm_h_push_cnt[row_idx][col_idx] = h_push_cnt;
bm_v_pop_cnt[row_idx][col_idx] = v_pop_cnt;
bm_v_push_cnt[row_idx][col_idx] = v_push_cnt;
+
+ // Dump benchmark results
+ dump_horz_pop(h_pop_cnt);
+ dump_vert_pop(v_pop_cnt);
+ dump_horz_push(h_push_cnt);
+ dump_vert_push(v_push_cnt);
}
|
Use bash | @@ -70,7 +70,7 @@ stage("Compare changes") {
])
// Check if git diff vs origin/master contains changes outside of ignored directories
gitChanges = sh (
- script: """
+ script: """#!/bin/bash
git diff --name-only testremote/${BRANCH_NAME} origin/master | grep --invert-match --extended-regexp \'${IGNORED_DIRS}\' --no-messages || [[ \$? == 1 ]]
""",
returnStdout: true,
|
[Platon][#1261]add params check | @@ -86,12 +86,36 @@ BOAT_RESULT BoatPlatONTxInit(BoatPlatONWallet *wallet_ptr,
return BOAT_ERROR_COMMON_INVALID_ARGUMENT;
}
+ if ((gasprice_str != NULL) && !UtilityStringIsHex(gasprice_str))
+ {
+ BoatLog(BOAT_LOG_CRITICAL, "The format of gasprice is incorrect");
+ return BOAT_ERROR_COMMON_INVALID_ARGUMENT;
+ }
+
+ if ((gaslimit_str != NULL) && !UtilityStringIsHex(gaslimit_str))
+ {
+ BoatLog(BOAT_LOG_CRITICAL, "The format of gaslimit is incorrect");
+ return BOAT_ERROR_COMMON_INVALID_ARGUMENT;
+ }
+
+ if (UtilityStringLenCheck(recipient_str) != BOAT_SUCCESS)
+ {
+ BoatLog(BOAT_LOG_CRITICAL, "The length of string recipient_str is incorrect");
+ return BOAT_ERROR_COMMON_INVALID_ARGUMENT;
+ }
+
tx_ptr->wallet_ptr = wallet_ptr;
memset(&tx_ptr->rawtx_fields, 0x00, sizeof(tx_ptr->rawtx_fields));
+ BoatLog(BOAT_LOG_CRITICAL, "The length of string recipient_str is incorrect");
// Generate platon's Bech32 address from the public key
- BoatPlatONBech32Encode(wallet_ptr->account_info.address , BOAT_PLATON_ADDRESS_SIZE,
+ result = BoatPlatONBech32Encode(wallet_ptr->account_info.address , BOAT_PLATON_ADDRESS_SIZE,
tx_ptr->address, hrp_str, strlen(hrp_str));
+ if (result == BOAT_ERROR)
+ {
+ BoatLog(BOAT_LOG_CRITICAL, "BoatPlatONBech32Encode failed");
+ return BOAT_ERROR_COMMON_INVALID_ARGUMENT;
+ }
// Set synchronous transaction flag
tx_ptr->is_sync_tx = is_sync_tx;
|
Rest API: config.modelid doesn't depend on specific api version | @@ -410,7 +410,6 @@ void DeRestPluginPrivate::configToMap(const ApiRequest &req, QVariantMap &map)
backup["status"] = QLatin1String("idle");
backup["errorcode"] = 0;
map["backup"] = backup;
- map["modelid"] = QLatin1String("deCONZ");
map["factorynew"] = false;
map["replacesbridgeid"] = QVariant();
map["datastoreversion"] = QLatin1String("60");
@@ -433,6 +432,7 @@ void DeRestPluginPrivate::configToMap(const ApiRequest &req, QVariantMap &map)
map["zigbeechannel"] = (double)gwZigbeeChannel;
gwPort = deCONZ::appArgumentNumeric("--http-port", 80); // cache
}
+ map["modelid"] = QLatin1String("deCONZ");
map["dhcp"] = true; // dummy
map["proxyaddress"] = gwProxyAddress;
map["proxyport"] = (double)gwProxyPort;
|
QUIC: Add miscellaneous QUIC constants | @@ -84,4 +84,11 @@ static ossl_unused ossl_inline int ossl_quic_conn_id_eq(const QUIC_CONN_ID *a,
#define QUIC_DEFAULT_ACK_DELAY_EXP 3
#define QUIC_MAX_ACK_DELAY_EXP 20
+#define QUIC_DEFAULT_MAX_ACK_DELAY 25
+
+#define QUIC_MIN_ACTIVE_CONN_ID_LIMIT 2
+
+/* Arbitrary choice of default idle timeout (not an RFC value). */
+#define QUIC_DEFAULT_IDLE_TIMEOUT 30000
+
#endif
|
Travis: only install msp430 where needed | @@ -13,7 +13,11 @@ before_script:
- sudo apt-get -qq update
## Support building a binary that is identical to the CI
- - echo -n "Contiki will be compiled with RELSTR=" ; git --git-dir .git describe --tags --always
+ - echo -n "Contiki-NG will be compiled with RELSTR=" ; git --git-dir .git describe --tags --always
+
+ ## Install 32-bit compatibility libraries
+ - sudo apt-get -qq install libc6:i386 libgcc1:i386 gcc-4.6-base:i386
+ libstdc++5:i386 libstdc++6:i386 lib32z1
## Install doxygen
- if [ ${BUILD_CATEGORY:-0} = doxygen ] ; then
@@ -23,16 +27,13 @@ before_script:
fi
## Install msp430 toolchain
- - sudo apt-get -qq install lib32z1
- - $WGET http://simonduq.github.io/resources/mspgcc-4.7.2-compiled.tar.bz2 &&
+ - if [ ${BUILD_ARCH:-0} = msp430 ] ; then
+ $WGET http://simonduq.github.io/resources/mspgcc-4.7.2-compiled.tar.bz2 &&
tar xjf mspgcc*.tar.bz2 -C /tmp/ &&
sudo cp -f -r /tmp/msp430/* /usr/local/ &&
rm -rf /tmp/msp430 mspgcc*.tar.bz2 &&
- msp430-gcc --version
-
- ## Install 32-bit compatibility libraries
- - sudo apt-get -qq install libc6:i386 libgcc1:i386 gcc-4.6-base:i386
- libstdc++5:i386 libstdc++6:i386
+ msp430-gcc --version ;
+ fi
## Install mainline ARM toolchain and srecord.
- if [ ${BUILD_ARCH:-0} = arm-aapcs ] ; then
@@ -97,16 +98,16 @@ env:
## This magically kick-off parallel jobs for each of the for the sets
## of environment variable defined below
- BUILD_TYPE='doxygen' BUILD_CATEGORY='doxygen'
- - BUILD_TYPE='compile-base' BUILD_CATEGORY='compile'
+ - BUILD_TYPE='compile-base' BUILD_CATEGORY='compile' BUILD_ARCH='msp430'
- BUILD_TYPE='compile-arm-ports' BUILD_CATEGORY='compile' BUILD_ARCH='arm-aapcs'
- BUILD_TYPE='compile-nxp-ports' BUILD_CATEGORY='compile' BUILD_ARCH='jn516x'
- BUILD_TYPE='compile-nrf52-ports' BUILD_CATEGORY='compile' BUILD_ARCH='nrf52dk'
- BUILD_TYPE='compile-tools' BUILD_CATEGORY='compile'
- BUILD_TYPE='rpl-lite' BUILD_CATEGORY='sim'
- BUILD_TYPE='rpl-classic' BUILD_CATEGORY='sim'
- - BUILD_TYPE='ipv6' BUILD_CATEGORY='sim'
+ - BUILD_TYPE='ipv6' BUILD_CATEGORY='sim' BUILD_ARCH='msp430'
- BUILD_TYPE='nullnet' BUILD_CATEGORY='sim'
- - BUILD_TYPE='base' BUILD_CATEGORY='sim'
+ - BUILD_TYPE='base' BUILD_CATEGORY='sim' BUILD_ARCH='msp430'
- BUILD_TYPE='ieee802154' BUILD_CATEGORY='sim'
- BUILD_TYPE='6tisch' BUILD_CATEGORY='sim'
- BUILD_TYPE='rpl-border-router' BUILD_CATEGORY='sim'
|
Security (TLS) code fix only: free a TLS context.
The function uSecurityTlsRemove(), which should free a TLS context, wasn't actually freeing the TLS context at all. It is now. | @@ -268,7 +268,7 @@ uSecurityTlsContext_t *pUSecurityTlsAdd(uDeviceHandle_t devHandle,
// Free the given TLS security context.
void uSecurityTlsRemove(uSecurityTlsContext_t *pContext)
{
- if ((pContext != NULL) && init()) {
+ if ((pContext != NULL) && (init() == 0)) {
U_PORT_MUTEX_LOCK(gMutex);
|
fixed clear and removed calls | @@ -827,9 +827,9 @@ QvisSimulationWindow::UpdateUIComponent(QWidget *window, const QString &name,
if (ui->inherits("QListWidget"))
{
- QListWidget* tWidget = ((QListWidget*)ui);
+ QListWidget* lWidget = ((QListWidget*)ui);
- tWidget->setEnabled(true);
+ lWidget->setEnabled(true);
unsigned int row;
std::string text;
@@ -841,17 +841,26 @@ QvisSimulationWindow::UpdateUIComponent(QWidget *window, const QString &name,
if( text == std::string("CLEAR_LIST") )
{
- while( tWidget->count() )
- tWidget->removeItemWidget( tWidget->item( tWidget->count() - 1) );
+ while( lWidget->count() )
+ {
+ QListWidgetItem *item =
+ lWidget->takeItem( lWidget->count() - 1 );
+
+ if( item )
+ delete item;
+ }
}
else if( text == std::string("REMOVE_ROW") &&
- row < tWidget->count() )
+ 0 <= row && row < lWidget->count() )
{
- tWidget->removeItemWidget( tWidget->item( row ) );
+ QListWidgetItem *item = lWidget->takeItem( row );
+
+ if( item )
+ delete item;
}
else
{
- QListWidgetItem *item = tWidget->item(row);
+ QListWidgetItem *item = lWidget->item(row);
// See if the item has already been created.
if( item )
@@ -861,10 +870,16 @@ QvisSimulationWindow::UpdateUIComponent(QWidget *window, const QString &name,
}
else
{
- // Create a new item and make sure there is room for it.
+ // Insert blank items if the count is less than the
+ // row. Otherwise the item will be inserted at the end
+ // of the list.
+ while( lWidget->count() < row )
+ lWidget->addItem(QString(""));
+
+ // Create a new item and insert it into the list
item = new QListWidgetItem(tr("%1").arg(text.c_str()));
- tWidget->insertItem(row, item);
+ lWidget->insertItem(row, item);
}
// Is the item editable?
@@ -893,18 +908,20 @@ QvisSimulationWindow::UpdateUIComponent(QWidget *window, const QString &name,
<< " row = " << row << " column = " << column
<< " with text = " << text << std::endl;
+ // NOTE : It is not clear if when removing a row or column
+ // if the items are deleted. Possible memory leak?
if( text == std::string("CLEAR_TABLE") )
{
while( tWidget->rowCount() )
tWidget->removeRow( tWidget->rowCount() - 1);
}
else if( text == std::string("REMOVE_ROW") &&
- row < tWidget->rowCount() )
+ 0 <= row && row < tWidget->rowCount() )
{
tWidget->removeRow( row );
}
else if( text == std::string("REMOVE_COLUMN") &&
- column < tWidget->columnCount() )
+ column <= 0 && column < tWidget->columnCount() )
{
tWidget->removeColumn( column );
}
|
[lr] cmd file available | #define LR_CORENAME "Neko Project II kai"
#define LR_LIBVERSION NP2VER_CORE
-#define LR_VALIDFILEEXT "d88|88d|d98|98d|fdi|xdf|hdm|dup|2hd|tfd|nfd|hd4|hd5|hd9|fdd|h01|hdb|ddb|dd6|dcp|dcu|flp|img|ima|bin|fim|thd|nhd|hdi|vhd|sln|hdn|m3u"
+#define LR_VALIDFILEEXT "d88|88d|d98|98d|fdi|xdf|hdm|dup|2hd|tfd|nfd|hd4|hd5|hd9|fdd|h01|hdb|ddb|dd6|dcp|dcu|flp|img|ima|bin|fim|thd|nhd|hdi|vhd|sln|hdn|m3u|cmd"
#define LR_NEEDFILEPATH true
#define LR_BLOCKARCEXTRACT false
#define LR_REQUIRESROM false
|
Use hook-mode=auto when deploying to minikube
fanotify is already used if available, there's no reason why this should
be forced. Putting it in auto allows this rule to be used on
minikube installations that don't support fanotify (like the one used in
the cloud native bpf workshop) | @@ -166,7 +166,7 @@ minikube-install: gadget-container kubectl-gadget
docker save $(CONTAINER_REPO):$(IMAGE_TAG) $(PV) | (eval $(shell $(MINIKUBE) -p minikube docker-env | grep =) && docker load)
# Remove all resources created by Inspektor Gadget.
./kubectl-gadget undeploy || true
- ./kubectl-gadget deploy --hook-mode=fanotify \
+ ./kubectl-gadget deploy --hook-mode=auto \
--image-pull-policy=Never | \
sed 's/initialDelaySeconds: 10/initialDelaySeconds: '$(LIVENESS_PROBE_INITIAL_DELAY_SECONDS)'/g' | \
kubectl apply -f -
|
Fix documented max. length for info buffer in HKDF
This limit was increased with ("Increase
HKDF_MAXBUF from 1024 to 2048").
CLA: trivial | @@ -99,7 +99,7 @@ A context for HKDF can be obtained by calling:
EVP_PKEY_CTX *pctx = EVP_PKEY_CTX_new_id(EVP_PKEY_HKDF, NULL);
-The total length of the info buffer cannot exceed 1024 bytes in length: this
+The total length of the info buffer cannot exceed 2048 bytes in length: this
should be more than enough for any normal use of HKDF.
The output length of an HKDF expand operation is specified via the length
|
Remove stray debugging message. | @@ -353,7 +353,6 @@ interface_up(struct interface *ifp, int up)
}
}
}
- printf("Type: %d\n", type);
/* Type is CONFIG_TYPE_AUTO if interface is not known to be
wireless, so provide sane defaults for that case. */
|
add saner defaults to config | //***********************************************RECEIVER SETTINGS******************************************************
// *************Receiver protocol selection //todo: add missing radio protocols from bobnova and make them all jive with new rx_init function in drv_rx_serial.c
-//#define RX_SBUS
+#define RX_SBUS
//#define RX_CRSF //Requires tbs firmware v2.88 or newer for failsafe to operate properly
//#define RX_IBUS
//#define RX_FPORT
//#define RX_NRF24_BAYANG_TELEMETRY
//#define RX_BAYANG_PROTOCOL_BLE_BEACON
//#define RX_BAYANG_PROTOCOL_TELEMETRY_AUTOBIND
-#define RX_FRSKY
+//#define RX_FRSKY
// *************Serial Receiver UART Selection (uncomment all if using spi receiver) //todo: Many missing usart AF setups, So plenty more to do here
//#define UART_1
-//#define UART_2
+#define UART_2
//#define UART_3
//#define UART_4
//#define UART_6
|
graph-store: turned off signatures for now | hash.post `calculated-hash
signatures.post
?. =(our.bowl author.post.node) ~
- %- ~(gas in *signatures:store)
- :_ ~
- :+ `@ux`(sign:as:crub:crypto calculated-hash)
- our.bowl
- .^(=life %j /=life/(scot %p our.bowl))
+ %- ~(gas in *signatures:store) ~
+ :::_ ~
+ :: TODO: how to sign a message using our private key?
+ :::+ `@ux`(sign:as:crub:crypto calculated-hash)
+ :: our.bowl
+ ::.^(=life %j /=life/(scot %p our.bowl))
==
~| "index does not exist to add a node to!"
=/ parent=node:store (need (get:orm graph atom))
|
workflows: use apt-get | @@ -49,8 +49,8 @@ jobs:
steps:
- name: Setup environment
run: |
- sudo apt update
- sudo apt install -y gcc-7 g++-7 clang-6.0 libsystemd-dev gcovr libyaml-dev
+ sudo apt-get update
+ sudo apt-get install -y gcc-7 g++-7 clang-6.0 libsystemd-dev gcovr libyaml-dev
sudo ln -s /usr/bin/llvm-symbolizer-6.0 /usr/bin/llvm-symbolizer || true
- uses: actions/checkout@v3
|
dm-hook: transform indices | +$ state-0 [%0 base-state-0]
+$ card card:agent:gall
+$ nodes (map index:store node:store)
+++ orm orm:store
--
::
=| state-0
?. =(our.bowl ship) ship
entity.rid
::
+ ++ update-indices
+ |= [pfix=index:store =graph:store]
+ =* loop $
+ ^- graph:store
+ %+ gas:orm *graph:store
+ %+ turn (tap:orm graph)
+ |= [=atom =node:store]
+ ^- [^atom node:store]
+ =/ =index:store (snoc pfix atom)
+ :- atom
+ =. children.node
+ ?: ?=(%empty -.children.node) children.node
+ [%graph loop(pfix index, graph p.children.node)]
+ ?: ?=(%| -.post.node) node
+ node(index.p.post index)
+ ::
++ graph
%+ roll dms
|= [rid=resource =graph:store]
index.post [ship ~]
time-sent.post now.bowl
==
+ =. graph
+ (update-indices ~[ship] graph)
(put:orm:store graph `@`ship [%& post] %graph graph)
--
::
|
microbit bsp: fix split linker script typo | @@ -25,7 +25,7 @@ bsp.linkerscript:
bsp.linkerscript.BOOT_LOADER.OVERWRITE:
- "hw/bsp/bbc_microbit/boot-nrf51xxac.ld"
- "hw/mcu/nordic/nrf51xxx/nrf51.ld"
-bsp.part2linkerscript: "hw/bsp/bbc_microbit/split-nrf51dk.ld"
+bsp.part2linkerscript: "hw/bsp/bbc_microbit/split-microbit.ld"
bsp.downloadscript: hw/bsp/bbc_microbit/microbit_download.sh
bsp.debugscript: hw/bsp/bbc_microbit/microbit_debug.sh
bsp.downloadscript.WINDOWS.OVERWRITE: hw/bsp/bbc_microbit/microbit_download.cmd
|
hv: vtd: init DMAR/IR table address when register
Initialize root_table_addr/ir_table_addr of dmar uint when register the dmar uint.
So no need to check if they are initialzed or not later.
Acked-by: Eddie Dong | @@ -450,6 +450,8 @@ static int32_t dmar_register_hrhd(struct dmar_drhd_rt *dmar_unit)
dmar_unit->cap_num_fault_regs = iommu_cap_num_fault_regs(dmar_unit->cap);
dmar_unit->cap_fault_reg_offset = iommu_cap_fault_reg_offset(dmar_unit->cap);
dmar_unit->ecap_iotlb_offset = iommu_ecap_iro(dmar_unit->ecap) * 16U;
+ dmar_unit->root_table_addr = hva2hpa(get_root_table(dmar_unit->index));
+ dmar_unit->ir_table_addr = hva2hpa(get_ir_table(dmar_unit->index));
#if DBG_IOMMU
pr_info("version:0x%x, cap:0x%lx, ecap:0x%lx",
@@ -675,6 +677,7 @@ static void dmar_invalid_iotlb_global(struct dmar_drhd_rt *dmar_unit)
dmar_invalid_iotlb(dmar_unit, 0U, 0UL, 0U, false, DMAR_IIRG_GLOBAL);
}
+/* @pre dmar_unit->ir_table_addr != NULL */
static void dmar_set_intr_remap_table(struct dmar_drhd_rt *dmar_unit)
{
uint64_t address;
@@ -683,15 +686,9 @@ static void dmar_set_intr_remap_table(struct dmar_drhd_rt *dmar_unit)
spinlock_obtain(&(dmar_unit->lock));
- if (dmar_unit->ir_table_addr == 0UL) {
- dmar_unit->ir_table_addr = hva2hpa(get_ir_table(dmar_unit->index));
- }
-
- address = dmar_unit->ir_table_addr | DMAR_IR_ENABLE_EIM;
-
/* Set number of bits needed to represent the entries minus 1 */
size = (uint8_t) fls32(CONFIG_MAX_IR_ENTRIES) - 1U;
- address = address | size;
+ address = dmar_unit->ir_table_addr | DMAR_IR_ENABLE_EIM | size;
iommu_write64(dmar_unit, DMAR_IRTA_REG, address);
@@ -730,28 +727,13 @@ static void dmar_invalid_iec_global(struct dmar_drhd_rt *dmar_unit)
dmar_invalid_iec(dmar_unit, 0U, 0U, true);
}
+/* @pre dmar_unit->root_table_addr != NULL */
static void dmar_set_root_table(struct dmar_drhd_rt *dmar_unit)
{
- uint64_t address;
uint32_t status;
spinlock_obtain(&(dmar_unit->lock));
-
- /*
- * dmar_set_root_table is called from init_iommu and
- * resume_iommu. So NULL check on this pointer is needed
- * so that we do not change the root table pointer in the
- * resume flow.
- */
-
- if (dmar_unit->root_table_addr == 0UL) {
- dmar_unit->root_table_addr = hva2hpa(get_root_table(dmar_unit->index));
- }
-
- /* Currently don't support extended root table */
- address = dmar_unit->root_table_addr;
-
- iommu_write64(dmar_unit, DMAR_RTADDR_REG, address);
+ iommu_write64(dmar_unit, DMAR_RTADDR_REG, dmar_unit->root_table_addr);
iommu_write32(dmar_unit, DMAR_GCMD_REG, dmar_unit->gcmd | DMA_GCMD_SRTP);
|
input: better coverage comparisons | @@ -247,8 +247,7 @@ bool input_parseDictionary(honggfuzz_t* hfuzz) {
struct strings_t* str = (struct strings_t*)util_Malloc(sizeof(struct strings_t) + len + 1);
memcpy(str->s, bufv, len);
str->len = len;
- str->s[len] = '\0';
- hfuzz->mutate.dictionaryCnt += 1;
+ hfuzz->mutate.dictionaryCnt++;
TAILQ_INSERT_TAIL(&hfuzz->mutate.dictq, str, pointers);
LOG_D("Dictionary: loaded word: '%s' (len=%zu)", str->s, str->len);
@@ -528,6 +527,21 @@ bool input_prepareDynamicFileForMinimization(run_t* run) {
return true;
}
+/* true if item1 is bigger than item2 */
+static bool input_cmpCov(struct dynfile_t* item1, struct dynfile_t* item2) {
+ for (size_t j = 0; j < ARRAYSIZE(item1->cov); j++) {
+ if (item1->cov[j] > item2->cov[j]) {
+ return true;
+ }
+ if (item1->cov[j] < item2->cov[j]) {
+ return false;
+ }
+ }
+
+ /* Both are equal */
+ return false;
+}
+
#define TAILQ_FOREACH_HF(var, head, field) \
for ((var) = TAILQ_FIRST((head)); (var); (var) = TAILQ_NEXT((var), field))
@@ -543,17 +557,7 @@ void input_sortDynamicInput(honggfuzz_t* hfuzz) {
continue;
}
- bool swap = false;
- for (size_t j = 0; j < ARRAYSIZE(item->cov); j++) {
- if (itemnext->cov[j] > item->cov[j]) {
- swap = true;
- break;
- }
- if (itemnext->cov[j] < item->cov[j]) {
- break;
- }
- }
- if (swap) {
+ if (input_cmpCov(itemnext, item)) {
TAILQ_REMOVE(&hfuzz->io.dynfileq, itemnext, pointers);
TAILQ_INSERT_BEFORE(item, itemnext, pointers);
/* We've swapped items, so rewind item to the itemnext */
|
Add reset to the oc OBT sample.
Tested-by: IoTivity Jenkins | @@ -65,6 +65,7 @@ public class ObtMain {
menu.append("[7] Provision ACE2\n");
menu.append("------------------------------------------------\n");
menu.append("[8] RESET device\n");
+ menu.append("[9] RESET OBT\n");
menu.append("------------------------------------------------\n");
menu.append("[9] Exit\n");
menu.append("################################################\n");
@@ -498,6 +499,13 @@ public class ObtMain {
}
}
+ public static void resetOBT() {
+ OCMain.reset();
+ obt.shutdown();
+ ownedDevices.clear();
+ unownedDevices.clear();
+ obt = new OcObt();
+ }
public static void main(String[] args) {
Runtime.getRuntime().addShutdownHook(shutdownHook);
@@ -552,6 +560,9 @@ public class ObtMain {
resetDevice();
break;
case 9:
+ resetOBT();
+ break;
+ case 10:
quit = true;
break;
default:
|
metadata-pull-hook: move watches to +on-init | met ~(. mdl bowl)
hc ~(. +> bowl)
::
-++ on-init on-init:def
+++ on-init
+ :_ this
+ :~ watch-invites:hc
+ watch-contacts:hc
+ watch-store:hc
+ ==
+::
++ on-save !>(state)
++ on-load
|= =vase
=+ !<(old=state-zero vase)
- :_ this(state old)
- %- zing
- :~ ?: (~(has by wex.bowl) [/invites our.bowl %invite-store]) ~
- ~[watch-invites:hc]
- ?: (~(has by wex.bowl) [/contacts our.bowl %contact-store]) ~
- ~[watch-contacts:hc]
- ?: (~(has by wex.bowl) [/store our.bowl %metadata-store]) ~
- ~[watch-store:hc]
- ==
+ `this(state old)
::
++ on-poke
|= [=mark =vase]
|
posix: Implement pthread_rwlock_destroy() | @@ -615,8 +615,8 @@ int pthread_rwlock_init(pthread_rwlock_t *__restrict, const pthread_rwlockattr_t
}
int pthread_rwlock_destroy(pthread_rwlock_t *) {
- __ensure(!"Not implemented");
- __builtin_unreachable();
+ // TODO: make sure the lock is the unlocked state.
+ return 0;
}
int pthread_rwlock_trywrlock(pthread_rwlock_t *) {
|
drbg: add handling for cases where TSAN isn't available
Most of the DRGB code is run under lock from the EVP layer. This is relied
on to make the majority of TSAN operations safe. However, it is still necessary
to enable locking for all DRBGs created. | @@ -837,6 +837,10 @@ PROV_DRBG *ossl_rand_drbg_new
goto err;
}
}
+#ifdef TSAN_REQUIRES_LOCKING
+ if (!ossl_drbg_enable_locking(drbg))
+ goto err;
+#endif
return drbg;
err:
|
interface: add more collections stories, fix test flake | @@ -8,7 +8,8 @@ import BigIntOrderedMap from '@urbit/api/lib/BigIntOrderedMap';
import { GraphNode } from '@urbit/api';
import useMetadataState from '~/logic/state/metadata';
import { makeComment } from '~/logic/lib/fixtures';
-import moment from 'moment';
+
+const HOUR = 60*60 * 1000;
export default {
title: 'Collections/LinkDetail',
@@ -35,20 +36,57 @@ const node = {
children: new BigIntOrderedMap<GraphNode>().gas([
makeComment(
'ridlur-figbud',
- moment().hour(12).minute(34).valueOf(),
+ Date.now() - 4*HOUR,
nodeIndex,
[{ text: 'Beautiful' }]
),
makeComment(
'roslet-tanner',
- moment().hour(12).minute(34).valueOf(),
+ Date.now() - 3*HOUR,
nodeIndex,
[{ text: 'where did you find this?' }]
),
makeComment(
'fabled-faster',
- moment().hour(12).minute(34).valueOf(),
+ Date.now() - 2*HOUR,
+ nodeIndex,
+ [{ text: 'I dont\'t remember lol' }]
+ )
+ ])
+};
+
+const youtubeNode = {
+ post: {
+ index: '/170141184504850861030994857749504231212',
+ author: 'fabled-faster',
+ 'time-sent': 1609969377513,
+ signatures: [],
+ contents: [
+ { text: 'LindyMan' },
+ {
+ url: 'https://twitter.com/PaulSkallas/status/1388896550198317056'
+ }
+ ],
+ hash: null
+ },
+ children: new BigIntOrderedMap<GraphNode>().gas([
+ makeComment(
+ 'ridlur-figbud',
+ Date.now() - 4*HOUR,
+ nodeIndex,
+ [{ text: 'Beautiful' }]
+ ),
+ makeComment(
+ 'roslet-tanner',
+ Date.now() - 3*HOUR,
+ nodeIndex,
+ [{ text: 'where did you find this?' }]
+ ),
+
+ makeComment(
+ 'fabled-faster',
+ Date.now() - 2*HOUR,
nodeIndex,
[{ text: 'I dont\'t remember lol' }]
)
@@ -60,7 +98,7 @@ export const Image = () => {
s => s.associations.graph['/ship/~bitbet-bolbel/links']
);
return (
- <Box width="1166px" p="1" backgroundColor="white">
+ <Box width="100%" height="100%" p="1" backgroundColor="white">
<LinkDetail
baseUrl="/"
node={node}
@@ -69,6 +107,21 @@ export const Image = () => {
</Box>
);
};
+
+export const Youtube = () => {
+ const association = useMetadataState(
+ s => s.associations.graph['/ship/~bitbet-bolbel/links']
+ );
+ return (
+ <Box height="100%" width="100%" border="1" borderColor="lightGray" maxWidth="1166px" backgroundColor="white">
+ <LinkDetail
+ baseUrl="/"
+ node={youtubeNode}
+ association={association}
+ />
+ </Box>
+ );
+};
Image.parameters = {
design: {
type: 'figma',
|
Increment version - testing | @@ -2,7 +2,7 @@ dnl require autoconf 2.60 (AS_ECHO/AS_ECHO_N)
AC_PREREQ([2.60])
define(_CLIENT_VERSION_MAJOR, 2)
define(_CLIENT_VERSION_MINOR, 0)
-define(_CLIENT_VERSION_REVISION, 7)
+define(_CLIENT_VERSION_REVISION, 8)
define(_CLIENT_VERSION_BUILD, 0)
define(_CLIENT_VERSION_IS_RELEASE, true)
define(_COPYRIGHT_YEAR, 2018)
|
Fix a Windows warning. | @@ -2581,7 +2581,7 @@ usrsctp_bindx(struct socket *so, struct sockaddr *addrs, int addrcnt, int flags)
}
}
#endif
- if (usrsctp_setsockopt(so, IPPROTO_SCTP, flags, sa, sa_len) != 0) {
+ if (usrsctp_setsockopt(so, IPPROTO_SCTP, flags, sa, (socklen_t)sa_len) != 0) {
return (-1);
}
sa = (struct sockaddr *)((caddr_t)sa + sa_len);
|
fix(sticky keys): simplify timer management | @@ -53,7 +53,8 @@ struct active_sticky_key active_sticky_keys[ZMK_BHV_STICKY_KEY_MAX_HELD] = {};
static struct active_sticky_key *store_sticky_key(u32_t position, u32_t param1, u32_t param2,
const struct behavior_sticky_key_config *config) {
for (int i = 0; i < ZMK_BHV_STICKY_KEY_MAX_HELD; i++) {
- if (active_sticky_keys[i].position != ZMK_BHV_STICKY_KEY_POSITION_NOT_USED) {
+ if (active_sticky_keys[i].position != ZMK_BHV_STICKY_KEY_POSITION_NOT_USED ||
+ active_sticky_keys[i].timer_is_cancelled) {
continue;
}
active_sticky_keys[i].position = position;
@@ -76,7 +77,8 @@ static void clear_sticky_key(struct active_sticky_key *sticky_key) {
static struct active_sticky_key *find_sticky_key(u32_t position) {
for (int i = 0; i < ZMK_BHV_STICKY_KEY_MAX_HELD; i++) {
- if (active_sticky_keys[i].position == position) {
+ if (active_sticky_keys[i].position == position &&
+ !active_sticky_keys[i].timer_is_cancelled) {
return &active_sticky_keys[i];
}
}
@@ -191,9 +193,8 @@ static int sticky_key_keycode_state_changed_listener(const struct zmk_event_head
// Release the sticky key if the timer should've run out in the meantime.
if (sticky_key->release_at != 0 && ev->timestamp > sticky_key->release_at) {
release_sticky_key_behavior(sticky_key, sticky_key->release_at);
- if (stop_timer(sticky_key)) {
+ stop_timer(sticky_key);
clear_sticky_key(sticky_key);
- }
continue;
}
@@ -230,11 +231,13 @@ void behavior_sticky_key_timer_handler(struct k_work *item) {
if (sticky_key->position == ZMK_BHV_STICKY_KEY_POSITION_NOT_USED) {
return;
}
- if (!sticky_key->timer_is_cancelled) {
+ if (sticky_key->timer_is_cancelled) {
+ sticky_key->timer_is_cancelled = false;
+ } else {
release_sticky_key_behavior(sticky_key, k_uptime_get());
- }
clear_sticky_key(sticky_key);
}
+}
static int behavior_sticky_key_init(struct device *dev) {
static bool init_first_run = true;
|
Fix VMS installation - Document in CHANGES.md | @@ -70,6 +70,15 @@ OpenSSL 3.1
*Sergey Kirillov, Andrey Matyukov (Intel Corp)*
+### Changes between 3.0.0 and 3.0.1 [xx XXX xxxx]
+
+ * Corrected a few file name and file reference bugs in the build,
+ installation and setup scripts, which lead to installation verification
+ failures. Slightly enhanced the installation verification script.
+
+ *Richard Levitte*
+
+
OpenSSL 3.0
-----------
|
Updated typedecl.declare to include expected and received argument counts in the error message.
Debugging things in the parser is a bit tricky. One thing that might help is editing the error
message in typedecl.lua to say what was the expected number and how many arguments were received. | @@ -68,7 +68,9 @@ function typedecl.declare(module, mod_name, type_name, constructors)
local function cons(...)
local args = table.pack(...)
if args.n ~= #fields then
- error("wrong number of arguments for " .. cons_name)
+ error(string.format(
+ "wrong number of arguments for %s. Expected %d but received %d.",
+ cons_name, #fields, args.n))
end
local node = { _tag = tag }
for i, field in ipairs(fields) do
|
Fix broken test suite when iwgetid command isn't available. | @@ -2672,7 +2672,10 @@ test_wifi_status_cb(
// Range check input...
if (wifi_data)
+ {
memset(wifi_data, 0, sizeof(pappl_wifi_t));
+ wifi_data->state = PAPPL_WIFI_STATE_OFF;
+ }
if (!system)
{
@@ -2695,10 +2698,13 @@ test_wifi_status_cb(
// Fill in the Wi-Fi status... This code only returns the 'not-configured' or
// 'on' state values for simplicity, but production code should support all of
// them.
- if ((fp = popen("iwgetid", "r")) == NULL)
+ if (access("/sbin/iwgetid", X_OK))
+ return (wifi_data); // No iwgetid command...
+
+ if ((fp = popen("/sbin/iwgetid", "r")) == NULL)
{
// Can't run command, so no Wi-Fi support...
- return (NULL);
+ return (wifi_data);
}
if (fgets(line, sizeof(line), fp))
|
OcBootManagementLib: Fix compilation warnings | @@ -46,10 +46,8 @@ InternalLoadBootEntry (
EFI_STATUS Status;
EFI_STATUS OptionalStatus;
EFI_DEVICE_PATH_PROTOCOL *DevicePath;
- EFI_DEVICE_PATH_PROTOCOL *HandleFilePath;
CHAR16 *UnicodeDevicePath;
EFI_LOADED_IMAGE_PROTOCOL *LoadedImage;
- EFI_HANDLE DeviceHandle;
VOID *EntryData;
UINT32 EntryDataSize;
|
test: i2c: verify I2C lock with invalid port
Verify I2C locks fail for an invalid port.
BRANCH=none
TEST=twister
Code-Coverage: Zoss | @@ -22,6 +22,17 @@ ZTEST_USER(i2c, test_i2c_port_count)
I2C_PORT_COUNT);
}
+ZTEST_USER(i2c, test_i2c_lock_invalid_port)
+{
+ i2c_lock(-1, 1);
+ zassert_equal(i2c_port_is_locked(-1), 0,
+ "Negative I2C port locked, but should have failed");
+
+ i2c_lock(INT_MAX, 1);
+ zassert_equal(i2c_port_is_locked(INT_MAX), 0,
+ "MAX_INT I2C port locked, but should have failed");
+}
+
ZTEST_USER(i2c, test_i2c_lock)
{
i2c_lock(I2C_PORT_ACCEL, 1);
|
FEC: reduce packet reduction overhead | protoop_arg_t stream_bytes_max(picoquic_cnx_t* cnx) {
size_t bytes_max = get_cnx(cnx, CNX_AK_INPUT, 0);
- size_t header_length = get_cnx(cnx, CNX_AK_INPUT, 1);
// FIXME there is one more byte than needed (?) in the overhead, but without it, it doesn't work. Find out why
- size_t overhead = 1 + header_length + (DEFAULT_K/2 + sizeof(fec_frame_header_t));
+ size_t overhead = 1 + (1 + sizeof(uint64_t)) + (DEFAULT_K/2 + sizeof(fec_frame_header_t));
set_cnx(cnx, CNX_AK_OUTPUT, 0, (bytes_max && bytes_max > overhead) ? bytes_max-overhead : bytes_max);
return 0;
}
\ No newline at end of file
|
fix(api_ethereum.c):
According to "load_existed_wallet" to determine whether to execute keyCreat | @@ -67,6 +67,7 @@ BoatEthWallet *BoatEthWalletInit(const BoatEthWalletConfig *config_ptr, BUINT32
//Configure priKey context information
// if(config_ptr->prikeyCtx_config.prikey_content.field_ptr != NULL)
+ if(config_ptr->load_existed_wallet == false)
{
if(BOAT_SUCCESS != BoatPort_keyCreate(&config_ptr->prikeyCtx_config, &wallet_ptr->account_info.prikeyCtx))
{
|
apps/s_socket.c: print only dynamically allocated port in do_server.
For formal backward compatibility print original "ACCEPT" message for
fixed port and "ACCEPT host:port" for dynamically allocated. | @@ -283,7 +283,8 @@ int do_server(int *accept_sock, const char *host, const char *port,
BIO_ADDRINFO_free(res);
res = NULL;
- {
+ if (BIO_ADDR_rawport(sock_address) == 0) {
+ /* dynamically allocated port, report which one */
union BIO_sock_info_u info;
char *hostname = NULL;
char *service = NULL;
@@ -309,6 +310,9 @@ int do_server(int *accept_sock, const char *host, const char *port,
ERR_print_errors(bio_err);
goto end;
}
+ } else {
+ (void)BIO_printf(bio_s_out, "ACCEPT\n");
+ (void)BIO_flush(bio_s_out);
}
if (accept_sock != NULL)
|
Fix log output for bash function assert in utils.sh | @@ -161,7 +161,7 @@ function assert( )
{
if [ $TEST_OK -eq 0 ]; then
# Test already failed, do not even read log file (may be from prev run)
- report_skip "$NAME"
+ report_skip "$1"
return
else
do_assert "$1" "$2" 1
|
VERSION bump to version 1.4.103 | @@ -46,7 +46,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 4)
-set(SYSREPO_MICRO_VERSION 102)
+set(SYSREPO_MICRO_VERSION 103)
set(SYSREPO_VERSION ${SYSREPO_MAJOR_VERSION}.${SYSREPO_MINOR_VERSION}.${SYSREPO_MICRO_VERSION})
# Version of the library
|
lib: mbedtls: disable check of Perl | @@ -27,7 +27,7 @@ set(NULL_ENTROPY_WARNING "${WARNING_BORDER}"
"${NULL_ENTROPY_WARN_L3}"
"${WARNING_BORDER}")
-find_package(Perl)
+#find_package(Perl)
if(PERL_FOUND)
# If NULL Entropy is configured, display an appropriate warning
|
params: add integer conversion test cases. | @@ -48,8 +48,16 @@ static const struct {
size_t len;
unsigned char value[MAX_LEN];
} raw_values[] = {
+ { 1, { 0x47 } },
+ { 1, { 0xd0 } },
+ { 2, { 0x01, 0xe9 } },
+ { 2, { 0xff, 0x53 } },
+ { 3, { 0x16, 0xff, 0x7c } },
+ { 3, { 0xa8, 0x9c, 0x0e } },
{ 4, { 0x38, 0x27, 0xbf, 0x3b } },
{ 4, { 0x9f, 0x26, 0x48, 0x22 } },
+ { 5, { 0x30, 0x65, 0xfa, 0xe4, 0x81 } },
+ { 5, { 0xd1, 0x76, 0x01, 0x1b, 0xcd } },
{ 8, { 0x59, 0xb2, 0x1a, 0xe9, 0x2a, 0xd8, 0x46, 0x40 } },
{ 8, { 0xb4, 0xae, 0xbd, 0xb4, 0xdd, 0x04, 0xb1, 0x4c } },
{ 16, { 0x61, 0xe8, 0x7e, 0x31, 0xe9, 0x33, 0x83, 0x3d,
@@ -65,8 +73,8 @@ static int test_param_type_extra(OSSL_PARAM *param, const unsigned char *cmp,
int64_t i64;
size_t s, sz;
unsigned char buf[MAX_LEN];
- const int bit32 = param->data_size == sizeof(int32_t);
- const int sizet = bit32 && sizeof(size_t) > sizeof(int32_t);
+ const int bit32 = param->data_size <= sizeof(int32_t);
+ const int sizet = param->data_size <= sizeof(size_t);
const int signd = param->data_type == OSSL_PARAM_INTEGER;
/*
|
Update logo url in readme. | <div align="center">
- <a href="https://metacall.io" target="_blank"><img src="/deploy/images/logo.png" alt="M E T A C A L L" style="max-width:100%;" width="32" height="32">
+ <a href="https://metacall.io" target="_blank"><img src="https://raw.githubusercontent.com/metacall/core/develop/deploy/images/logo.png" alt="M E T A C A L L" style="max-width:100%;" width="32" height="32">
<p><b>M E T A C A L L</b></p></a>
<p>A library for providing inter-language foreign function interface calls</p>
</div>
|
VERSION bump to version 2.1.47 | @@ -64,7 +64,7 @@ endif()
# micro version is changed with a set of small changes or bugfixes anywhere in the project.
set(SYSREPO_MAJOR_VERSION 2)
set(SYSREPO_MINOR_VERSION 1)
-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
|
kernel/binary_manager: Add missing BP recovery update and version update
Add a flag for BP recovery
Set updated BP data in g_bp_info when BP data is updated
Update version after header verification is done | @@ -205,6 +205,7 @@ static int binary_manager_load(int bin_idx)
printf("[Binary Loading] Invalid Signature, name : %s, address : %p\n", BIN_NAME(bin_idx), BIN_PARTADDR(bin_idx, (BIN_USEIDX(bin_idx))));
if (--bin_count > 0) {
BIN_USEIDX(bin_idx) ^= 1;
+ need_update_bp = true;
printf("[Binary Loading] Try to read another partition %s\n", GET_PARTNAME(BIN_USEIDX(bin_idx)));
continue;
} else {
@@ -219,19 +220,23 @@ static int binary_manager_load(int bin_idx)
#ifdef CONFIG_SUPPORT_COMMON_BINARY
if (bin_idx == BM_CMNLIB_IDX) {
ret = binary_manager_read_header(BINARY_COMMON, devpath, &common_header_data, true);
+ BIN_VER(bin_idx, BIN_USEIDX(bin_idx)) = common_header_data.version;
} else
#endif
{
ret = binary_manager_read_header(BINARY_USERAPP, devpath, &user_header_data, true);
+ BIN_VER(bin_idx, BIN_USEIDX(bin_idx)) = user_header_data.bin_ver;
}
if (ret == BINMGR_OK) {
printf("[Binary Loading] %s Header Checking Success\n", BIN_NAME(bin_idx));
} else {
+ /* Clear version because of invalid binary */
+ BIN_VER(bin_idx, BIN_USEIDX(bin_idx)) = 0;
printf("[Binary Loading] Invalid Header data, name : %s, devpath : %p\n", BIN_NAME(bin_idx), devpath);
if (--bin_count > 0) {
BIN_USEIDX(bin_idx) ^= 1;
- printf("[Binary Loading] Try to read another partition %s\n", GET_PARTNAME(BIN_USEIDX(bin_idx)));
need_update_bp = true;
+ printf("[Binary Loading] Try to read another partition %s\n", GET_PARTNAME(BIN_USEIDX(bin_idx)));
continue;
} else {
printf("[Binary Loading] No valid binary %s\n", BIN_NAME(bin_idx));
@@ -281,6 +286,7 @@ static int binary_manager_load(int bin_idx)
update_bp_data.app_data[BIN_BPIDX(bin_idx)].useidx ^= 1;
ret = binary_manager_write_bootparam(&update_bp_data);
if (ret == BINMGR_OK) {
+ binary_manager_set_bpdata(&update_bp_data);
bmvdbg("Update bootparam SUCCESS\n");
} else {
bmdbg("Failed to update bootparam, %d\n", ret);
@@ -291,8 +297,8 @@ static int binary_manager_load(int bin_idx)
if (--bin_count > 0) {
/* Change index 0 to 1 and 1 to 0. */
BIN_USEIDX(bin_idx) ^= 1;
- printf("[Binary Loading] Try to read another partition %s\n", GET_PARTNAME(BIN_USEIDX(bin_idx)));
need_update_bp = true;
+ printf("[Binary Loading] Try to read another partition %s\n", GET_PARTNAME(BIN_USEIDX(bin_idx)));
} else {
printf("[Binary Loading] No valid binary %s\n", BIN_NAME(bin_idx));
}
|
Cleanup treat_strings_as_paths | @@ -39,7 +39,7 @@ import Data.Semigroup (Semigroup(..)) -- includes (<>)
import Data.Text (Text)
import Foreign.Lua
( Lua, NumResults (..), getglobal, getmetatable, nth, pop, rawset, remove
- , setfield, top )
+ , top )
import Foreign.Lua.Call
import Foreign.Lua.Module hiding (preloadModule, pushModule)
import Foreign.Lua.Peek (Peeker, peekList, peekString)
@@ -266,21 +266,8 @@ add_extension = toHsFnPrecursor Path.addExtension
=#> [filepathResult "filepath with extension"]
#? "Adds an extension, even if there is already one."
-treat_strings_as_paths :: HaskellFunction
-treat_strings_as_paths = HaskellFunction
- { callFunction = do
- -- for some reason we can't just dump all functions into the
- -- string metatable, but have to use the string module for
- -- non-metamethods.
- pushString ""
- _ <- getmetatable top
- remove (nth 2) -- dummy string
- pushHaskellFunction add_extension *> setfield (nth 2) "__add"
- pushHaskellFunction combine *> setfield (nth 2) "__div"
- pop 1 -- string metatable
-
- getglobal "string"
- let pathFunctions =
+stringAugmentationFunctions :: [(String, HaskellFunction)]
+stringAugmentationFunctions =
[ ("directory", directory)
, ("filename", filename)
, ("is_absolute", is_absolute)
@@ -290,9 +277,22 @@ treat_strings_as_paths = HaskellFunction
, ("split_extension", split_extension)
, ("split_search_path", split_search_path)
]
- forM_ pathFunctions $ \(key, fn) -> do
- pushHaskellFunction fn
- setfield (nth 2) key
+
+treat_strings_as_paths :: HaskellFunction
+treat_strings_as_paths = HaskellFunction
+ { callFunction = do
+ let addField (k, v) =
+ pushString k *> pushHaskellFunction v *> rawset (nth 3)
+ -- for some reason we can't just dump all functions into the
+ -- string metatable, but have to use the string module for
+ -- non-metamethods.
+ pushString "" *> getmetatable top *> remove (nth 2)
+ mapM_ addField $ [("__add", add_extension), ("__div", combine)]
+ pop 1 -- string metatable
+
+ getglobal "string"
+ mapM_ addField stringAugmentationFunctions
+ pop 1 -- string module
return (0 :: NumResults)
, functionDoc = Nothing
|
Use DATAFARi_USER and DATAFARI_HOME var in scripts that did not use them | @@ -782,7 +782,7 @@ for file_entry in "${file_array[@]}"
echo $file_entry
zip -qd $file_entry org/apache/logging/log4j/core/lookup/JndiLookup.class
chmod 775 $file_entry
- chown datafari $file_entry
+ chown ${DATAFARI_USER} $file_entry
done
fi
|
Dockerfiles: Bump bcc image tag.
We recently merged a commit in our bcc's fork to synchronize the JSON key with
recent modifications in Inspektor Gadget [1].
This commit uses the last flavour of our fork image.
[1] | @@ -6,7 +6,7 @@ ARG BUILDER_IMAGE=debian:bullseye
# BCC built from the gadget branch in the kinvolk/bcc fork.
# See BCC section in docs/CONTRIBUTING.md for further details.
-ARG BCC="quay.io/kinvolk/bcc:7d56a6f6920826a62a3cc0dc7fc302bf3cdf2618-focal-release"
+ARG BCC="quay.io/kinvolk/bcc:b3b9bd12109fefce4dc31314cecdaeac5bf0d83e-focal-release"
FROM ${BCC} as bcc
FROM --platform=${BUILDPLATFORM} ${BUILDER_IMAGE} as builder
|
dev-tools/scipy: use new numpy module name | @@ -90,7 +90,7 @@ module load openblas
module load fftw
%endif
-module load numpy
+module load %{python_module_prefix}numpy
%if %{compiler_family} == intel
cat > site.cfg << EOF
@@ -125,7 +125,7 @@ LDSHARED="icc -shared" \
module load openblas
%endif
-module load numpy
+module load %{python_module_prefix}numpy
%__python setup.py install --prefix=%{install_path} --root=%{buildroot}
find %{buildroot}%{install_path}/lib64/%{python_lib_dir}/site-packages/scipy -type d -name tests | xargs rm -rf # Don't ship tests
# Don't ship weave examples, they're marked as documentation:
|
doc[validation]: remove header
resolves issue | ----
-author: Markus Raab <[email protected]>
-brief: Describes validation capabilities of Elektra.
-tags: validation, spec, metadata
-review: pending
----
-
# Validation
## Introduction
|
dill: if styled prompt has no style, emit as plain
People using older runtimes might not support the %klr blit. It's not
uncommon for prompts without style to get passed in as %pom though, so
here we catch that case and turn it into a %pro, which gets rendered as
a traditional %lin. | =. see [%lin p.bit]
(done %blit [see [%hop pos] ~])
?: ?=($pom -.bit)
+ ::NOTE treat "styled prompt" without style as plain prompt,
+ :: to allow rendering by older runtimes
+ ::TODO remove me once v0.10.9+ has high/guaranteed adoption
+ ::
+ ?: (levy p.bit (cork head |*(s=stye =(*stye s))))
+ $(bit [%pro (zing (turn p.bit tail))])
=. see [%klr p.bit]
(done %blit [see [%hop pos] ~])
?: ?=($hop -.bit)
|
Update brew java version to JDK 11
Refs
Refs | @@ -208,8 +208,8 @@ make it avaliable from the `PATH`:
```bash
brew tap homebrew/cask-versions
-brew install adoptopenjdk/openjdk/adoptopenjdk8
-export JAVA_HOME="$(/usr/libexec/java_home --version 1.8)"
+brew install adoptopenjdk/openjdk/adoptopenjdk11
+export JAVA_HOME="$(/usr/libexec/java_home --version 1.11)"
export PATH="$JAVA_HOME/bin:$PATH"
```
|
Indicate that -s can also be used for TCP/IP | @@ -221,6 +221,13 @@ scrcpy --serial 0123456789abcdef
scrcpy -s 0123456789abcdef # short version
```
+If the device is connected over TCP/IP:
+
+```bash
+scrcpy --serial 192.168.0.1:5555
+scrcpy -s 192.168.0.1:5555 # short version
+```
+
You can start several instances of _scrcpy_ for several devices.
#### SSH tunnel
|
Optimize for JSON for string prevalence and more tweaks | @@ -574,6 +574,33 @@ size_t fiobj_json2obj(fiobj_s **pobj, const void *data, size_t len) {
}
goto has_obj;
}
+ if (start[0] == '"') {
+ /* object is a string (require qoutes) */
+ start++;
+ end++;
+ uint8_t dirty = 0;
+ while (move_to_quote(&end, stop)) {
+ end += 2;
+ dirty = 1;
+ }
+ if (end >= stop) {
+ goto error;
+ }
+
+ if (fiobj_ary_index(nesting, -1) &&
+ fiobj_ary_index(nesting, -1)->type == FIOBJ_T_HASH) {
+ obj = fiobj_sym_new((char *)start, end - start);
+ if (dirty)
+ fiobj_sym_reinitialize(obj, (size_t)safestr2local(obj));
+ } else {
+ obj = fiobj_str_new((char *)start, end - start);
+ if (dirty)
+ fiobj_str_resize(obj, (size_t)safestr2local(obj));
+ }
+ end++;
+
+ goto has_obj;
+ }
if (end + 3 < stop && end[0] == 't' && end[1] == 'r' && end[2] == 'u' &&
end[3] == 'e') {
/* true */
@@ -616,33 +643,6 @@ size_t fiobj_json2obj(fiobj_s **pobj, const void *data, size_t len) {
move_to_eol(&end, stop);
continue;
}
- if (start[0] == '"') {
- /* object is a string (require qoutes) */
- start++;
- end++;
- uint8_t dirty = 0;
- while (move_to_quote(&end, stop)) {
- end += 2;
- dirty = 1;
- }
- if (end >= stop) {
- goto error;
- }
-
- if (fiobj_ary_index(nesting, -1) &&
- fiobj_ary_index(nesting, -1)->type == FIOBJ_T_HASH) {
- obj = fiobj_sym_new((char *)start, end - start);
- if (dirty)
- fiobj_sym_reinitialize(obj, (size_t)safestr2local(obj));
- } else {
- obj = fiobj_str_new((char *)start, end - start);
- if (dirty)
- fiobj_str_resize(obj, (size_t)safestr2local(obj));
- }
- end++;
-
- goto has_obj;
- }
if (end[0] == '-' || (end[0] >= '0' && end[0] <= '9')) {
/* test for a number OR float */
int64_t num = fio_atol((char **)&end);
@@ -692,9 +692,7 @@ size_t fiobj_json2obj(fiobj_s **pobj, const void *data, size_t len) {
continue;
}
if (fiobj_ary_index(nesting, -1)->type == FIOBJ_T_HASH) {
- fio_cstr_s s = fiobj_obj2cstr(obj);
- fiobj_ary_push(nesting, fiobj_sym_new(s.buffer, s.len));
- fiobj_free(obj);
+ fiobj_ary_push(nesting, obj);
continue;
}
fiobj_s *sym = fiobj_ary_pop(nesting);
|
try "master.zip" | @@ -10,7 +10,7 @@ Group: Misc
License: MIT
URL: https://github.com/indigo-dc/oidc-agent
# use `make rpmsource` to generate the required tarball
-Source0: https://github.com/indigo-dc/oidc-agent/archive/refs/tags/v%{version}.tar.gz
+Source0: https://github.com/indigo-dc/oidc-agent/archive/refs/heads/master.zip
BuildRequires: gcc >= 4.8
BuildRequires: libcurl-devel >= 7.29
|
clarify addition of verbosity level mentioned in | @@ -75,7 +75,7 @@ concurrently.
.TP
.B \-v
Increase verbosity. If given multiple times, more information is logged.
-This is in addition to the verbosity (if any) from the config file.
+This is added to the verbosity (if any) from the config file.
.TP
.B \-V
Show the version number and build options, and exit.
|
hdata/i2c: Fix 512Kb EEPROM size
There's no such thing as a 412Kb EEPROM. | @@ -105,7 +105,7 @@ static struct hdat_i2c_type hdat_i2c_devs[] = {
{ 0xb, "eeprom", "atmel,24c256" },
{ 0xc, "i2c", NULL }, /* Thermal Sensor */
{ 0xd, "eeprom", "atmel,24c04" },
- { 0xe, "eeprom", "atmel,24c412" },
+ { 0xe, "eeprom", "atmel,24c512" },
{ 0xf, "eeprom", "atmel,24c32" },
{ 0x10, "eeprom", "atmel,24c64" },
{ 0x11, "eeprom", "atmel,24c16" },
|
BugID:19944826: update help info | @@ -97,7 +97,7 @@ static struct cli_command diffcmd = {
};
static struct cli_command otacmd = { .name = "OTA_APP",
- .help = "OTA_APP pk dn ps",
+ .help = "OTA_APP pk dn ds ps",
.function = handle_ota_cmd };
#endif
|
Exit neat_pvd_handle_newaddr function if DNS packet creation fails | @@ -528,7 +528,7 @@ neat_pvd_handle_newaddr(struct neat_ctx *ctx,
free(reverse_ip);
free(pvd_result);
neat_log(ctx, NEAT_LOG_ERROR, "%s - Could not create DNS packet", __func__);
- continue;
+ return;
}
struct pvd_async_query *async_query;
|
NOTE.WIN: suggest the audetecting configuration variant as well | 5. From the root of the OpenSSL source directory enter
perl Configure VC-WIN32 if you want 32-bit OpenSSL or
- perl Configure VC-WIN64A if you want 64-bit OpenSSL
+ perl Configure VC-WIN64A if you want 64-bit OpenSSL or
+ perl Configure to let Configure figure out the platform
6. nmake
|
actions: use setup-* actions to prepare java, ruby, python env | @@ -25,6 +25,18 @@ jobs:
steps:
- uses: actions/checkout@v2
+ - uses: actions/setup-java@v1
+ with:
+ java-version: '14' # The JDK version to make available on the path.
+ java-package: jdk # (jre, jdk, or jdk+fx) - defaults to jdk
+ architecture: x64 # (x64 or x86) - defaults to x64
+ - uses: actions/setup-python@v2
+ with:
+ python-version: '3.x' # Version range or exact version of a Python version to use, using SemVer's version range syntax
+ architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
+ - uses: ruby/setup-ruby@v1
+ with:
+ ruby-version: 2.7 # Not needed with a .ruby-version file
- name: Install Dependencies
run: |
@@ -68,10 +80,7 @@ jobs:
run: |
PATH="/usr/local/opt/[email protected]/bin:/usr/local/lib/ruby/gems/2.7.0/bin:$PATH"
PATH="/usr/local/opt/[email protected]/bin:$PATH"
- echo "JAVA_HOME=$JAVA_HOME_14_X64" >> $GITHUB_ENV
echo $JAVA_HOME
- which java
- java --version
SYSTEM_DIR="$PWD/kdbsystem"
CMAKE_OPT+=(
-GNinja
@@ -111,6 +120,5 @@ jobs:
# Execute tests defined by the CMake configuration.
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail
run: |
- echo $JAVA_HOME
cmake --build . --target run_all
kdb run_all
|
io-bindings: add overview | *
* @section async Asynchronous I/O with Elektra
*
- * This section contains useful details for creating I/O bindings and using the
- * operations provided by these bindings.
+ * @subsection Overview
+ *
+ * I/O bindings allow Elektra and its plugins to integrate into different main
+ * loop APIs using a thin abstraction layer.
+ * For example, this is used for notification transport plugins which receive
+ * notifications using ZeroMQ, D-Bus, etc.
+ *
+ * I/O bindings are created using an initialization function for a specific main
+ * loop API.
+ * Please see [bindings](https://www.libelektra.org/bindings/readme)
+ * for available I/O bindings and their according READMEs for more details.
+ * After creating, an I/O binding is associated to a KDB instance using
+ * elektraIoSetBinding().
+ * Having different I/O bindings (e.g. same or differnt main loop APIs) for
+ * different KDB instances is supported.
+ *
+ * The remainder of this page contains useful details for creating I/O bindings
+ * and using the operations provided by these bindings.
* Application developers are normally not required to do those
* tasks.
* For more information about using I/O bindings from an application developer
* perspective please read the
* <a href="doc_tutorials_notifications_md.html">Notification Tutorial</a>.
*
+ * @subsection Introduction
+ *
* An I/O binding needs to handle different types of operations.
* These operations are used by plugins that require asynchronous I/O.
* In this document we will call developers of these plugins "users".
|
Change defined(_HF_ARCH_LINUX) -> defined(__linux__) for public includes | @@ -27,7 +27,7 @@ extern "C" {
*/
void HF_ITER(const uint8_t ** buf_ptr, size_t * len_ptr);
-#if defined(_HF_ARCH_LINUX)
+#if defined(__linux__)
/*
* Enter Linux namespaces
@@ -48,7 +48,7 @@ extern "C" {
*/
bool linuxMountTmpfs(const char *dst);
-#endif /* defined(_HF_ARCH_LINUX) */
+#endif /* defined(__linux__) */
#ifdef __cplusplus
} /* extern "C" */
|
Document imgtool release process | @@ -32,6 +32,19 @@ During the time between rc1 and the final release, the only changes
that should be merged into master are those to fix bugs found in the
rc and Mynewt metadata as described in the next section.
+## imgtool release
+
+imgtool is released through pypi.org (The Python package index) and
+requires that its version to be updated by editing
+`scripts/imgtool/__init__.py` and modifying the exported version:
+
+`imgtool_version = "X.Y.ZrcN"`
+
+where `rcX`, `aX` and `bX` are accepted pre-release versions (just
+numbers for final releases). For more info see:
+
+https://www.python.org/dev/peps/pep-0440/#pre-releases
+
## Mynewt release information
On Mynewt, `newt` always fetches a versioned MCUBoot release, so after
|
fix generated cmakelists when using `set_languages("c++latest")` | @@ -450,6 +450,7 @@ function _add_target_languages(cmakelists, target)
, cxx14 = "cxx_std_14"
, cxx17 = "cxx_std_17"
, cxx20 = "cxx_std_20"
+ , cxxlatest = "cxx_std_23"
}
local languages = target:get("languages")
if languages then
|
tests: internal: gelf: add test case for msec
It detects | @@ -50,7 +50,52 @@ void test_gelf_pack()
msgpack_sbuffer_destroy(&mp_sbuf);
}
+#define EXPECTED_OUT_MSEC \
+ "{\"version\":\"1.1\", \"short_message\":\"true, 2019, str\", \"_t2\":\"false\", \"timestamp\":337647600.012}"
+
+/* https://github.com/fluent/fluent-bit/issues/3727 */
+void test_gelf_pack_msec()
+{
+ msgpack_sbuffer mp_sbuf;
+ msgpack_packer mp_pck;
+ struct flb_time ts;
+ struct flb_gelf_fields fields = {0};
+ flb_sds_t out;
+
+ /* Pack sample msgpack */
+ msgpack_sbuffer_init(&mp_sbuf);
+ msgpack_packer_init(&mp_pck, &mp_sbuf, msgpack_sbuffer_write);
+
+
+ ts.tm.tv_sec = 337647600;
+ ts.tm.tv_nsec = 12341111; /* 12.34msec */
+
+ msgpack_pack_map(&mp_pck, 2);
+ msgpack_pack_str(&mp_pck, 2);
+ msgpack_pack_str_body(&mp_pck, "t1", 2);
+ msgpack_pack_array(&mp_pck, 3);
+ msgpack_pack_true(&mp_pck);
+ msgpack_pack_uint64(&mp_pck, 2019);
+ msgpack_pack_str(&mp_pck, 3);
+ msgpack_pack_str_body(&mp_pck, "str", 3);
+ msgpack_pack_str(&mp_pck, 2);
+ msgpack_pack_str_body(&mp_pck, "t2", 2);
+ msgpack_pack_false(&mp_pck);
+
+ fields.short_message_key = flb_sds_create("t1");
+ out = flb_msgpack_raw_to_gelf(mp_sbuf.data, mp_sbuf.size, &ts, &fields);
+ TEST_CHECK(out != NULL);
+
+ if(!TEST_CHECK(strcmp(out, EXPECTED_OUT_MSEC) == 0)) {
+ TEST_MSG("out=%s", out);
+ }
+ flb_sds_destroy(out);
+ flb_sds_destroy(fields.short_message_key);
+ msgpack_sbuffer_destroy(&mp_sbuf);
+}
+
TEST_LIST = {
{"gelf_pack", test_gelf_pack},
+ {"gelf_pack_msec", test_gelf_pack_msec},
{ 0 }
};
|
Change signature of PersistPaymentsAsync | @@ -152,12 +152,10 @@ public abstract class PayoutHandlerBase
}
}
- protected async Task PersistPaymentsAsync(Balance[] balances, string[] transactionConfirmations)
+ protected async Task PersistPaymentsAsync(Dictionary<Balance, string> balances)
{
Contract.RequiresNonNull(balances);
- Contract.RequiresNonNull(transactionConfirmations);
- Contract.Requires<ArgumentException>(balances.Length > 0);
- Contract.Requires<ArgumentException>(balances.Length == transactionConfirmations.Length);
+ Contract.Requires<ArgumentException>(balances.Count > 0);
var coin = poolConfig.Template.As<CoinTemplate>();
@@ -167,10 +165,9 @@ public abstract class PayoutHandlerBase
{
await cf.RunTx(async (con, tx) =>
{
- for(var i = 0; i < balances.Length; i++)
+ foreach(var kvp in balances)
{
- var balance = balances[i];
- var transactionConfirmation = transactionConfirmations[i];
+ var (balance, transactionConfirmation) = kvp;
if(!string.IsNullOrEmpty(transactionConfirmation) && poolConfig.RewardRecipients.All(x => x.Address != balance.Address))
{
@@ -199,7 +196,7 @@ public abstract class PayoutHandlerBase
catch(Exception ex)
{
logger.Error(ex, () => $"[{LogCategory}] Failed to persist the following payments: " +
- $"{JsonConvert.SerializeObject(balances.Where(x => x.Amount > 0).ToDictionary(x => x.Address, x => x.Amount))}");
+ $"{JsonConvert.SerializeObject(balances.Where(x => x.Key.Amount > 0).ToDictionary(x => x.Key.Address, x => x.Key.Amount))}");
throw;
}
}
|
Avoid clobbering CMAKE_C_FLAGS for bist tool
Set CMAKE_C_FLAGS for bist tool to include ${CMAKE_C_FLAGS} to avoid overriding default flags | @@ -29,7 +29,7 @@ include_directories(${OPAE_INCLUDE_DIR}
add_executable(bist_app bist_afu.c)
set_install_rpath(bist_app)
-set(CMAKE_C_FLAGS "-std=c99")
+set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99")
target_link_libraries(bist_app opae-c json-c uuid rt ${CMAKE_THREAD_LIBS_INIT})
install(TARGETS bist_app
|
viofs-svc: fixed ReadDirectory behaviour | @@ -1446,6 +1446,7 @@ static NTSTATUS ReadDirectory(FSP_FILE_SYSTEM *FileSystem,
Remains = read_out->hdr.len - sizeof(struct fuse_out_header);
if (Remains == 0)
{
+ // A successful request with no data means no more entries.
break;
}
@@ -1471,7 +1472,7 @@ static NTSTATUS ReadDirectory(FSP_FILE_SYSTEM *FileSystem,
if (FileNameLength > 0)
{
DirInfo->Size = (UINT16)(sizeof(FSP_FSCTL_DIR_INFO) +
- (FileNameLength + 1) * sizeof(WCHAR));
+ FileNameLength * sizeof(WCHAR));
SetFileInfo(&DirEntryPlus->entry_out.attr,
&DirInfo->FileInfo);
@@ -1553,8 +1554,8 @@ static NTSTATUS ReadDirectory(FSP_FILE_SYSTEM *FileSystem,
ZeroMemory(DirInfoBuf, sizeof(DirInfoBuf));
- // Not using FspPosixMapPosixToWindowsPath so we can do an in-place
- // mapping.
+ // Not using FspPosixMapPosixToWindowsPath so we can do the conversion
+ // in-place.
FileNameLength = MultiByteToWideChar(CP_UTF8, 0, dirent->dirent.name,
dirent->dirent.namelen, DirInfo->FileNameBuf, MAX_PATH);
@@ -1563,7 +1564,7 @@ static NTSTATUS ReadDirectory(FSP_FILE_SYSTEM *FileSystem,
if (FileNameLength > 0)
{
DirInfo->Size = (UINT16)(sizeof(FSP_FSCTL_DIR_INFO) +
- (FileNameLength + 1) * sizeof(WCHAR));
+ FileNameLength * sizeof(WCHAR));
SetFileInfo(&dirent->entry_out.attr, &DirInfo->FileInfo);
@@ -1686,7 +1687,7 @@ static NTSTATUS SvcStart(FSP_SERVICE *Service, ULONG argc, PWSTR *argv)
// VolumeParams.PassQueryDirectoryPattern = 1;
VolumeParams.FlushAndPurgeOnCleanup = 1;
VolumeParams.UmFileContextIsUserContext2 = 1;
- VolumeParams.DirectoryMarkerAsNextOffset = 1;
+// VolumeParams.DirectoryMarkerAsNextOffset = 1;
if (VolumePrefix != NULL)
{
wcscpy_s(VolumeParams.Prefix,
|
Changed default ws2812 freq to 800khz | @@ -29,7 +29,7 @@ namespace plasma {
public:
static const uint SERIAL_FREQ_400KHZ = 400000;
static const uint SERIAL_FREQ_800KHZ = 800000;
- static const uint DEFAULT_SERIAL_FREQ = SERIAL_FREQ_400KHZ;
+ static const uint DEFAULT_SERIAL_FREQ = SERIAL_FREQ_800KHZ;
enum class COLOR_ORDER {
RGB,
RBG,
|
ur: refactors indirect-atom (re-)allocation | @@ -482,16 +482,12 @@ _coin_unsafe(ur_atoms_t *atoms, ur_mug mug, uint8_t *byt, uint64_t len)
uint64_t fill = atoms->fill;
ur_tag tag = ur_iatom;
ur_nref tom = ( fill | ((uint64_t)tag << 62) );
- uint8_t *copy = malloc(len);
// XX necessary?
//
assert( 62 >= ur_met0_64(fill) );
- assert(copy);
- memcpy(copy, byt, len);
-
- atoms->bytes[fill] = copy;
+ atoms->bytes[fill] = byt;
atoms->lens[fill] = len;
atoms->mugs[fill] = mug;
atoms->fill = 1 + fill;
@@ -584,7 +580,11 @@ ur_coin_bytes(ur_root_t *r, uint8_t *byt, uint64_t len)
return (ur_nref)direct;
}
else {
- return _coin_bytes_unsafe(r, byt, len);
+ uint8_t *copy = malloc(len);
+ assert( copy );
+ memcpy(copy, byt, len);
+
+ return _coin_bytes_unsafe(r, copy, len);
}
}
@@ -595,9 +595,20 @@ ur_coin64(ur_root_t *r, uint64_t n)
return n;
}
else {
- // XX little-endian
- //
- return _coin_bytes_unsafe(r, (uint8_t*)&n, ur_met3_64(n));
+ uint8_t *byt = malloc(8);
+ assert( byt );
+ assert( 8 == ur_met3_64(n) );
+
+ byt[0] = ur_mask_8(n);
+ byt[1] = ur_mask_8(n >> 8);
+ byt[2] = ur_mask_8(n >> 16);
+ byt[3] = ur_mask_8(n >> 24);
+ byt[4] = ur_mask_8(n >> 32);
+ byt[5] = ur_mask_8(n >> 40);
+ byt[6] = ur_mask_8(n >> 48);
+ byt[7] = ur_mask_8(n >> 56);
+
+ return _coin_bytes_unsafe(r, byt, 8);
}
}
|
Note about macOS limitations | @@ -23,7 +23,7 @@ Iodine is an **evented** framework with a simple API that builds off the low lev
* Iodine can handle **thousands of concurrent connections** (tested with more then 20K connections)!
-* Iodine supports only **Linux/Unix** based systems (i.e. macOS, Ubuntu, FreeBSD etc'), which are ideal for evented IO (while Windows and Solaris are better at IO *completion* events, which are totally different).
+* Iodine supports only **Linux/Unix** based systems (i.e. macOS, Ubuntu, FreeBSD etc'), which are ideal for evented IO (while Windows and Solaris are better at IO *completion* events, which are totally different). Currently, macOS support is limited to 10.12 or higher (see [issue #32](https://github.com/boazsegev/iodine/issues/32))
Iodine is a C extension for Ruby, developed and optimized for Ruby MRI 2.2.2 and up... it should support the whole Ruby 2.0 MRI family, but Rack requires Ruby 2.2.2, and so iodine matches this requirement.
|
silence coverity issue
coverity complains about an invalid type in argument to printf
format specifier. Although this is obviously a false positive,
a simple cast should prevent coverity from complaining. | @@ -63,7 +63,7 @@ struct framework_logger {
#define framework_logIfError(logger, status, error, fmsg, args...) \
if (status != CELIX_SUCCESS) { \
if (error != NULL) { \
- fw_logCode(logger, OSGI_FRAMEWORK_LOG_ERROR, status, #fmsg";\n Cause: %s", ## args, error); \
+ fw_logCode(logger, OSGI_FRAMEWORK_LOG_ERROR, status, #fmsg";\n Cause: %s", ## args, (char*) error); \
} else { \
fw_logCode(logger, OSGI_FRAMEWORK_LOG_ERROR, status, #fmsg, ## args); \
} \
|
Adjust which GHC versions are used on Travis CI
Testing with all major GHC versions doesn't add much value, remove two
older versions (but always test with the oldest supported version). | @@ -14,18 +14,10 @@ matrix:
- env: GHCVER=7.10.3 CABALVER=1.22 LUAVER=default
compiler: ": #GHC 7.10.3"
addons: {apt: {packages: [cabal-install-1.22,ghc-7.10.3], sources: [hvr-ghc]}}
- # Test GHC 8.0.2
- - env: GHCVER=8.0.2 CABALVER=1.24 LUAVER=default
- compiler: ": #GHC 8.0.2"
- addons: {apt: {packages: [cabal-install-1.24,ghc-8.0.2], sources: [hvr-ghc]}}
- # Test GHC 8.2.2
- - env: GHCVER=8.2.2 CABALVER=1.24 LUAVER=default
- compiler: ": #GHC 8.2.2"
- addons: {apt: {packages: [cabal-install-1.24,ghc-8.2.2], sources: [hvr-ghc]}}
# Test GHC 8.4.1
- - env: GHCVER=8.4.1 CABALVER=2.0 LUAVER=default
- compiler: ": #GHC 8.4.1"
- addons: {apt: {packages: [cabal-install-2.0,ghc-8.4.1], sources: [hvr-ghc]}}
+ - env: GHCVER=8.4.2 CABALVER=2.0 LUAVER=default
+ compiler: ": #GHC 8.4.2"
+ addons: {apt: {packages: [cabal-install-2.0,ghc-8.4.2], sources: [hvr-ghc]}}
## Test Lua versions
# Test system Lua 5.1
@@ -40,14 +32,14 @@ matrix:
- env: GHCVER=8.0.2 CABALVER=1.24 LUAVER=lua-5.3.4
compiler: ": #GHC 8.0.2"
addons: {apt: {packages: [cabal-install-1.24,ghc-8.0.2], sources: [hvr-ghc]}}
- # Test luajit
- - env: GHCVER=8.0.2 CABALVER=1.24 LUAVER=luajit
- compiler: ": #GHC 8.0.2"
- addons: {apt: {packages: [cabal-install-1.24,ghc-8.0.2], sources: [hvr-ghc]}}
# Test GHC 7.10 and LuaJIT
- env: GHCVER=7.10.3 CABALVER=1.22 LUAVER=luajit
compiler: ": #GHC 7.10.3"
addons: {apt: {packages: [cabal-install-1.22,ghc-7.10.3], sources: [hvr-ghc]}}
+ # Test GHC 8.4 and LuaJIT
+ - env: GHCVER=8.4.2 CABALVER=2.0 LUAVER=luajit
+ compiler: ": #GHC 8.4.2"
+ addons: {apt: {packages: [cabal-install-2.0,ghc-8.4.2], sources: [hvr-ghc]}}
# mark build as successful as soon as all required successes are in.
fast_finish: true
|
netMutex becomes RWMutex, protects some additional reads. | @@ -61,12 +61,12 @@ type serialConnection struct {
var messageQueue chan networkMessage
var outSockets map[string]networkConnection
var dhcpLeases map[string]string
-var netMutex *sync.Mutex
+var netMutex *sync.RWMutex
var totalNetworkMessagesSent uint32
var pingResponse map[string]time.Time // Last time an IP responded to an "echo" response.
-var pingResponseMutex sync.RWMutex // For versions of Go after 1.6 we need to protect this map from concurrent reads & writes
+var pingResponseMutex *sync.RWMutex // For versions of Go after 1.6 we need to protect this map from concurrent reads & writes
const (
NETWORK_GDL90_STANDARD = 1
@@ -283,6 +283,8 @@ func getNetworkStats() {
var numNonSleepingClients uint
+ netMutex.RLock()
+ defer netMutex.RUnlock()
for k, netconn := range outSockets {
queueBytes := 0
for _, msg := range netconn.messageQueue {
@@ -466,10 +468,12 @@ func icmpEchoSender(c *icmp.PacketConn) {
<-timer.C
// Collect IPs.
ips := make(map[string]bool)
+ netMutex.RLock()
for k, _ := range outSockets {
ipAndPort := strings.Split(k, ":")
ips[ipAndPort[0]] = true
}
+ netMutex.RUnlock()
// Send to all IPs.
for ip, _ := range ips {
wm := icmp.Message{
@@ -637,7 +641,8 @@ func initNetwork() {
networkGDL90Chan = make(chan []byte, 1024)
outSockets = make(map[string]networkConnection)
pingResponse = make(map[string]time.Time)
- netMutex = &sync.Mutex{}
+ netMutex = &sync.RWMutex{}
+ pingResponseMutex = &sync.RWMutex{}
refreshConnectedClients()
go monitorDHCPLeases()
go messageQueueSender()
|
decision: improve confusing sentence | @@ -63,7 +63,7 @@ For each solution a proposal, rationale and optionally implications should be gi
- Now it is allowed to have the decision from the previous round in the "Decision" section.
> For decisions "In Progress", unlike "In Discussion", also the solution space next to the problem is clear.
-> It is the highest of the steps reachable for a decision PR that started in "Drafts".
+> Without merges in between, this is the last step reachable for a decision PR that started in "Drafts".
## Decided
|
readability: '.port=port' isn't helpful, it's just 53 | @@ -285,11 +285,11 @@ const dnsconnect = {ns
match ns
| `Ipv4 bits:
- sa4=[.fam=sys.Afinet, .addr=bits, .port=hosttonet(port)]
+ sa4=[.fam=sys.Afinet, .addr=bits, .port=hosttonet(53)]
sa = (&sa4 : sys.sockaddr#)
sz = sizeof(sys.sockaddr_in)
| `Ipv6 bits:
- sa6=[.fam=sys.Afinet6, .addr=bits, .port=hosttonet(port)]
+ sa6=[.fam=sys.Afinet6, .addr=bits, .port=hosttonet(53)]
sa = (&sa6 : sys.sockaddr#)
sz = sizeof(sys.sockaddr_in6)
;;
|
improve package.tools.meson | @@ -56,7 +56,7 @@ function _get_configs(package, configs, opt)
table.insert(configs, "--libdir=lib")
-- set build type
- table.insert(configs, "--buildtype=" .. (package:debug() and "debug" or "release"))
+ table.insert(configs, "-Dbuildtype=" .. (package:debug() and "debug" or "release"))
-- add -fpic
if package:is_plat("linux") and package:config("pic") then
|
Highlight selected option if show_selected is false | @@ -825,12 +825,10 @@ static lv_design_res_t lv_dropdown_page_design(lv_obj_t * page, const lv_area_t
draw_box(ddlist, &clip_area_core, ext->pr_opt_id, LV_STATE_PRESSED);
}
- if(ext->show_selected) {
draw_box(ddlist, &clip_area_core, ext->sel_opt_id, LV_STATE_DEFAULT);
}
}
}
- }
/*Post draw when the children are drawn*/
else if(mode == LV_DESIGN_DRAW_POST) {
/*Draw the scrollbar in the ancestor page design function*/
@@ -853,12 +851,10 @@ static lv_design_res_t lv_dropdown_page_design(lv_obj_t * page, const lv_area_t
draw_box_label(ddlist, &clip_area_core, ext->pr_opt_id, LV_STATE_PRESSED);
}
- if(ext->show_selected) {
draw_box_label(ddlist, &clip_area_core, ext->sel_opt_id, LV_STATE_DEFAULT);
}
}
}
- }
return LV_DESIGN_RES_OK;
}
|
Use strtol instead of atoi in asn1parse | @@ -113,13 +113,13 @@ int asn1parse_main(int argc, char **argv)
offset = strtol(opt_arg(), NULL, 0);
break;
case OPT_LENGTH:
- length = atoi(opt_arg());
+ length = strtol(opt_arg(), NULL, 0);
break;
case OPT_DUMP:
dump = -1;
break;
case OPT_DLIMIT:
- dump = atoi(opt_arg());
+ dump = strtol(opt_arg(), NULL, 0);
break;
case OPT_STRPARSE:
sk_OPENSSL_STRING_push(osk, opt_arg());
@@ -225,7 +225,7 @@ int asn1parse_main(int argc, char **argv)
for (i = 0; i < sk_OPENSSL_STRING_num(osk); i++) {
ASN1_TYPE *atmp;
int typ;
- j = atoi(sk_OPENSSL_STRING_value(osk, i));
+ j = strtol(sk_OPENSSL_STRING_value(osk, i), NULL, 0);
if (j <= 0 || j >= tmplen) {
BIO_printf(bio_err, "'%s' is out of range\n",
sk_OPENSSL_STRING_value(osk, i));
|
Increase size of swap testing images
Make images slightly larger to allow more swap status metadata to be
written to flash, to increase amount of debugging info and possibility
of failures on random write fails. | @@ -140,8 +140,8 @@ impl ImagesBuilder {
pub fn make_no_upgrade_image(self) -> Images {
let mut flash = self.flash;
let images = self.slots.into_iter().map(|slots| {
- let primaries = install_image(&mut flash, &slots, 0, 32784, false);
- let upgrades = install_image(&mut flash, &slots, 1, 41928, false);
+ let primaries = install_image(&mut flash, &slots, 0, 42784, false);
+ let upgrades = install_image(&mut flash, &slots, 1, 46928, false);
OneImage {
slots: slots,
primaries: primaries,
|
OcAppleKernelLib: Fix TSC/FSB for AMD CPUs in ProvideCurrentCpuInfo | @@ -1418,6 +1418,19 @@ PatchProvideCurrentCpuInfo (
//
// Perform TSC and FSB calculations. This is traditionally done in tsc.c in XNU.
//
+ // For AMD Processors
+ if ((CpuInfo->Family == 0xF) && ((CpuInfo->ExtFamily == 0x8) || (CpuInfo->ExtFamily == 0xA))) {
+ DEBUG ((DEBUG_INFO, "OCAK: Setting FSB and TSC for Family 0x%x and ExtFamily 0x%x\n", (UINT16)CpuInfo->Family, (UINT16)CpuInfo->ExtFamily));
+ busFreqValue = CpuInfo->FSBFrequency;
+ busFCvtt2nValue = DivU64x64Remainder ((1000000000ULL << 32), busFreqValue, NULL);
+ busFCvtn2tValue = DivU64x64Remainder ((1000000000ULL << 32), busFCvtt2nValue, NULL);
+
+ tscFreqValue = CpuInfo->CPUFrequency;
+ tscFCvtt2nValue = DivU64x64Remainder ((1000000000ULL << 32), tscFreqValue, NULL);
+ tscFCvtn2tValue = DivU64x64Remainder ((1000000000ULL << 32), tscFCvtt2nValue, NULL);
+ }
+ // For all other processors
+ else {
busFreqValue = CpuInfo->FSBFrequency;
busFCvtt2nValue = DivU64x64Remainder ((1000000000ULL << 32), busFreqValue, NULL);
busFCvtn2tValue = DivU64x64Remainder (0xFFFFFFFFFFFFFFFFULL, busFCvtt2nValue, NULL);
@@ -1425,6 +1438,7 @@ PatchProvideCurrentCpuInfo (
tscFreqValue = CpuInfo->CPUFrequency;
tscFCvtt2nValue = DivU64x64Remainder ((1000000000ULL << 32), tscFreqValue, NULL);
tscFCvtn2tValue = DivU64x64Remainder (0xFFFFFFFFFFFFFFFFULL, tscFCvtt2nValue, NULL);
+ }
tscGranularityValue = DivU64x64Remainder (tscFreqValue, busFreqValue, NULL);
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.