message
stringlengths 6
474
| diff
stringlengths 8
5.22k
|
---|---|
evp_extra_test: Remove TODO comment as setting the curve is mandatory
Even with the SM2 algorithm the curve is needed for the paramgen. | @@ -1319,7 +1319,6 @@ static int test_EVP_SM2(void)
if (!TEST_true(EVP_PKEY_paramgen_init(pctx) == 1))
goto done;
- /* TODO is this even needed? */
if (!TEST_true(EVP_PKEY_CTX_set_ec_paramgen_curve_nid(pctx, NID_sm2)))
goto done;
|
hw/mcu/dialog: Remove legacy settings for lpclk
Choice syscfg is preferred way to set lpclk. | @@ -343,19 +343,6 @@ syscfg.defs:
restrictions:
- '!GPADC_BATTERY'
- LP_RCX:
- description:
- value: 0
-
- LP_XTAL32K:
- description:
- value: 0
-
-syscfg.vals.LP_RCX:
- MCU_LPCLK_SOURCE: RCX
-syscfg.vals.LP_XTAL32K:
- MCU_LPCLK_SOURCE: XTAL32K
-
syscfg.restrictions:
- "QSPI_FLASH_ADDRESS_LENGTH==24"
- "!I2C_0 || (I2C_0_PIN_SCL && I2C_0_PIN_SDA)"
|
feat(coder) Implement int->float casts | @@ -848,11 +848,27 @@ generate_exp = function(exp) -- TODO
end
elseif tag == ast.Exp.Cast then
+ local cstats, cvalue = generate_exp(exp.exp)
+
+ local src_typ = exp.exp._type
+ local dst_typ = exp._type
+
+ if src_typ._tag == dst_typ._tag then
+ return cstats, cvalue
+
+ elseif src_typ._tag == types.T.Integer and dst_typ._tag == types.T.Float then
+ return cstats, "((lua_Number)"..cvalue..")"
+
+ elseif src_typ._tag == types.T.Float and dst_typ._tag == types.T.Integer then
error("not implemented yet")
else
error("impossible")
end
+
+ else
+ error("impossible")
+ end
end
return coder
|
HW: Adding reset values for regX_data to action_memcopy.vhd in order to get around 'partial antenna' image build problem | @@ -716,8 +716,11 @@ read_write_process:
tail <= 0;
head <= 0;
reg0_valid <= '0';
+ reg0_data <= dma_rd_data;
reg1_valid <= '0';
+ reg1_data <= dma_rd_data;
reg2_valid <= '0';
+ reg2_data <= dma_rd_data;
write_counter_up <= (25 downto 1 => '0') & '1';
write_counter_dn <= blocks_to_write(25 downto 0);
else
|
common/util_stdlib.c: Format with clang-format
BRANCH=none
TEST=none | @@ -134,8 +134,7 @@ __stdlib_compat int atoi(const char *nptr)
return neg ? -result : result;
}
-__keep
-__stdlib_compat int memcmp(const void *s1, const void *s2, size_t len)
+__keep __stdlib_compat int memcmp(const void *s1, const void *s2, size_t len)
{
const char *sa = s1;
const char *sb = s2;
@@ -151,8 +150,7 @@ __stdlib_compat int memcmp(const void *s1, const void *s2, size_t len)
}
#if !(__has_feature(address_sanitizer) || __has_feature(memory_sanitizer))
-__keep
-__stdlib_compat void *memcpy(void *dest, const void *src, size_t len)
+__keep __stdlib_compat void *memcpy(void *dest, const void *src, size_t len)
{
char *d = (char *)dest;
const char *s = (const char *)src;
@@ -197,8 +195,7 @@ __stdlib_compat void *memcpy(void *dest, const void *src, size_t len)
#endif /* address_sanitizer || memory_sanitizer */
#if !(__has_feature(address_sanitizer) || __has_feature(memory_sanitizer))
-__keep
-__stdlib_compat __visible void *memset(void *dest, int c, size_t len)
+__keep __stdlib_compat __visible void *memset(void *dest, int c, size_t len)
{
char *d = (char *)dest;
uint32_t cccc;
@@ -237,8 +234,7 @@ __stdlib_compat __visible void *memset(void *dest, int c, size_t len)
#endif /* address_sanitizer || memory_sanitizer */
#if !(__has_feature(address_sanitizer) || __has_feature(memory_sanitizer))
-__keep
-__stdlib_compat void *memmove(void *dest, const void *src, size_t len)
+__keep __stdlib_compat void *memmove(void *dest, const void *src, size_t len)
{
if ((uintptr_t)dest <= (uintptr_t)src ||
(uintptr_t)dest >= (uintptr_t)src + len) {
@@ -326,7 +322,6 @@ __stdlib_compat int strncmp(const char *s1, const char *s2, size_t n)
break;
s1++;
s2++;
-
}
return 0;
}
|
[build] Add global .pb.cc when build python proto libraries to increase protobuf performance | import os
import ymake
-from _common import stripext, rootrel_arc_src
+from _common import stripext, rootrel_arc_src, listid
from pyx import PyxParser
@@ -22,6 +22,14 @@ def pb2_arg(path, mod, unit):
return '{}_pb2.py={}_pb2'.format(stripext(to_build_root(path, unit)), mod)
+def pb_cc_arg(path, unit):
+ return '{}.pb.cc'.format(stripext(to_build_root(path, unit)))
+
+
+def ev_cc_arg(path, unit):
+ return '{}.ev.pb.cc'.format(stripext(to_build_root(path, unit)))
+
+
def pb2_grpc_arg(path, mod, unit):
return '{}_pb2_grpc.py={}_pb2_grpc'.format(stripext(to_build_root(path, unit)), mod)
@@ -131,7 +139,8 @@ def onpy_srcs(unit, *args):
if '/library/python/runtime' not in unit.path():
unit.onpeerdir(['library/python/runtime'])
- if unit.get('MODULE_TYPE') == 'PROGRAM':
+ is_program = unit.get('MODULE_TYPE') == 'PROGRAM'
+ if is_program:
py_program(unit)
py_namespace_value = unit.get('PY_NAMESPACE_VALUE')
@@ -260,10 +269,19 @@ def onpy_srcs(unit, *args):
grpc = unit.get('GRPC_FLAG') == 'yes'
if grpc:
- unit.onpeerdir(['contrib/libs/grpc/python'])
+ unit.onpeerdir(['contrib/libs/grpc/python', 'contrib/libs/grpc'])
- unit.ongenerate_py_protos([path for path, mod in protos])
+ proto_paths = [path for path, mod in protos]
+ unit.ongenerate_py_protos(proto_paths)
unit.onpy_srcs([pb2_arg(path, mod, unit) for path, mod in protos])
+ unit.onsrcs(proto_paths)
+
+ if not is_program:
+ pb_cc_outs = [pb_cc_arg(path, unit) for path in proto_paths]
+ if len(pb_cc_outs) > 1:
+ unit.onjoin_srcs_global(['join_' + listid(pb_cc_outs) + '.cpp'] + pb_cc_outs)
+ else:
+ unit.onsrcs(['GLOBAL'] + pb_cc_outs)
if grpc:
unit.onpy_srcs([pb2_grpc_arg(path, mod, unit) for path, mod in protos])
@@ -274,6 +292,14 @@ def onpy_srcs(unit, *args):
unit.ongenerate_py_evs([path for path, mod in evs])
unit.onpy_srcs([ev_arg(path, mod, unit) for path, mod in evs])
+ unit.onsrcs([path for path, mod in evs])
+
+ if not is_program:
+ pb_cc_outs = [ev_cc_arg(path, unit) for path, _ in evs]
+ if len(pb_cc_outs) > 1:
+ unit.onjoin_srcs_global(['join_' + listid(pb_cc_outs) + '.cpp'] + pb_cc_outs)
+ else:
+ unit.onsrcs(['GLOBAL'] + pb_cc_outs)
if swigs:
unit.onsrcs(swigs)
|
s5j: add netif flags on wlan_init function
This commit is to add netif flags for lwIP stack
- to handle ARP, Broadcast and IGMP multicast packets,
those flags should be configured on netif | @@ -112,5 +112,7 @@ err_t wlan_init(struct netif *netif)
snprintf(netif->d_ifname, IFNAMSIZ, "%c%c%d", netif->name[0], netif->name[1], netif->num);
+ netif->flags = NETIF_FLAG_ETHARP | NETIF_FLAG_ETHERNET | NETIF_FLAG_BROADCAST | NETIF_FLAG_IGMP;
+
return ERR_OK;
}
|
Reordered changes for 1.25.0 by significance (subjective). | @@ -33,7 +33,7 @@ NGINX Unit updated to 1.25.0.
<change type="feature">
<para>
-TLS session tickets.
+client IP address replacement from a specified HTTP header field.
</para>
</change>
@@ -45,7 +45,7 @@ TLS sessions cache.
<change type="feature">
<para>
-process and thread lifecycle hooks in Ruby.
+TLS session tickets.
</para>
</change>
@@ -57,22 +57,21 @@ application restart control.
<change type="feature">
<para>
-client IP address replacement from a specified HTTP header field.
+process and thread lifecycle hooks in Ruby.
</para>
</change>
<change type="bugfix">
<para>
-TLS connections were rejected for configurations with multiple
-certificate bundles in a listener if the client did not use SNI.
+the router process could crash on TLS connection open when multiple listeners
+with TLS certificates were configured; the bug had appeared in 1.23.0.
</para>
</change>
-
<change type="bugfix">
<para>
-the router process could crash on TLS connection open when multiple listeners
-with TLS certificates were configured; the bug had appeared in 1.23.0.
+TLS connections were rejected for configurations with multiple certificate
+bundles in a listener if the client did not use SNI.
</para>
</change>
@@ -85,22 +84,22 @@ reconfiguration.
<change type="bugfix">
<para>
-a descriptor and memory leak occurred in the router process when an app
-process stopped or crashed.
+compatibility issues with some Python ASGI apps, notably based on the Starlette
+framework.
</para>
</change>
<change type="bugfix">
<para>
-the controller or router process could crash if the configuration contained
-a full-form IPv6 in a listener address.
+a descriptor and memory leak occurred in the router process when an app process
+stopped or crashed.
</para>
</change>
<change type="bugfix">
<para>
-compatibility issues with some Python ASGI apps, notably based on the Starlette
-framework.
+the controller or router process could crash if the configuration contained
+a full-form IPv6 in a listener address.
</para>
</change>
@@ -113,8 +112,8 @@ or "upstreams" using a variable "pass" option.
<change type="bugfix">
<para>
-the router process crashed while matching a request to an empty array of
-source or destination address patterns.
+the router process crashed while matching a request to an empty array of source
+or destination address patterns.
</para>
</change>
|
Fix error numeration | @@ -555,7 +555,7 @@ static int add_block_nolock(struct xdag_block *newBlock, xtime_t limit)
/* check remark */
if(tmpNodeBlock.flags & BI_REMARK) {
if(!remark_acceptance(newBlock->field[remark_index].remark)) {
- err = 0xC;
+ err = 0xE;
goto end;
}
}
@@ -732,7 +732,7 @@ static int add_block_nolock(struct xdag_block *newBlock, xtime_t limit)
if(!insert_index(nodeBlock)) {
g_xdag_stats.nblocks++;
} else {
- err = 0xC;
+ err = 0xD;
goto end;
}
|
Test automation: Fixed some pylint remarks for u_run_zephyr.py | @@ -211,7 +211,7 @@ def download_single_cpu(connection, jlink_device_name, guard_time_seconds, build
return u_utils.exe_run(call_list, guard_time_seconds, printer, prompt,
shell_cmd=True, set_env=env)
-def download_nrf53(connection, jlink_device_name, guard_time_seconds, build_dir, env, printer, prompt):
+def download_nrf53(connection, guard_time_seconds, build_dir, env, printer, prompt):
cpunet_hex_path = os.path.join(build_dir, "hci_rpmsg", "zephyr", "merged_CPUNET.hex")
success = True
if os.path.exists(cpunet_hex_path):
@@ -221,7 +221,8 @@ def download_nrf53(connection, jlink_device_name, guard_time_seconds, build_dir,
if connection and "debugger" in connection and connection["debugger"]:
call_list.extend(["-s", connection["debugger"]])
print_call_list(call_list, printer, prompt)
- success = u_utils.exe_run(call_list, guard_time_seconds, printer, prompt, shell_cmd=True, set_env=env)
+ success = u_utils.exe_run(call_list, guard_time_seconds, printer,
+ prompt, shell_cmd=True, set_env=env)
if success:
# Give nrfjprog some time to relax
sleep(10)
@@ -231,14 +232,15 @@ def download_nrf53(connection, jlink_device_name, guard_time_seconds, build_dir,
if connection and "debugger" in connection and connection["debugger"]:
call_list.extend(["-s", connection["debugger"]])
print_call_list(call_list, printer, prompt)
- success = u_utils.exe_run(call_list, guard_time_seconds, printer, prompt, shell_cmd=True, set_env=env)
+ success = u_utils.exe_run(call_list, guard_time_seconds, printer,
+ prompt, shell_cmd=True, set_env=env)
return success
def download(connection, jlink_device_name, guard_time_seconds,
build_dir, env, printer, prompt):
'''Download the given hex file(s)'''
if jlink_device_name == "nRF5340_XXAA_APP":
- success = download_nrf53(connection, jlink_device_name, guard_time_seconds,
+ success = download_nrf53(connection, guard_time_seconds,
build_dir, env, printer, prompt)
else:
success = download_single_cpu(connection, jlink_device_name, guard_time_seconds,
@@ -437,7 +439,8 @@ def run(instance, mcu, toolchain, connection, connection_lock,
reporter.event(u_report.EVENT_TYPE_TEST,
u_report.EVENT_START)
- with URttReader(jlink_device(mcu), jlink_serial=connection["debugger"]) as rtt_reader:
+ with URttReader(jlink_device(mcu),
+ jlink_serial=connection["debugger"]) as rtt_reader:
return_value = u_monitor.main(rtt_reader,
u_monitor.CONNECTION_RTT,
RUN_GUARD_TIME_SECONDS,
|
power/alderlake_slg4bd44540.c: Format with clang-format
BRANCH=none
TEST=none | #define GPIO_SET_LEVEL(signal, value) \
gpio_set_level_verbose(CC_CHIPSET, signal, value)
#else
-#define GPIO_SET_LEVEL(signal, value) \
- gpio_set_level(signal, value)
+#define GPIO_SET_LEVEL(signal, value) gpio_set_level(signal, value)
#endif
/* The wait time is ~150 msec, allow for safety margin. */
@@ -250,7 +249,6 @@ enum power_state power_handle_state(enum power_state state)
common_intel_x86_handle_rsmrst(state);
switch (state) {
-
case POWER_G3S5:
GPIO_SET_LEVEL(GPIO_EN_S5_RAILS, 1);
@@ -262,7 +260,8 @@ enum power_state power_handle_state(enum power_state state)
* signal doesn't go high within 250 msec then go back to G3.
*/
if (power_wait_signals_timeout(IN_PCH_SLP_SUS_DEASSERTED,
- IN_PCH_SLP_SUS_WAIT_TIME_USEC) != EC_SUCCESS) {
+ IN_PCH_SLP_SUS_WAIT_TIME_USEC) !=
+ EC_SUCCESS) {
CPRINTS("SLP_SUS_L didn't go high! Going back to G3.");
return POWER_S5G3;
}
|
Use log-module for Orchestra | #include "net/routing/rpl-classic/rpl-private.h"
#endif
-#define DEBUG DEBUG_PRINT
-#include "net/ipv6/uip-debug.h"
+#include "sys/log.h"
+#define LOG_MODULE "Orchestra"
+#define LOG_LEVEL LOG_LEVEL_MAC
/* A net-layer sniffer for packets sent and received */
static void orchestra_packet_received(void);
@@ -171,10 +172,10 @@ orchestra_init(void)
linkaddr_copy(&orchestra_parent_linkaddr, &linkaddr_null);
/* Initialize all Orchestra rules */
for(i = 0; i < NUM_RULES; i++) {
- PRINTF("Orchestra: initializing rule %s (%u)\n", all_rules[i]->name, i);
+ LOG_INFO("Initializing rule %s (%u)\n", all_rules[i]->name, i);
if(all_rules[i]->init != NULL) {
all_rules[i]->init(i);
}
}
- PRINTF("Orchestra: initialization done\n");
+ LOG_INFO("Initialization done\n");
}
|
Call monitor_cap_detect in bsp_boot_init
On the APL NUC board (CPU family: 0x6 model: 92), the monitor is buggy.
We can't use it to wake up CPU core from mwait by memory monitor. | @@ -74,9 +74,10 @@ struct cpu_capability {
static struct cpu_capability cpu_caps;
static void apicv_cap_detect(void);
+static void monitor_cap_detect(void);
static void cpu_set_logical_id(uint32_t logical_id);
static void print_hv_banner(void);
-bool check_monitor_support(void);
+static inline bool get_monitor_cap(void);
int cpu_find_logical_id(uint32_t lapic_id);
#ifndef CONFIG_EFI_STUB
static void start_cpus();
@@ -310,6 +311,8 @@ void bsp_boot_init(void)
apicv_cap_detect();
+ monitor_cap_detect();
+
/* Set state for this CPU to initializing */
cpu_set_current_state(CPU_BOOT_ID, CPU_STATE_INITIALIZING);
@@ -557,7 +560,7 @@ static void pcpu_sync_sleep(unsigned long *sync, int mask_bit)
{
int wake_sync = (1 << mask_bit);
- if (check_monitor_support()) {
+ if (get_monitor_cap()) {
/* Wait for the event to be set using monitor/mwait */
asm volatile ("1: cmpl %%ebx,(%%eax)\n"
" je 2f\n"
@@ -653,7 +656,7 @@ static void monitor_cap_detect(void)
}
}
-bool check_monitor_support(void)
+static inline bool get_monitor_cap(void)
{
return cpu_caps.monitor_supported;
}
|
BugID:19146271:Keep ble mesh init in ble task context to prevent handles mixing issue | @@ -74,6 +74,11 @@ static u8_t reg_faults[CUR_FAULTS_MAX * 2];
struct mesh_shell_cmd *bt_mesh_get_shell_cmd_list();
+#ifdef CONFIG_BT_MESH_PROV
+static bt_mesh_prov_bearer_t prov_bear;
+static void cmd_pb2(bt_mesh_prov_bearer_t bearer, const char *s);
+#endif
+
static void get_faults(u8_t *faults, u8_t faults_size, u8_t *dst, u8_t *count)
{
u8_t i, limit = *count;
@@ -545,37 +550,20 @@ static void bt_ready(int err)
#if IS_ENABLED(CONFIG_BT_MESH_LOW_POWER)
bt_mesh_lpn_set_cb(lpn_cb);
#endif
+
+#ifdef CONFIG_BT_MESH_PROV
+ cmd_pb2(prov_bear, "on");
+#endif
}
static int cmd_init(int argc, char *argv[])
{
- int err;
+ int err = 0;
#ifndef CONFIG_MESH_STACK_ALONE
err = bt_enable(bt_ready);
#endif
- if (err && err != -EALREADY) {
- printk("Bluetooth init failed (err %d)\n", err);
- return 0;
- } else if (!err) {
- printk("Bluetooth initialized\n");
- }
-
-#if 0
- err = bt_mesh_init(&prov, &comp);
- if (err) {
- printk("Mesh initialization failed (err %d)\n", err);
- }
-
- printk("Mesh initialized\n");
- printk("Use \"pb-adv on\" or \"pb-gatt on\" to enable advertising\n");
-
-#if IS_ENABLED(CONFIG_BT_MESH_LOW_POWER)
- bt_mesh_lpn_set_cb(lpn_cb);
-#endif
-#endif
-
- return 0;
+ return err;
}
#if defined(CONFIG_BT_MESH_GATT_PROXY)
@@ -2140,7 +2128,7 @@ static int cmd_bunch_pb_adv(int argc, char *argv[])
{
cmd_uuid(argc, argv);
cmd_init(0, NULL);
- cmd_pb2(BT_MESH_PROV_ADV, "on");
+ prov_bear = BT_MESH_PROV_ADV;
return 0;
}
@@ -2148,7 +2136,7 @@ static int cmd_bunch_pb_gatt(int argc, char *argv[])
{
cmd_uuid(argc, argv);
cmd_init(0, NULL);
- cmd_pb2(BT_MESH_PROV_ADV | BT_MESH_PROV_GATT, "on");
+ prov_bear = BT_MESH_PROV_ADV | BT_MESH_PROV_GATT;
return 0;
}
#endif
|
doc: fix link in faq | @@ -112,7 +112,7 @@ Please start by reading [here](/.github/CONTRIBUTING.md).
[New BSD license](/LICENSE.md) which allows us to have plugins link against GPL
and GPL-incompatible libraries. If you compile Elektra, e.g., with GPL plugins, the
-result is GPL. We are [reuse](reuse.software/) compliant.
+result is GPL. We are [reuse](https://reuse.software/) compliant.
## Which version should I use?
|
Fix range checks with -offset and -length in asn1parse | @@ -258,14 +258,14 @@ int asn1parse_main(int argc, char **argv)
num = tmplen;
}
- if (offset >= num) {
+ if (offset < 0 || offset >= num) {
BIO_printf(bio_err, "Error: offset too large\n");
goto end;
}
num -= offset;
- if ((length == 0) || ((long)length > num))
+ if (length == 0 || length > (unsigned int)num)
length = (unsigned int)num;
if (derout != NULL) {
if (BIO_write(derout, str + offset, length) != (int)length) {
|
os/fs/smartfs : Delete unusing code
Remove unnecessary code | @@ -1079,11 +1079,6 @@ static int smart_setsectorsize(FAR struct smart_struct_s *dev, uint16_t size)
/* Now get Total Journal data of both of 2 area */
dev->njournaldata = dev->njournalPerBlk * dev->njournaleraseblocks;
- if (dev->sSeqLogMap != NULL) {
- smart_free(dev, dev->sSeqLogMap);
- dev->sSeqLogMap = NULL;
- }
-
#endif
#if defined(CONFIG_FS_PROCFS) && !defined(CONFIG_FS_PROCFS_EXCLUDE_SMARTFS)
@@ -5459,6 +5454,7 @@ static int smart_journal_recovery(FAR struct smart_struct_s *dev, journal_log_t
default:
return -EIO;
}
+ return OK;
}
#endif
|
[mechanics] put gain the specilization fro bullet2dR (to be fixed) | #define XBULLET_CLASSES() \
REGISTER(BulletR)\
REGISTER(Bullet5DR)\
+ REGISTER(Bullet2dR)
#ifdef SICONOS_HAS_BULLET
@@ -224,7 +225,7 @@ void contactPointProcess<Lagrangian2d2DR>(SiconosVector& answer,
const SiconosVector& posa = *rel.pc1();
const SiconosVector& posb = *rel.pc2();
const SiconosVector& nc = *rel.nc();
- DEBUG_PRINTF("posa(0)=%g\n", posa(0)); DEBUG_PRINTF("posa(1)=%g\n", posa(1)); DEBUG_PRINTF("posa(2)=%g\n", posa(2));
+ DEBUG_PRINTF("posa(0)=%g\n", posa(0)); DEBUG_PRINTF("posa(1)=%g\n", posa(1));
double id = inter.number();
double mu = ask<ForMu>(*inter.nonSmoothLaw());
@@ -233,35 +234,33 @@ void contactPointProcess<Lagrangian2d2DR>(SiconosVector& answer,
prod(*inter.lambda(1), jachq, cf, true);
- answer.resize(23);
+ answer.resize(16);
answer.setValue(0, mu);
answer.setValue(1, posa(0));
answer.setValue(2, posa(1));
- answer.setValue(3, posa(2));
- answer.setValue(4, posb(0));
- answer.setValue(5, posb(1));
- answer.setValue(6, posb(2));
- answer.setValue(7, nc(0));
- answer.setValue(8, nc(1));
- answer.setValue(9, nc(2));
- answer.setValue(10, cf(0));
- answer.setValue(11, cf(1));
- answer.setValue(12, cf(2));
- answer.setValue(13,inter.y(0)->getValue(0));
- answer.setValue(14,inter.y(0)->getValue(1));
- answer.setValue(15,inter.y(0)->getValue(2));
- answer.setValue(16,inter.y(1)->getValue(0));
- answer.setValue(17,inter.y(1)->getValue(1));
- answer.setValue(18,inter.y(1)->getValue(2));
- answer.setValue(19,inter.lambda(1)->getValue(0));
- answer.setValue(20,inter.lambda(1)->getValue(1));
- answer.setValue(21,inter.lambda(1)->getValue(2));
- answer.setValue(22, id);
+
+ answer.setValue(3, posb(0));
+ answer.setValue(4, posb(1));
+
+ answer.setValue(5, nc(0));
+ answer.setValue(6, nc(1));
+
+ answer.setValue(7, cf(0));
+ answer.setValue(8, cf(1));
+
+ answer.setValue(9,inter.y(0)->getValue(0));
+ answer.setValue(10,inter.y(0)->getValue(1));
+
+ answer.setValue(11,inter.y(1)->getValue(0));
+ answer.setValue(12,inter.y(1)->getValue(1));
+
+ answer.setValue(13,inter.lambda(1)->getValue(0));
+ answer.setValue(14,inter.lambda(1)->getValue(1));
+
+ answer.setValue(15, id);
};
-/* template partial specilization is not possible inside struct, so we
- * need an helper function */
template<>
void contactPointProcess<Bullet2dR>(SiconosVector& answer,
const Interaction& inter,
@@ -308,15 +307,6 @@ void contactPointProcess<Bullet2dR>(SiconosVector& answer,
};
-
-
-
-
-
-
-
-
-
template<>
void contactPointProcess<PivotJointR>(SiconosVector& answer,
const Interaction& inter,
|
add version flags to the new menu commands to flag them as new
and turn them green (kind of a hack, since it it really refers to the maya version, but
we set it to a future maya version, and next houdini version we will
remove the flags) | @@ -582,10 +582,13 @@ houdiniEngineCreateUI()
menuItem -label "Sync Asset"
-command "houdiniEngine_syncSelectedAsset";
menuItem -label "Bake Asset"
+ -version 2019
-command "houdiniEngine_bakeSelectedAssets";
menuItem -label "Remove Asset From History"
+ -version 2019
-command "houdiniEngine_removeSelectedHistory";
menuItem -label "Add Asset To Mesh History"
+ -version 2019
-command "houdiniEngine_addSelectedHistory";
menuItem -label "Reload Asset"
-command "houdiniEngine_reloadSelectedAssets";
|
BugID:17865306: Fix NAME for developerkit | -ifeq ($(AOS_2BOOT_SUPPORT), yes)
-NAME := board_developerkit_2boot
-else
NAME := board_developerkit
-endif
$(NAME)_MBINS_TYPE := kernel
$(NAME)_VERSION := 1.0.0
@@ -12,6 +8,8 @@ HOST_MCU_FAMILY := mcu_stm32l4xx_cube
HOST_MCU_NAME := STM32L496VGTx
ifeq ($(AOS_2BOOT_SUPPORT), yes)
+$(NAME)_LIBSUFFIX := _2boot
+
HOST_OPENOCD := stm32l4xx
GLOBAL_DEFINES += USE_HAL_DRIVER
GLOBAL_DEFINES += STM32L496xx
|
CLIENT LIST / INFO show resp version | @@ -2329,7 +2329,7 @@ sds catClientInfoString(sds s, client *client) {
total_mem += zmalloc_size(client->argv);
return sdscatfmt(s,
- "id=%U addr=%s laddr=%s %s name=%s age=%I idle=%I flags=%s db=%i sub=%i psub=%i multi=%i qbuf=%U qbuf-free=%U argv-mem=%U obl=%U oll=%U omem=%U tot-mem=%U events=%s cmd=%s user=%s redir=%I",
+ "id=%U addr=%s laddr=%s %s name=%s age=%I idle=%I flags=%s db=%i sub=%i psub=%i multi=%i qbuf=%U qbuf-free=%U argv-mem=%U obl=%U oll=%U omem=%U tot-mem=%U events=%s cmd=%s user=%s redir=%I resp=%i",
(unsigned long long) client->id,
getClientPeerId(client),
getClientSockname(client),
@@ -2352,7 +2352,8 @@ sds catClientInfoString(sds s, client *client) {
events,
client->lastcmd ? client->lastcmd->name : "NULL",
client->user ? client->user->name : "(superuser)",
- (client->flags & CLIENT_TRACKING) ? (long long) client->client_tracking_redirection : -1);
+ (client->flags & CLIENT_TRACKING) ? (long long) client->client_tracking_redirection : -1,
+ client->resp);
}
sds getAllClientsInfoString(int type) {
|
Ensure we force close an invalid client under ws_send_strict_fifo_to_client(). | @@ -2539,8 +2539,13 @@ ws_send_strict_fifo_to_client (WSServer * server, int listener, WSPacket * pa) {
if (!(client = ws_get_client_from_list (listener, &server->colist)))
return;
/* no handshake for this client */
- if (client->headers == NULL || client->headers->ws_accept == NULL)
+ if (client->headers == NULL || client->headers->ws_accept == NULL) {
+ LOG (("No headers. Closing %d [%s]\n", client->listener, client->remote_ip));
+
+ handle_tcp_close (client->listener, client, server);
+ client->status = WS_CLOSE;
return;
+ }
ws_send_data (client, pa->type, pa->data, pa->len);
}
|
clay: add /cs/===/bloc scry for all desk blobs
Lets you retrieve all blobs from the blob store that are in use by the
desk, both presently and in all its history. | ++ read-s
|= [yon=aeon pax=path]
^- (unit (unit cage))
+ ?: ?=([%bloc ~] pax)
+ :^ ~ ~ %noun
+ :- -:!>(*(map lobe blob))
+ ^- (map lobe blob)
+ %- %~ rep in
+ %- reachable-takos
+ (~(got by hit.dom) let.dom)
+ |= [t=tako o=(map lobe blob)]
+ %- ~(gas by o)
+ %+ turn
+ ~(val by q:(~(got by hut.ran) t))
+ |=(l=lobe [l (~(got by lat.ran) l)])
?. ?=([@ * *] pax)
`~
?+ i.pax `~
|
added upload progressbar | /*===========================================================================*/
/* globale Konstante */
+struct memory
+{
+char *response;
+size_t size;
+};
+
static long int uploadcountok;
static long int uploadcountfailed;
static const char *wpasecurl = "https://wpa-sec.stanev.org";
static bool removeflag = false;
+struct memory *curlmem;
/*===========================================================================*/
static int testwpasec(long int timeout)
{
@@ -46,6 +53,22 @@ curl_global_cleanup();
return res;
}
/*===========================================================================*/
+static size_t cb(void *data, size_t size, size_t nmemb, void *userp)
+{
+char *ptr;
+size_t realsize = size *nmemb;
+
+curlmem = (struct memory *)userp;
+
+ptr = realloc(curlmem->response, curlmem->size +realsize +1);
+if(ptr == NULL) return 0;
+curlmem->response = ptr;
+memcpy(&(curlmem->response[curlmem->size]), data, realsize);
+curlmem->size += realsize;
+curlmem->response[curlmem->size] = 0;
+return realsize;
+}
+/*===========================================================================*/
static bool sendcap2wpasec(char *sendcapname, long int timeout, char *keyheader, char *emailheader)
{
CURL *curl;
@@ -57,6 +80,7 @@ struct curl_httppost *formpost=NULL;
struct curl_httppost *lastptr=NULL;
struct curl_slist *headerlist=NULL;
static const char buf[] = "Expect:";
+struct memory chunk = {0};
printf("uploading %s to %s\n", sendcapname, wpasecurl);
curl_global_init(CURL_GLOBAL_ALL);
@@ -67,6 +91,9 @@ curl = curl_easy_init();
headerlist = curl_slist_append(headerlist, buf);
if(curl)
{
+ curl_easy_setopt(curl, CURLOPT_NOPROGRESS, 0L);
+ curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, cb);
+ curl_easy_setopt(curl, CURLOPT_WRITEDATA, (void *)&chunk);
curl_easy_setopt(curl, CURLOPT_URL, wpasecurl);
curl_easy_setopt(curl, CURLOPT_CONNECTTIMEOUT, timeout);
curl_easy_setopt(curl, CURLOPT_HTTPPOST, formpost);
@@ -74,12 +101,17 @@ if(curl)
res = curl_easy_perform(curl);
if(res == CURLE_OK)
{
- printf("\n\x1B[32mupload done\x1B[0m\n\n");
+ printf("upload done\n");
if(removeflag == true)
{
ret = remove(sendcapname);
if(ret != 0) fprintf(stderr, "couldn't remove %s\n", sendcapname);
}
+ if(curlmem->response != NULL)
+ {
+ printf("\n%s\n\n", curlmem->response);
+ free(curlmem->response);
+ }
}
else
{
|
Adjust button numbers for lumi.ctrl_neutral1 and lumi.ctrl_neutral2
1002
2002
3002 | @@ -4262,15 +4262,25 @@ void DeRestPluginPrivate::updateSensorNode(const deCONZ::NodeEvent &event)
if (item && !i->buttonMap() &&
event.event() == deCONZ::NodeEvent::UpdatedClusterDataZclReport)
{
- // TODO better button handler
- quint32 button;
+ quint32 button = 0;
if (i->modelId() == QLatin1String("lumi.sensor_86sw1") ||
- i->modelId() == QLatin1String("lumi.sensor_86sw2") ||
- i->modelId() == QLatin1String("lumi.ctrl_neutral1") ||
+ i->modelId() == QLatin1String("lumi.sensor_86sw2"))
+ {
+ button = (S_BUTTON_1 * event.endpoint()) + S_BUTTON_ACTION_SHORT_RELEASED;
+ }
+ else if (i->modelId() == QLatin1String("lumi.ctrl_neutral1") ||
i->modelId() == QLatin1String("lumi.ctrl_neutral2"))
{
+ switch (event.endpoint())
+ {
+ case 2: button = S_BUTTON_1 + S_BUTTON_ACTION_SHORT_RELEASED; break;
+ case 3: button = S_BUTTON_2 + S_BUTTON_ACTION_SHORT_RELEASED; break;
+ case 6: button = S_BUTTON_3 + S_BUTTON_ACTION_SHORT_RELEASED; break;
+ default: // should not happen
button = (S_BUTTON_1 * event.endpoint()) + S_BUTTON_ACTION_SHORT_RELEASED;
+ break;
+ }
}
else
{
|
Make _advance a little bit more readable. | @@ -21,14 +21,14 @@ function Parser:init(lexer)
end
function Parser:_advance()
- local err
- local tok = self.next
- self.next = self.look
- self.look, err = self.lexer:next()
- if not self.look then
+ local tok, err = self.lexer:next()
+ if not tok then
self:syntax_error(self.lexer:loc(), err)
end
- return tok
+ local ret = self.next
+ self.next = self.look
+ self.look = tok
+ return ret
end
-- Check the next token without consuming it
|
New linter with arcadia global checkstyle (update of https://a.yandex-team.ru/review/725386) | @@ -445,6 +445,7 @@ def onadd_check(unit, *args):
allowed_levels = {
'base': '/yandex_checks.xml',
'strict': '/yandex_checks_strict.xml',
+ 'extended': '/yandex_checks_extended.xml',
}
if check_level not in allowed_levels:
raise Exception('{} is not allowed in LINT(), use one of {}'.format(check_level, allowed_levels.keys()))
|
Disable flagstat test as output differs in samtools-1.13 | @@ -244,7 +244,8 @@ class SamtoolsTest(unittest.TestCase):
command = self.get_command(statement, map_to_internal=False)
# bam2fq differs between version 1.5 and 1.6 - re-enable if
# bioconda samtools will be available.
- if command in ("bedcov", "stats", "dict", "bam2fq"):
+ # flagstat differs between version <=1.12 and >=1.13
+ if command in ("bedcov", "stats", "dict", "bam2fq", "flagstat"):
continue
if (command == "calmd" and
|
improve standalone test | #!/usr/bin/env python
import os
-from panda.lib.panda import Panda
+import struct
import time
+from panda.lib.panda import Panda
if __name__ == "__main__":
if os.getenv("WIFI") is not None:
@@ -10,12 +11,15 @@ if __name__ == "__main__":
p = Panda()
print p.health()
+ a = 0
while 1:
# flood
- p.can_send(0xaa, "\xaa"*8, 0)
- p.can_send(0xaa, "\xaa"*8, 1)
- p.can_send(0xaa, "\xaa"*8, 4)
+ msg = "\xaa"*4 + struct.pack("I", a)
+ p.can_send(0xaa, msg, 0)
+ p.can_send(0xaa, msg, 1)
+ p.can_send(0xaa, msg, 4)
time.sleep(0.01)
print p.can_recv()
+ a += 1
|
[numerics] Delete the function getNewtonSteplength, which has been replaced by getStepLength which uses long double. | @@ -123,8 +123,6 @@ typedef long double float_type;
/* On the implementation and usage of SDPT3 - a Matlab software package */
/* for semidefinite-quadratic-linear programming, version 4.0 */
/* Draft, 17 July 2006 */
-static double getNewtonStepLength(const double * const x, const double * const dx,
- const unsigned int vecSize, const unsigned int varsCount, const double gamma);
/* Returns the maximum step-length to the boundary reduced by a factor gamma. Uses long double. */
static double getStepLength(const double * const x, const double * const dx, const unsigned int vecSize,
@@ -267,68 +265,6 @@ static float_type dnrm2l(const unsigned int n, const double * x)
return norm;
}
-/* Returns the step length for variables update in IPM */
-static double getNewtonStepLength(const double * const x, const double * const dx, const unsigned int vecSize,
- const unsigned int varsCount, const double gamma)
-{
- unsigned int dimension = (int)(vecSize / varsCount);
- double * alpha_list = (double*)calloc(varsCount, sizeof(double));
-
- unsigned int pos;
- double ai, bi, ci, di, alpha, min_alpha;
- double *xi2, *dxi2, *xi_dxi;
-
- const double *dxi, *xi;
-
- dxi2 = (double*)calloc(dimension, sizeof(double));
- xi2 = (double*)calloc(dimension, sizeof(double));
- xi_dxi = (double*)calloc(dimension, sizeof(double));
-
- for(unsigned int i = 0; i < varsCount; ++i)
- {
- pos = i * dimension;
- xi = x + pos;
- dxi = dx + pos;
-
- NV_power2(dxi, dimension, dxi2);
- ai = dxi2[0] - NV_reduce((dxi2 + 1), dimension - 1);
-
- NV_prod(xi, dxi, dimension, xi_dxi);
- bi = xi_dxi[0] - NV_reduce((xi_dxi + 1), dimension - 1);
- // bi = gamma*bi;
-
- NV_power2(xi, dimension, xi2);
- ci = xi2[0] - NV_reduce((xi2 + 1), dimension - 1);
- // ci = gamma*gamma*ci;
-
- di = bi * bi - ai * ci;
-
- if(ai < 0 || (bi < 0 && ai < (bi * bi) / ci))
- alpha = ((-bi - sqrt(di)) / ai);
- else if((fabs(ai) < DBL_EPSILON) && (bi < 0))
- alpha = (-ci / (2 * bi));
- else
- alpha = DBL_MAX;
- //NV_display(xi2, dimension);
- //printf("**************** %3i ai = %9.2e b = %9.2e ci = %9.2e alpha = %9.2e\n",i, ai, bi, ci, alpha);
-
- if(fabs(alpha) < DBL_EPSILON)
- alpha = 0.0;
-
- alpha_list[i] = alpha;
- }
-
- min_alpha = NV_min(alpha_list, varsCount);
-
- free(xi2);
- free(dxi2);
- free(xi_dxi);
- free(alpha_list);
-
- return fmin(1.0, gamma * min_alpha);
- //return fmin(1.0, min_alpha);
-}
-
/* Returns the maximum step-length to the boundary reduced by a factor gamma. Uses long double. */
static double getStepLength(const double * const x, const double * const dx, const unsigned int vecSize,
const unsigned int varsCount, const double gamma)
|
error: added more examples | @@ -21,12 +21,18 @@ e.g., to keep the mountpoint information or on how wordings should be (with or w
"Sorry, ...", coloring of certain parts of a message, etc.)
Examples would be to
- - Leave out the "Sorry"
- - Show mountpoint info but in another way:
+
+- Leave out the "Sorry" in the error message or leave the introduction sentence completely
+- Drop `At`, `Mountpoint`, `Configfile`, `Module`. This information though yields useful information
+ or was even added as a request
+- Show mountpoint, configfile, module, etc in beneath the general introduction message. Eg.
`The command kdb set failed while accessing the key database on mountpoint (...) with the info`
- - Incorporating the description in another way:
+- Incorporating the description in another ways:
`Reason: Validation of key "<key>" with string "<value>" failed. (validation failed)`
- - etc.
+- Use one command line option to show all additional info which gets hidden per default from now on instead of two
+- Color the main message differently compared to the general introduction message
+- Do not color messages as it might confuse users with overwhelming many colors
+- Do not print out the error code. It is useful though for googling
## Decision
|
bfscope_nfs: increase local buffer to 128M, redump trace if necessary, and cleanup unused/unnecessary globals | #define DEBUG if (0) printf
-/// Buffer size for temp buffer during dumping
-#define BFSCOPE_BUFLEN (2<<20)
+/// Buffer size for temp buffer during dumping: 128MB
+#define BFSCOPE_BUFLEN (128UL * 1024 * 1024)
/// Use /bfscope as mount point for NFS share
#define MOUNT_DIR "/bfscope"
@@ -46,8 +46,6 @@ static vfs_handle_t dump_file_vh;
static bool local_flush = false;
static char *trace_buf = NULL;
-static size_t trace_length = 0;
-static size_t trace_sent = 0;
static bool dump_in_progress = false;
struct bfscope_ack_send_state {
@@ -91,8 +89,6 @@ static void bfscope_send_flush_ack_to_monitor(void)
static void bfscope_trace_dump_finished(void)
{
- trace_length = 0;
- trace_sent = 0;
dump_in_progress = false;
if (!local_flush) {
@@ -106,13 +102,16 @@ static void bfscope_trace_dump_finished(void)
static void bfscope_trace_dump(void)
{
errval_t err;
+ int number_of_events = 0;
+ size_t trace_length = 0;
if(dump_in_progress) {
// Currently there is already a dump in progress, do nothing.
return;
}
- int number_of_events = 0;
+dump_again:
+ number_of_events = 0;
// Acquire the trace buffer
trace_length = trace_dump(trace_buf, BFSCOPE_BUFLEN, &number_of_events);
@@ -144,6 +143,11 @@ static void bfscope_trace_dump(void)
}
DEBUG("dump to NFS share done!\n");
+ if (trace_length == BFSCOPE_BUFLEN) {
+ debug_printf("got full buffer from first call to trace_dump()... calling again\n");
+ goto dump_again;
+ }
+
bfscope_trace_dump_finished();
}
|
improve makefile for lib include files | @@ -519,17 +519,20 @@ install_lib: $(LIB_PATH)/$(SHARED_LIB_NAME_FULL) $(LIB_PATH)/$(SHARED_LIB_NAME_S
@echo "Installed library"
.PHONY: install_lib-dev
-install_lib-dev: $(LIB_PATH)/$(SHARED_LIB_NAME_FULL) $(LIB_PATH)/$(SHARED_LIB_NAME_SO) $(LIBDEV_PATH)/$(SHARED_LIB_NAME_SHORT) $(LIBDEV_PATH)/liboidc-agent.a $(INCLUDE_PATH)/oidc-agent/api.h $(INCLUDE_PATH)/oidc-agent/tokens.h $(INCLUDE_PATH)/oidc-agent/accounts.h $(INCLUDE_PATH)/oidc-agent/api_helper.h $(INCLUDE_PATH)/oidc-agent/comm.h $(INCLUDE_PATH)/oidc-agent/error.h $(INCLUDE_PATH)/oidc-agent/memory.h $(INCLUDE_PATH)/oidc-agent/ipc_values.h $(INCLUDE_PATH)/oidc-agent/oidc_error.h $(INCLUDE_PATH)/oidc-agent/export_symbols.h
+install_lib-dev: $(LIB_PATH)/$(SHARED_LIB_NAME_FULL) $(LIB_PATH)/$(SHARED_LIB_NAME_SO) $(LIBDEV_PATH)/$(SHARED_LIB_NAME_SHORT) $(LIBDEV_PATH)/liboidc-agent.a install_includes
@echo "Installed library dev"
endif
ifdef MINGW
.PHONY: install_lib_windows-dev
-install_lib_windows-dev: create_obj_dir_structure $(LIBDEV_PATH)/liboidc-agent.a $(INCLUDE_PATH)/oidc-agent/api.h $(INCLUDE_PATH)/oidc-agent/tokens.h $(INCLUDE_PATH)/oidc-agent/accounts.h $(INCLUDE_PATH)/oidc-agent/api_helper.h $(INCLUDE_PATH)/oidc-agent/comm.h $(INCLUDE_PATH)/oidc-agent/error.h $(INCLUDE_PATH)/oidc-agent/memory.h $(INCLUDE_PATH)/oidc-agent/ipc_values.h $(INCLUDE_PATH)/oidc-agent/oidc_error.h $(INCLUDE_PATH)/oidc-agent/export_symbols.h
+install_lib_windows-dev: create_obj_dir_structure $(LIBDEV_PATH)/liboidc-agent.a install_includes
@echo "Installed windows library dev"
endif
+.PHONY: install_includes
+install_includes: $(INCLUDE_PATH)/oidc-agent/api.h $(INCLUDE_PATH)/oidc-agent/tokens.h $(INCLUDE_PATH)/oidc-agent/accounts.h $(INCLUDE_PATH)/oidc-agent/api_helper.h $(INCLUDE_PATH)/oidc-agent/comm.h $(INCLUDE_PATH)/oidc-agent/error.h $(INCLUDE_PATH)/oidc-agent/memory.h $(INCLUDE_PATH)/oidc-agent/ipc_values.h $(INCLUDE_PATH)/oidc-agent/oidc_error.h $(INCLUDE_PATH)/oidc-agent/export_symbols.h
+
ifndef ANY_MSYS
.PHONY: install_scheme_handler
|
Emit correct button event for Sengled E1E-G7F | @@ -4625,6 +4625,13 @@ void DeRestPluginPrivate::checkSensorButtonEvent(Sensor *sensor, const deCONZ::A
}
}
+ else if (ind.clusterId() == SENGLED_CLUSTER_ID)
+ {
+ if (buttonMap.zclParam0 == pl0)
+ {
+ ok = true;
+ }
+ }
if (ok && buttonMap.button != 0)
{
|
todo: 2 step process for API design review | On potential changes (including extensions) of the API/ABI please check following list:
- [ ] [use case](/doc/usecases) for API exists
+- [ ] API design [review](/doc/api_review/) template is created by author of API change
- [ ] **Before** starting to implement the change: [decision](/doc/decision) for API is in step `decided`
- [ ] **After** implementing the change: [decision](/doc/decision) for API is in step `implemented`
-- [ ] API design is [reviewed](/doc/api_review/)
+- [ ] API design is [reviewed](/doc/api_review/) by someone else, too
- [ ] full Doxygen docu (all parameters, full design-by-contract, brief, long, examples, etc.)
- [ ] full Testcoverage
- [ ] still ABI/API forward-compatible
|
Add SKIP_EMPTY_PARTS define for QString::split()
Will be used to fix depreacted warning after Qt 5.14 | @@ -18,6 +18,12 @@ CONFIG(release, debug|release) {
LIBS += -L../../release
}
+equals(QT_MAJOR_VERSION, 5):lessThan(QT_MINOR_VERSION, 15) {
+ DEFINES += SKIP_EMPTY_PARTS=QString::SkipEmptyParts
+} else {
+ DEFINES += SKIP_EMPTY_PARTS=Qt::SkipEmptyParts
+}
+
greaterThan(QT_MAJOR_VERSION, 4) {
QT += core gui widgets serialport
|
Adapt cs_loader_impl for Guix build. | @@ -29,6 +29,23 @@ message(STATUS "Plugin ${target} implementation")
# Create target
#
+if(OPTION_BUILD_GUIX)
+ if(DOTNET_VERSION VERSION_EQUAL "2.0" OR DOTNET_VERSION VERSION_GREATER "2.0")
+ execute_process(
+ COMMAND ${DOTNET_COMMAND} nuget locals all --list | grep global-packages | awk '{print $NF}'
+ OUTPUT_VARIABLE DOTNET_SOURCE
+ )
+ else()
+ set(DOTNET_SOURCE)
+ message(FATAL_ERROR ".NET Core support not implemented in Guix build for versions less than 2.0.")
+ endif()
+
+ # Build without internet access
+ add_custom_target(${target} ALL
+ COMMAND ${DOTNET_COMMAND} restore --source ${DOTNET_SOURCE} ${CMAKE_CURRENT_SOURCE_DIR}/source/project.csproj
+ COMMAND ${DOTNET_COMMAND} publish --source ${DOTNET_SOURCE} ${CMAKE_CURRENT_SOURCE_DIR}/source/project.csproj -o ${CMAKE_BINARY_DIR}
+ )
+else()
if(DOTNET_VERSION VERSION_EQUAL "2.0" OR DOTNET_VERSION VERSION_GREATER "2.0")
add_custom_target(${target} ALL
COMMAND ${DOTNET_COMMAND} restore ${CMAKE_CURRENT_SOURCE_DIR}/source/project.csproj
@@ -48,6 +65,7 @@ else()
)
endif()
endif()
+endif()
#
# Project options
|
combine feature list items | @@ -18,8 +18,7 @@ Supported are also domains consisting of public keys represented as hexadecimal
* small size, ~85KB depending on features, ~35KB compressed
* command line interface (kadnode-ctl)
* NSS support through /etc/nsswitch.conf
-* DNS interface and proxy support
-* integrated simplified DNS server and proxy (handles A, AAAA, and SRV requests)
+* DNS server interface and DNS proxy (handles A, AAAA, and SRV requests)
* packages for ArchLinux/Debian/FreeBSD/MacOSX/OpenWrt/Windows
* peer file import/export on startup/shutdown and every 24h
* uses sha256 hash method
|
Wrap ISerializable descendants in Handle | @@ -843,18 +843,18 @@ sol::object RTTIHelper::NewHandle(RED4ext::CBaseRTTIType* apType, sol::optional<
result.type = apType;
result.value = NewInstance(apType, sol::nullopt, &allocator);
- // Wrap IScriptable descendants in Handle
+ // Wrap ISerializable descendants in Handle
if (result.value && apType->GetType() == RED4ext::ERTTIType::Class)
{
static auto* s_pHandleType = m_pRtti->GetType(RED4ext::FNV1a("handle:Activator"));
- static auto* s_pIScriptableType = m_pRtti->GetType(RED4ext::FNV1a("IScriptable"));
+ static auto* s_pISerializableType = m_pRtti->GetType(RED4ext::FNV1a("ISerializable"));
auto* pClass = reinterpret_cast<RED4ext::CClass*>(apType);
- if (pClass->IsA(s_pIScriptableType))
+ if (pClass->IsA(s_pISerializableType))
{
- auto* pInstance = reinterpret_cast<RED4ext::IScriptable*>(result.value);
- auto* pHandle = allocator.New<RED4ext::Handle<RED4ext::IScriptable>>(pInstance);
+ auto* pInstance = reinterpret_cast<RED4ext::ISerializable*>(result.value);
+ auto* pHandle = allocator.New<RED4ext::Handle<RED4ext::ISerializable>>(pInstance);
result.type = s_pHandleType; // To trick converter and deallocator
result.value = pHandle;
|
Declare secret OpenVR functions; | #pragma once
+// From openvr_capi.h
+extern intptr_t VR_InitInternal(EVRInitError *peError, EVRApplicationType eType);
+extern void VR_ShutdownInternal();
+extern bool VR_IsHmdPresent();
+extern intptr_t VR_GetGenericInterface(const char* pchInterfaceVersion, EVRInitError* peError);
+extern bool VR_IsRuntimeInstalled();
+extern const char* VR_GetVRInitErrorAsSymbol(EVRInitError error);
+extern const char* VR_GetVRInitErrorAsEnglishDescription(EVRInitError error);
+
typedef struct {
int isInitialized;
int isRendering;
|
Update GCC options for STM32L0 series | @@ -13,16 +13,20 @@ endif()
#################################################################
# need to specify this for assembler
-set(CMAKE_ASM_FLAGS " -mthumb -mcpu=cortex-m0 -mabi=aapcs -x assembler-with-cpp" CACHE INTERNAL "asm compiler flags")
+#####################################################################
+# because nanoCLR is loaded the VTOR has to be init in ChibiOS CRT0
+# this define has to be placed here because it's on an assembly file
+#####################################################################
+set(CMAKE_ASM_FLAGS " -mthumb -mcpu=cortex-m0plus -mfloat-abi=soft -mabi=aapcs -mtune=cortex-m0plus -x assembler-with-cpp -DCRT0_VTOR_INIT=TRUE" CACHE INTERNAL "asm compiler flags")
# need to specify linker flags here
-set(CMAKE_EXE_LINKER_FLAGS " -Wl,--gc-sections -Wl,--no-wchar-size-warning -mthumb -mcpu=cortex-m0 -mabi=aapcs -nostartfiles " CACHE INTERNAL "executable linker flags")
+set(CMAKE_EXE_LINKER_FLAGS " -Wl,--gc-sections -Wl,--no-wchar-size-warning -mthumb -mcpu=cortex-m0plus -mfloat-abi=soft -mabi=aapcs -mtune=cortex-m0plus -nostartfiles " CACHE INTERNAL "executable linker flags")
function(NF_SET_COMPILER_OPTIONS TARGET)
# include any extra options comming from any extra args?
- target_compile_options(${TARGET} PUBLIC ${ARGN} -mthumb -mcpu=cortex-m0 -mabi=aapcs -nostdlib -Wall -Wextra -Werror -ffunction-sections -fshort-wchar -falign-functions=16 -fdata-sections -fno-builtin -fno-common -fomit-frame-pointer -mlong-calls -fdollars-in-identifiers -fno-exceptions -fno-unroll-loops -mstructure-size-boundary=8 -ffast-math -ftree-vectorize -fcheck-new )
+ target_compile_options(${TARGET} PUBLIC ${ARGN} -mthumb -mcpu=cortex-m0plus -mfloat-abi=soft -mabi=aapcs -mtune=cortex-m0plus -nostdlib -Wall -Wextra -Werror -ffunction-sections -fshort-wchar -falign-functions=16 -fdata-sections -fno-builtin -fno-common -fomit-frame-pointer -mlong-calls -fdollars-in-identifiers -fno-exceptions -fno-unroll-loops -mstructure-size-boundary=8 -ffast-math -ftree-vectorize -fcheck-new )
endfunction()
|
[NFSU] fix sticky steering for high FPS usage | @@ -1051,6 +1051,23 @@ void Init()
// another frametime -- seems to affect some gameplay elements...
uint32_t* dword_6B5C08 = *hook::pattern("DF E0 F6 C4 41 7A ? 8A 44 24 12 D9 05 ? ? ? ?").count(1).get(0).get<uint32_t*>(13);
injector::WriteMemory(dword_6B5C08, FrameTime, true);
+
+ // GAME BUGFIX: fix sticky steering (especially on high FPS)
+ // kill the autocentering!
+ uint32_t* dword_460A3D = hook::pattern("D9 54 24 14 D9 E1 D8 1D ? ? ? ? DF E0 F6 C4 05 7A 08").count(1).get(0).get<uint32_t>(0x11); //0x460A2C anchor
+ injector::WriteMemory<uint8_t>(dword_460A3D, 0xEB, true);
+
+ // explanation:
+ // this is a native game bug which can sadly happen on a bone-stock game, it's just been exaggerated by the higher FPS and faster input
+ // what happens is this: if the steering curve isn't finished with the steering (if the wheels aren't centered), it will outright ignore the other direction you're pressing
+ // to exaggerate the issue even further: nop out the instruction at 00460DFA which will make the steering extremely slow, then try steering all the way to the left, then quickly go and hold right. Notice how it *won't* continue to go right.
+ // so to summarize in a chain of events:
+ // 1. game controller sets steering value (-1.0 to 1.0)
+ // 2. World::DoTimestep updates the player info and somewhere
+ // 3. Somewhere in that chain it calls PlayerSteering::DoUndergroundSteering with the steering value as argument
+ // 4. Steering curves get processed at PlayerSteering::CalculateSteeringSpeed <-- THIS IS WHERE THE BUG HAPPENS (or shortly thereafter)
+ // 5. Steering value gets passed to the car
+ // Skipping 4. is possible by enabling the bool at 00736514, but that is intended exclusively for wheel input and not gamepad/keyboard input.
}
// windowed mode
|
viofs-svc: report Read permission as Read&Execute.
A test solution to allow file execution in Windows but without
polluting the Linux side. | #define SafeHeapFree(p) if (p != NULL) { HeapFree(GetProcessHeap(), 0, p); }
+#define ReadAndExecute(x) ((x) | (((x) & 0444) >> 2))
+
typedef struct
{
FSP_FILE_SYSTEM *FileSystem;
@@ -635,8 +637,8 @@ static NTSTATUS GetFileInfoInternal(VIRTFS *VirtFs,
if (SecurityDescriptor != NULL)
{
Status = FspPosixMapPermissionsToSecurityDescriptor(
- VirtFs->LocalUid, VirtFs->LocalGid, attr->mode,
- SecurityDescriptor);
+ VirtFs->LocalUid, VirtFs->LocalGid,
+ ReadAndExecute(attr->mode), SecurityDescriptor);
}
}
@@ -719,7 +721,7 @@ static NTSTATUS GetSecurityByName(FSP_FILE_SYSTEM *FileSystem, PWSTR FileName,
}
Status = FspPosixMapPermissionsToSecurityDescriptor(VirtFs->LocalUid,
- VirtFs->LocalGid, attr->mode, &Security);
+ VirtFs->LocalGid, ReadAndExecute(attr->mode), &Security);
if (NT_SUCCESS(Status))
{
|
pbdrv/imu: Fix error include.
This is needed whether the IMU is enabled or not. | #define PBDRV_IMU_H
#include <pbdrv/config.h>
+#include <pbio/error.h>
/**
* Opaque handle to an IMU device instance.
@@ -18,8 +19,6 @@ typedef struct _pbdrv_imu_dev_t pbdrv_imu_dev_t;
#if PBDRV_CONFIG_IMU
-#include <pbio/error.h>
-
/**
* Gets the one and only IMU device instance.
* @param [out] imu_dev The device instance.
|
improve renderers (clean up vars) | /= configs /: /===/web/collections
/^ (map knot config:collections) /_ /collections-config/
:: this was a dumb way to do do this, clean up
-/= extratopic /^ {a=manx b=topicful:collections ~}
- /%
- /. /& elem
+/= content /& elem
/& md
:: don't render first line if there's a title
/; |= a/topic:collections
(of-wain:format +:wat.a)
(of-wain:format wat.a)
/collections-topic/
- /collections-topic-full/
- ==
+/= metawcom /^ topicful:collections /collections-topic-full/
=/ config (~(get by configs) +<:s.bem.gas)
=, old-zuse
^- manx
{(trip desc:(need config))} /
==
;div.row.mod.text-mono
- ; {(trip (scot %da mod.info.b.extratopic))}
+ ; {(trip (scot %da mod.info.metawcom))}
==
==
::
;div#show
;div.row.tit
- ;h1: {(trip tit.info.b.extratopic)}
+ ;h1: {(trip tit.info.metawcom)}
==
;* ?: (authed:colls gas)
;=
;div(data-component "Subscribe", data-circle "{(scow %p p.bem.gas)}/collection_~{(trip +<:s.bem.gas)}_~{(trip -:s.bem.gas)}");
==
;div.row.content.mb-18
- +{a.extratopic}
+ +{content}
==
;* ?: comm:(need config)
;=
;ol
;* %+ turn
%+ sort
- ~(tap by coms.b.extratopic)
+ ~(tap by coms.metawcom)
|= [a=[c=@da d=[mod=@da who=@p wat=wain]] b=[c=@da d=[mod=@da who=@p wat=wain]]]
(lth (unt c.a) (unt c.b))
::
|
Remove double return statement | @@ -493,9 +493,6 @@ int DeRestPluginPrivate::createSensor(const ApiRequest &req, ApiResponse &rsp)
rsp.list.append(rspItem);
rsp.httpStatus = HttpStatusOk;
return REQ_READY_SEND;
-
-
- return REQ_READY_SEND;
}
/*! PUT, PATCH /api/<apikey>/sensors/<id>
|
Build fix for FreeBSD. | @@ -93,7 +93,7 @@ int nsa_socket(int domain, int type, int protocol, const char* properties)
pthread_mutex_unlock(&gSocketAPIInternals->nsi_socket_set_mutex);
}
else {
- errno = EUNATCH;
+ errno = ENXIO;
}
return(result);
}
|
naive: large batch test | owner.own:(got:orm points.state ~marbud)
==
::
+++ test-large-batch ^- tang
+ =+ batch-size=20 :: should be an even number
+ =/ tx-1 [[marbud-own %transfer-point (addr %marbud-key-1) |] %marbud-key-0]
+ =/ tx-2 [[marbud-own %transfer-point (addr %marbud-key-0) |] %marbud-key-1]
+ =+ nonce=0
+ ::
+ =| =^state:naive
+ =^ f state (init-marbud state)
+ %+ expect-eq
+ !> [`@ux`(addr %marbud-key-1) +(batch-size)]
+ ::
+ !>
+ |^
+ ?: =((mod nonce 2) 0)
+ =^ f state (n state %bat q:(gen-tx nonce tx-1)) loop
+ =^ f state (n state %bat q:(gen-tx nonce tx-2)) loop
+ ++ loop
+ ?: =(batch-size nonce)
+ owner.own:(got:orm points.state ~marbud)
+ $(nonce +(nonce))
+ --
+::
--
|
Remove obsolete typedefs | @@ -58,12 +58,6 @@ int select_set_callback(int fd, const struct select_callback *callback);
#define EEPROM_CONF_SIZE 1024
#endif
-/* These names are deprecated, use C99 names. */
-typedef uint8_t u8_t;
-typedef uint16_t u16_t;
-typedef uint32_t u32_t;
-typedef int32_t s32_t;
-
typedef unsigned int uip_stats_t;
#define LEDS_CONF_LEGACY_API 1
|
Python header decls | @@ -22,6 +22,9 @@ int codes_c_bufr_keys_iterator_get_name(int *iterid, char *name, int len);
int codes_c_bufr_keys_iterator_rewind(int *kiter);
int codes_c_bufr_keys_iterator_delete(int *iterid);
+int codes_c_bufr_multi_element_constant_arrays_off(void);
+int codes_c_bufr_multi_element_constant_arrays_on(void);
+
int grib_c_gribex_mode_on(void);
int grib_c_gribex_mode_off(void);
int grib_c_skip_computed(int *iterid);
|
docs - add gp_external_enable_filter_pushdown to external table parameters table. | <xref href="guc-list.xml#gp_external_enable_exec" type="section"
>gp_external_enable_exec</xref>
</p>
+ <p>
+ <xref href="guc-list.xml#gp_external_enable_filter_pushdown" type="section"
+ >gp_external_enable_filter_pushdown</xref>
+ </p>
<p>
<xref href="guc-list.xml#gp_external_max_segs" type="section"
>gp_external_max_segs</xref>
|
update ya tool arc
switch path-log to server if possible
remove unused base class | },
"arc": {
"formula": {
- "sandbox_id": [366051836],
+ "sandbox_id": [367180606],
"match": "arc"
},
"executable": {
|
Better error reporting in search query expression parser | @@ -28,8 +28,7 @@ namespace carto {
using qi::_1;
using qi::_2;
- unesc_char.add
- ("\\a", '\a')("\\b", '\b')("\\f", '\f')("\\n", '\n')
+ unesc_char.add("\\a", '\a')("\\b", '\b')("\\f", '\f')("\\n", '\n')
("\\r", '\r')("\\t", '\t')("\\v", '\v')("\\\\", '\\')
("\\\'", '\'')("\\\"", '\"');
@@ -113,11 +112,17 @@ namespace carto {
std::string::const_iterator end = expr.end();
queryexpressionimpl::encoding::space_type space;
std::shared_ptr<QueryExpression> queryExpr;
- bool result = boost::spirit::qi::phrase_parse(it, end, queryexpressionimpl::Grammar<std::string::const_iterator>(), space, queryExpr);
+ bool result = false;
+ try {
+ result = boost::spirit::qi::phrase_parse(it, end, queryexpressionimpl::Grammar<std::string::const_iterator>(), space, queryExpr);
+ }
+ catch (const boost::spirit::qi::expectation_failure<std::string::const_iterator>& ex) {
+ throw ParseException("Expectation error", expr, static_cast<int>(ex.first - expr.begin()));
+ }
if (!result) {
throw ParseException("Failed to parse query expression", expr);
} else if (it != expr.end()) {
- throw ParseException("Could not parse to the end of query expression", expr, static_cast<int>(expr.end() - it));
+ throw ParseException("Could not parse to the end of query expression", expr, static_cast<int>(it - expr.begin()));
}
return queryExpr;
}
|
Update cryptic network device names (Issue | @@ -280,7 +280,9 @@ pappl_dnssd_list(
bool ret = false; // Return value
cups_array_t *devices; // DNS-SD devices
_pappl_dns_sd_dev_t *device; // Current DNS-SD device
- char device_uri[1024];
+ char device_name[1024],
+ // Network device name
+ device_uri[1024];
// Network device URI
int last_count, // Last number of devices
timeout; // Timeout counter
@@ -336,12 +338,14 @@ pappl_dnssd_list(
// Do the callback for each of the devices...
for (device = (_pappl_dns_sd_dev_t *)cupsArrayFirst(devices); device; device = (_pappl_dns_sd_dev_t *)cupsArrayNext(devices))
{
+ snprintf(device_name, sizeof(device_name), "%s (DNS-SD Network Printer)", device->name);
+
if (device->uuid)
httpAssembleURIf(HTTP_URI_CODING_ALL, device_uri, sizeof(device_uri), "socket", NULL, device->fullName, 0, "/?uuid=%s", device->uuid);
else
httpAssembleURI(HTTP_URI_CODING_ALL, device_uri, sizeof(device_uri), "socket", NULL, device->fullName, 0, "/");
- if ((*cb)(device->name, device_uri, device->device_id, data))
+ if ((*cb)(device_name, device_uri, device->device_id, data))
{
ret = true;
break;
@@ -603,9 +607,9 @@ pappl_snmp_find(
model = "Printer";
if (!strcmp(make, "HP") && !strncmp(model, "HP ", 3))
- snprintf(info, sizeof(info), "%s (%s)", model, cur_device->addrname);
+ snprintf(info, sizeof(info), "%s (Network Printer %s)", model, cur_device->uri + 7);
else
- snprintf(info, sizeof(info), "%s %s (%s)", make, model, cur_device->addrname);
+ snprintf(info, sizeof(info), "%s %s (Network Printer %s)", make, model, cur_device->uri + 7);
if ((*cb)(info, cur_device->uri, cur_device->device_id, data))
{
|
Self-permissions issue. | =+ wyt=?=(?($white $green) p.cordon.con)
::x if we just created the story, and invite only, make sure we're in.
=. q.cordon.con ::TODO =?
- ?: &(neu wyt) q.cordon.con
- [our.hid ~ ~]
+ ?: &(neu wyt) [our.hid ~ ~]
+ q.cordon.con
pa-abet:(~(pa-reform pa man ~ pur) con)
::
++ ra-unconfig
|
decisions: usually -> sometimes
on purpose no rules on it, as it needs to be decided case-by-case. | @@ -95,7 +95,7 @@ For each solution a proposal, rationale and optionally implications should be gi
- "Decision", "Rationale" and "Implications" are now filled out and fixed according to the reviews
- decisions of this step usually already have an implementation PR
-Decisions that need an update, e.g. because assumptions changed, usually directly start with the step "Decided".
+Decisions that need an update, e.g. because assumptions changed, sometimes directly start with the step "Decided".
> In this step, decision PRs only modify a _single_ decision.
> Only exceptions like backlinks from other decisions are allowed.
|
[mechanics] typo in PrismaticJointR comments | @@ -236,7 +236,7 @@ void PrismaticJointR::computeh(double time, BlockVector& q0, SiconosVector& y)
// we can disable some warning
#pragma GCC diagnostic ignored "-Wunused-but-set-variable"
-/* sympy expreesion:
+/* sympy expression:
*
* G1G2d1 = unrot(G2-G1, q1)
*
|
ChatMessage: fix props destructure | @@ -255,7 +255,7 @@ interface ChatMessageProps {
}
function ChatMessage(props: ChatMessageProps) {
- let { highlighted } = this.props;
+ let { highlighted } = props;
const {
msg,
previousMsg,
|
parser: Var dynaload's type doesn't need to be copied. | @@ -1553,10 +1553,10 @@ static lily_type *get_type_raw(lily_parse_state *parser, int flags)
that sends flags as 0. */
#define get_type(p) get_type_raw(p, 0)
-/* Get a type represented by the name given. Largely used by dynaload. */
+/* Get this type, running a dynaload if necessary. Used bv var dynaload. */
static lily_type *type_by_name(lily_parse_state *parser, const char *name)
{
- lily_lexer_load(parser->lex, et_copied_string, name);
+ lily_lexer_load(parser->lex, et_shallow_string, name);
lily_lexer(parser->lex);
lily_type *result = get_type(parser);
lily_pop_lex_entry(parser->lex);
|
enable default peers | @@ -27,8 +27,8 @@ config kadnode
# option peerfile '/etc/kadnode/peers.txt'
## Add static peers addresses.
-# list peer 'bttracker.debian.org:6881'
-# list peer 'router.bittorrent.com:6881'
+ list peer 'bttracker.debian.org:6881'
+ list peer 'router.bittorrent.com:6881'
## Bind the DHT to this port.
# option port '6881'
|
example/openssl: disable CRYPTO_memcmp | @@ -30,6 +30,18 @@ diff -Nur ORIG.openssl-1.1.0e/Configure openssl-1.1.0e/Configure
unless ($disabled{asan}) {
$config{cflags} .= "-fsanitize=address ";
}
+diff -Nur ORIG.openssl-1.1.0e/crypto/cryptlib.c openssl-1.1.0e/crypto/cryptlib.c
+--- ORIG.openssl-1.1.0e/crypto/cryptlib.c 2017-02-16 12:58:21.000000000 +0100
++++ openssl-1.1.0e/crypto/cryptlib.c 2017-02-19 17:03:41.093898461 +0100
+@@ -324,7 +324,7 @@
+ * pointers to volatile to not be emitted in some rare,
+ * never needed in real life, pieces of code.
+ */
+-int CRYPTO_memcmp(const volatile void * volatile in_a,
++int DISABLED_CRYPTO_memcmp(const volatile void * volatile in_a,
+ const volatile void * volatile in_b,
+ size_t len)
+ {
diff -Nur ORIG.openssl-1.1.0e/include/openssl/crypto.h openssl-1.1.0e/include/openssl/crypto.h
--- ORIG.openssl-1.1.0e/include/openssl/crypto.h 2017-02-16 12:58:23.000000000 +0100
+++ openssl-1.1.0e/include/openssl/crypto.h 2017-02-19 17:01:34.004166029 +0100
|
Use cmp_ok and is for comparison | @@ -59,8 +59,8 @@ $resp = `curl --silent -o /dev/stderr http://127.0.0.1:${server2_port}/server-st
$jresp = decode_json("$resp");
my $num_forwarded = $jresp->{'http3.packet-forwarded'};
-ok($num_forwarded > 0, "some packets were forwarded through event counter");
-ok($num_forwarded == $num_forwarded_received, "packets forwarded == packets received");
+cmp_ok($num_forwarded, '>', 0, "some packets were forwarded through event counter");
+is($num_forwarded, num_forwarded_received, "packets forwarded == packets received");
done_testing;
|
admin/nagios: daemon-init is now default-init | @@ -201,7 +201,7 @@ install -p -m 0644 %{SOURCE10} %{SOURCE11} %{SOURCE12} html/images/logos/
make %{?_smp_mflags} all
#sed -i -e "s| package Embed::Persistent;|#\!%{_bindir}/perl\npackage Embed::Persistent;|" p1.pl
-sed -i -e "s|NagiosCmd=/var/log/nagios/rw/nagios.cmd|NagiosCmd=%{_localstatedir}/spool/%{pname}/cmd/nagios.cmd|" daemon-init
+sed -i -e "s|NagiosCmd=/var/log/nagios/rw/nagios.cmd|NagiosCmd=%{_localstatedir}/spool/%{pname}/cmd/nagios.cmd|" default-init
sed -i -e "s|resource.cfg|private/resource.cfg|" \
-e "s|#query_socket=/var/log/nagios/rw/nagios.qh|query_socket=%{_localstatedir}/log/%{pname}/nagios.qh|" \
-e "s|command_file=/var/log/nagios/rw/nagios.cmd|command_file=%{_localstatedir}/spool/%{pname}/cmd/nagios.cmd|" sample-config/nagios.cfg
|
Improve naming of script builder args | @@ -258,7 +258,7 @@ class ScriptBuilder {
output.push(lo(stringIndex));
};
- textChoice = (variable, args) => {
+ textChoice = (setVariable, args) => {
const output = this.output;
const { strings, variables } = this.options;
const choiceText = combineMultipleChoiceText(args);
@@ -267,7 +267,7 @@ class ScriptBuilder {
strings.push(choiceText);
stringIndex = strings.length - 1;
}
- const variableIndex = getVariableIndex(variable, variables);
+ const variableIndex = getVariableIndex(setVariable, variables);
output.push(cmd(CHOICE));
output.push(hi(variableIndex));
output.push(lo(variableIndex));
@@ -337,9 +337,9 @@ class ScriptBuilder {
output.push(value);
};
- variableCopy = (variableA, variableB) => {
+ variableCopy = (setVariable, otherVariable) => {
const output = this.output;
- this.vectorsLoad(variableA, variableB);
+ this.vectorsLoad(setVariable, otherVariable);
output.push(cmd(COPY_VALUE));
};
@@ -354,33 +354,33 @@ class ScriptBuilder {
output.push(range);
};
- variablesAdd = (variableA, variableB) => {
+ variablesAdd = (setVariable, otherVariable) => {
const output = this.output;
- this.vectorsLoad(variableA, variableB);
+ this.vectorsLoad(setVariable, otherVariable);
output.push(cmd(MATH_ADD_VALUE));
};
- variablesSub = (variableA, variableB) => {
+ variablesSub = (setVariable, otherVariable) => {
const output = this.output;
- this.vectorsLoad(variableA, variableB);
+ this.vectorsLoad(setVariable, otherVariable);
output.push(cmd(MATH_SUB_VALUE));
};
- variablesMul = (variableA, variableB) => {
+ variablesMul = (setVariable, otherVariable) => {
const output = this.output;
- this.vectorsLoad(variableA, variableB);
+ this.vectorsLoad(setVariable, otherVariable);
output.push(cmd(MATH_MUL_VALUE));
};
- variablesDiv = (variableA, variableB) => {
+ variablesDiv = (setVariable, otherVariable) => {
const output = this.output;
- this.vectorsLoad(variableA, variableB);
+ this.vectorsLoad(setVariable, otherVariable);
output.push(cmd(MATH_DIV_VALUE));
};
- variablesMod = (variableA, variableB) => {
+ variablesMod = (setVariable, otherVariable) => {
const output = this.output;
- this.vectorsLoad(variableA, variableB);
+ this.vectorsLoad(setVariable, otherVariable);
output.push(cmd(MATH_MOD_VALUE));
};
|
isaac's eyre changes to polling parameters as requested by Logan | {$poll p/{i/@uvH t/(list @uvH)}}
{$spur p/spur}
{$subs p/?($put $delt) q/{dock $json wire path}}
- {$view p/ixor q/{$~ u/@ud}}
+ ::{$view p/ixor q/{$~ u/@ud}}
+ {$view p/ixor q/{$~ u/@ud} r/(unit @dr)}
==
::
++ perk-auth :: parsed auth
(turn dep |=({a/@tas $~} (slav %uv a)))
::
$of
- :+ %view ?>(?=({@ $~} but) i.but)
- ?> ?=({{$poll @} $~} quy) :: XX eventsource
+ :^ %view
+ ?> ?=({@ $~} but)
+ i.but
+ ?> ?=({{$poll @} *} quy) :: XX eventsource
[~ (rash q.i.quy dem)]
+ ?: ?=({{$t @} $~} +.quy)
+ =/ s (rash q.i.t.quy dem)
+ `(yule [0 0 0 s ~])
+ ~
::
$to
=+ ^- dir/{p/ship q/term r/mark}
::
$view
~| lost-ixor+p.hem
- [%| ((teba poll:(ire-ix p.hem)) u.q.hem)]
+ [%| ((teba poll:(ire-ix p.hem)) u.q.hem r.hem)]
==
::
++ process-auth
::
++ pop-duct =^(ned med ~(get to med) abet(hen ned))
++ poll
- |= a/@u ^+ ..ix
+ |= [a/@u t=(unit @dr)]
+ ^+ ..ix
=< abet
=. ..poll refresh
?: =(a p.eve)
=. ..poll poll-rest
- =. era (add ~s30 now)
+ =. era
+ ?~ t (add ~s30 now)
+ (add u.t now)
=. lyv (~(put by lyv) hen [%poll ire])
pass-wait(ude [~ hen &])
?: (gth a p.eve) ~|(seq-high+cur=p.eve !!)
|
Fix bug related to allocation size in lv_img_decoder.c | @@ -354,7 +354,7 @@ static const uint8_t * lv_img_decoder_built_in_open(lv_img_decoder_t * decoder,
}
lv_img_decoder_built_in_data_t * user_data = dsc->user_data;
- user_data->palette = lv_mem_alloc(sizeof(palette_size * sizeof(lv_color_t)));
+ user_data->palette = lv_mem_alloc(palette_size * sizeof(lv_color_t));
if(user_data->palette == NULL) {
LV_LOG_ERROR("img_decoder_built_in_open: out of memory");
#if LV_USE_FILESYSTEM
|
Add LambdaTemplateParam test. | @@ -25,6 +25,10 @@ Y_UNIT_TEST_SUITE(Demangle) {
Check("_ZNKSt3__110__function6__funcIZN4DLCL8DLFutureIP15AnalysenManagerE3setINS_8functionIFS5_vEEEJEEEvT_DpOT0_EUlvE_NS_9allocatorISF_EEFvvEE7__cloneEv", "std::__1::__function::__func<void DLCL::DLFuture<AnalysenManager*>::set<std::__1::function<AnalysenManager* ()> >(std::__1::function<AnalysenManager* ()>)::'lambda'(), std::__1::allocator<void DLCL::DLFuture<AnalysenManager*>::set<std::__1::function<AnalysenManager* ()> >(std::__1::function<AnalysenManager* ()>)::'lambda'()>, void ()>::__clone() const");
}
+ Y_UNIT_TEST(LambdaTemplateParam) {
+ Check("_Z1bIZN1cC1EvEUlT_E_EvS1_", "void b<c::c()::'lambda'(auto)>(auto)");
+ }
+
Y_UNIT_TEST(Difficult1) {
Check("_ZNSt4__y16vectorIN2na2caINS1_2nb2cbEEENS_9allocatorIS5_EEE6assignIPS5_EENS_9enable_ifIXaasr21__is_forward_iteratorIT_EE5valuesr16is_constructibleIS5_NS_15iterator_traitsISC_E9referenceEEE5valueEvE4typeESC_SC_", "std::__y1::enable_if<(__is_forward_iterator<na::ca<na::nb::cb>*>::value) && (is_constructible<na::ca<na::nb::cb>, std::__y1::iterator_traits<na::ca<na::nb::cb>*>::reference>::value), void>::type std::__y1::vector<na::ca<na::nb::cb>, std::__y1::allocator<na::ca<na::nb::cb> > >::assign<na::ca<na::nb::cb>*>(na::ca<na::nb::cb>*, na::ca<na::nb::cb>*)");
}
|
Update BCC to fix trace bind issue | @@ -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:a432665d57f5fe10e30e6420208462711f865d5f-focal-release"
+ARG BCC="quay.io/kinvolk/bcc:401c6c81f131d539e49646ab337d3a738c7be47d-focal-release"
FROM ${BCC} as bcc
FROM --platform=${BUILDPLATFORM} ${BUILDER_IMAGE} as builder
|
Fix dname_has_label() code review changes | @@ -549,9 +549,13 @@ dname_lab_startswith(uint8_t* label, char* prefix, char** endptr)
int
dname_has_label(uint8_t* dname, uint8_t* label)
{
- uint8_t lablen = *dname++;
- if(memlowercmp(dname, label, lablen) == 0)
+ uint8_t lablen = *dname;
+ while(lablen) {
+ if(lablen == *label && memlowercmp(dname, label, lablen) == 0)
return 1;
+ dname += lablen;
+ lablen = *dname;
+ }
return 0;
}
|
Update hkRootLevelContainer.cs
fix compiler warnings | @@ -5,9 +5,9 @@ public unsafe partial struct hkRootLevelContainer
{
public struct NamedVariant
{
- hkStringPtr Name;
- hkStringPtr ClassName;
- hkRefPtr<hkReferencedObject> Variant;
+ public hkStringPtr Name;
+ public hkStringPtr ClassName;
+ public hkRefPtr<hkReferencedObject> Variant;
};
public hkArray<NamedVariant> NamedVariants;
|
Solve architecture info on WindowsDesktopSystemInformationImpl.cpp | @@ -132,7 +132,7 @@ namespace PAL_NS_BEGIN {
const PCSTR c_currentVersion_Key = "SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion";
const PCSTR c_buildLabEx_ValueName = "BuildLabEx";
DWORD size = sizeof(buff);
- RegGetValueA(HKEY_LOCAL_MACHINE, c_currentVersion_Key, c_buildLabEx_ValueName, RRF_RT_REG_SZ, NULL, (char*)buff, &size);
+ RegGetValueA(HKEY_LOCAL_MACHINE, c_currentVersion_Key, c_buildLabEx_ValueName, RRF_RT_REG_SZ | RRF_SUBKEY_WOW6464KEY, NULL, (char*)buff, &size);
return buff;
}
|
Corrected ZCash difficulty calculation. Fixes | @@ -166,7 +166,7 @@ namespace MiningCore.Blockchain.ZCash
BlockTemplate = blockTemplate;
JobId = jobId;
- Difficulty = (double) new BigRational(ZCashConstants.Diff1b, BlockTemplate.Target.HexToByteArray().ToBigInteger());
+ Difficulty = (double) new BigRational(ZCashConstants.Diff1b, BlockTemplate.Target.HexToByteArray().ReverseArray().ToBigInteger());
this.isPoS = isPoS;
this.shareMultiplier = shareMultiplier;
|
Use pkt_ts which is the timestamp when a packet is received | @@ -6636,7 +6636,8 @@ conn_recv_delayed_handshake_pkt(ngtcp2_conn *conn, const ngtcp2_pkt_hd *hd,
ngtcp2_acktr_immediate_ack(&pktns->acktr);
}
- rv = ngtcp2_conn_sched_ack(conn, &pktns->acktr, hd->pkt_num, require_ack, ts);
+ rv = ngtcp2_conn_sched_ack(conn, &pktns->acktr, hd->pkt_num, require_ack,
+ pkt_ts);
if (rv != 0) {
return rv;
}
|
add optional installation folder for macOS to compiling documentation | @@ -120,12 +120,12 @@ or execute (Debian-based systems only): `apt-get install gcc build-essential cma
1. Change into the project source directory: `cd stlink`
2. Run `make clean` -- required by some linux variants.
3. Run `make release` to create the _Release_ target
-4. Run `make install` to full install the package with complete system integration
+4. Run `make install` to full install the package with complete system integration. This might require sudo permissions.
5. Run `make debug` to create the _Debug_ target (_optional_)<br />
The debug target is only necessary in order to modify the sources and to run under a debugger.
6. Run `make package`to build a Debian Package. The generated packages can be found in the subdirectory `./build/dist`.
-As an option you may also install to an individual user-defined folder e.g `$HOME` with `make install DESTDIR=$HOME`.
+> **Note** As an option you may also install to an individual user-defined folder e.g `$HOME` with `make install DESTDIR=$HOME`.
#### Removal:
@@ -219,6 +219,8 @@ To do this with only one simple command, type:
5. Run `make debug` to create the _Debug_ target (_optional_)<br />
The debug target is only necessary in order to modify the sources and to run under a debugger.
+> **Note** As an option you may also install to an individual user-defined folder e.g `$HOME` with `make install DESTDIR=$HOME`.
+
## Build options
### Build using a different directory for shared libs
|
Update lv_ta.c | @@ -1623,7 +1623,6 @@ static void get_cursor_style(lv_obj_t * ta, lv_style_t * style_res)
style_res->body.padding.top = 0;
style_res->body.padding.bottom = 0;
style_res->line.width = 1;
- style_res->body.opa = LV_OPA_COVER;
}
}
|
[components][USB][Device][Core]fix the device_qualifier error respond on fullspeed | @@ -194,7 +194,18 @@ static rt_err_t _get_descriptor(struct udevice* device, ureq_t setup)
_get_string_descriptor(device, setup);
break;
case USB_DESC_TYPE_DEVICEQUALIFIER:
+ /* If a full-speed only device (with a device descriptor version number equal to 0200H) receives a
+ GetDescriptor() request for a device_qualifier, it must respond with a request error. The host must not make
+ a request for an other_speed_configuration descriptor unless it first successfully retrieves the
+ device_qualifier descriptor. */
+ if(device->dcd->device_is_hs)
+ {
_get_qualifier_descriptor(device, setup);
+ }
+ else
+ {
+ rt_usbd_ep0_set_stall(device);
+ }
break;
case USB_DESC_TYPE_OTHERSPEED:
_get_config_descriptor(device, setup);
|
Improve decoder stopped event
The syntax was correct, but less readable, and it unnecessarily zeroed
the fields other than "type".
Create the event properly, from a separate method. | @@ -33,6 +33,12 @@ static void push_frame(struct decoder *decoder) {
SDL_PushEvent(&new_frame_event);
}
+static void notify_stopped(void) {
+ SDL_Event stop_event;
+ stop_event.type = EVENT_DECODER_STOPPED;
+ SDL_PushEvent(&stop_event);
+}
+
static int run_decoder(void *data) {
struct decoder *decoder = data;
int ret = 0;
@@ -137,7 +143,7 @@ run_finally_close_codec:
avcodec_close(codec_ctx);
run_finally_free_codec_ctx:
avcodec_free_context(&codec_ctx);
- SDL_PushEvent(&(SDL_Event) {.type = EVENT_DECODER_STOPPED});
+ notify_stopped();
return ret;
}
|
Fix ODCID handling by the server | @@ -1339,9 +1339,6 @@ int picoquic_incoming_segment(
/* Verify that the source CID matches expectation */
if (picoquic_is_connection_id_null(cnx->path[0]->remote_cnxid)) {
cnx->path[0]->remote_cnxid = ph.srce_cnx_id;
- if (cnx->client_mode == 0) {
- cnx->local_parameters.original_destination_connection_id = ph.dest_cnx_id;
- }
} else if (picoquic_compare_connection_id(&cnx->path[0]->remote_cnxid, &ph.srce_cnx_id) != 0) {
DBG_PRINTF("Error wrong srce cnxid (%d), type: %d, epoch: %d, pc: %d, pn: %d\n",
cnx->client_mode, ph.ptype, ph.epoch, ph.pc, (int)ph.pn);
@@ -1350,6 +1347,7 @@ int picoquic_incoming_segment(
if (ret == 0) {
if (cnx->client_mode == 0) {
/* TODO: finish processing initial connection packet */
+ cnx->local_parameters.original_destination_connection_id = ph.dest_cnx_id;
ret = picoquic_incoming_initial(&cnx, bytes,
addr_from, addr_to, if_index_to, &ph, current_time, *new_context_created);
}
|
Bipship: Add SKUID for non-keyboard backlight SKUs
BRANCH=octopus
TEST=make buildall -j.
Tested-by: Justin TerAvest | @@ -332,7 +332,7 @@ __override uint32_t board_override_feature_flags0(uint32_t flags0)
* Remove keyboard backlight feature for devices that don't support it.
*/
if (sku_id == 33 || sku_id == 36 || sku_id == 51 ||
- sku_id == 52 || sku_id == 66 || sku_id == 68)
+ sku_id == 52 || sku_id == 53 || sku_id == 66 || sku_id == 68)
return (flags0 & ~EC_FEATURE_MASK_0(EC_FEATURE_PWM_KEYB));
else
return flags0;
|
Fixed item WEIGHT property not working correctly
This issue was caused by previous commit | @@ -32,7 +32,7 @@ CItemBase::CItemBase(ITEMID_TYPE id) : CBaseBaseDef(RESOURCE_ID(RES_ITEMDEF, id)
if ( id < ITEMID_MULTI )
GetItemData(id, &tiledata);
else
- tiledata.m_weight = 0xFF;
+ tiledata.m_weight = UCHAR_MAX;
m_dwFlags = tiledata.m_flags;
m_type = GetTypeBase(id, tiledata);
@@ -51,7 +51,7 @@ CItemBase::CItemBase(ITEMID_TYPE id) : CBaseBaseDef(RESOURCE_ID(RES_ITEMDEF, id)
SetHeight(GetItemHeightFlags(tiledata, m_Can));
GetItemSpecificFlags(tiledata, m_Can, m_type, id);
- if ( (tiledata.m_weight == 0xFF) || (tiledata.m_flags & UFLAG1_WATER) ) // not movable
+ if ( (tiledata.m_weight == UCHAR_MAX) || (tiledata.m_flags & UFLAG1_WATER) ) // not movable
m_weight = USHRT_MAX;
else
m_weight = tiledata.m_weight * WEIGHT_UNITS;
@@ -1421,12 +1421,10 @@ bool CItemBase::r_LoadVal(CScript &s)
m_values.Load(s.GetArgRaw());
break;
case IBC_WEIGHT:
- {
m_weight = static_cast<WORD>(s.GetArgVal());
- if ( !strchr(s.GetArgStr(), '.') )
+ if ( strchr(s.GetArgStr(), '.') )
m_weight *= WEIGHT_UNITS;
break;
- }
default:
return CBaseBaseDef::r_LoadVal(s);
}
|
Shortcut icons are prevented from being dragged off-screen | @@ -355,6 +355,21 @@ static void _end_mouse_drag(mouse_interaction_state_t* state, Point mouse_point)
}
}
+static Rect rect_bind_to_screen_frame(Rect inp) {
+ inp.origin.x = max(inp.origin.x, 0);
+ inp.origin.y = max(inp.origin.y, 0);
+
+ if (inp.origin.x + inp.size.width >= _screen.resolution.width) {
+ uint32_t overhang = inp.origin.x + inp.size.width - _screen.resolution.width;
+ inp.origin.x -= overhang;
+ }
+ if (inp.origin.y + inp.size.height >= _screen.resolution.height) {
+ uint32_t overhang = inp.origin.y + inp.size.height - _screen.resolution.height;
+ inp.origin.y -= overhang;
+ }
+ return inp;
+}
+
static void _adjust_window_position(user_window_t* window, int32_t delta_x, int32_t delta_y) {
Rect original_frame = window->frame;
@@ -362,8 +377,7 @@ static void _adjust_window_position(user_window_t* window, int32_t delta_x, int3
window->frame.origin.y += delta_y;
// Don't let the window go off-screen
- window->frame.origin.x = max(window->frame.origin.x, 0);
- window->frame.origin.y = max(window->frame.origin.y, 0);
+ window->frame = rect_bind_to_screen_frame(window->frame);
if (window->frame.origin.x + window->frame.size.width >= _screen.resolution.width) {
uint32_t overhang = window->frame.origin.x + window->frame.size.width - _screen.resolution.width;
@@ -389,7 +403,6 @@ static void _handle_mouse_dragged(mouse_interaction_state_t* state, Point mouse_
// Nothing to do if we didn't start the drag with a hover window
if (!state->active_window) {
if (state->hovered_shortcut) {
- //printf("Drag shortcut icon %s\n", state->hovered_shortcut->display_name);
Rect original_frame = state->hovered_shortcut->view->frame;
Rect new_frame = rect_make(
point_make(
@@ -398,8 +411,12 @@ static void _handle_mouse_dragged(mouse_interaction_state_t* state, Point mouse_
),
original_frame.size
);
+ // Don't let the shortcut go off-screen
+ new_frame = rect_bind_to_screen_frame(new_frame);
state->hovered_shortcut->view->frame = new_frame;
- array_t* delta = rect_diff(rect_union(original_frame, new_frame), new_frame);
+
+ Rect total_update_frame = rect_union(original_frame, new_frame);
+ array_t* delta = rect_diff(total_update_frame, new_frame);
for (int32_t i = delta->size - 1; i >= 0; i--) {
Rect* r = array_lookup(delta, i);
queue_rect_to_update_this_cycle(*r);
@@ -407,8 +424,7 @@ static void _handle_mouse_dragged(mouse_interaction_state_t* state, Point mouse_
}
array_destroy(delta);
- //queue_rect_to_update_this_cycle(rect_union(original_frame, new_frame));
- windows_invalidate_drawable_regions_in_rect(rect_union(original_frame, new_frame));
+ windows_invalidate_drawable_regions_in_rect(total_update_frame);
}
else {
printf("Drag on desktop background\n");
|
[Docs] specify Digital Signature byte order, and esp_ds_sign() clarification | @@ -84,6 +84,9 @@ typedef struct esp_digital_signature_data {
* This is only used for encrypting the RSA parameters by calling esp_ds_encrypt_params().
* Afterwards, the result can be stored in flash or in other persistent memory.
* The encryption is a prerequisite step before any signature operation can be done.
+ *
+ * @note
+ * Y, M, Rb, & M_Prime must all be in little endian format.
*/
typedef struct {
uint32_t Y[ESP_DS_SIGNATURE_MAX_BIT_LEN / 32]; //!< RSA exponent
@@ -108,7 +111,9 @@ typedef struct {
* @note
* Please see note section of \c esp_ds_start_sign() for more details about the input parameters.
*
- * @param message the message to be signed; its length should be (data->rsa_length + 1)*4 bytes
+ * @param message the message to be signed; its length should be (data->rsa_length + 1)*4 bytes, and those
+ bytes must be in little endian format. It is your responsibility to apply your hash function
+ and padding before calling this function, if required. (e.g. message = padding(hash(inputMsg)))
* @param data the encrypted signing key data (AES encrypted RSA key + IV)
* @param key_id the HMAC key ID determining the HMAC key of the HMAC which will be used to decrypt the
* signing key data
@@ -149,7 +154,9 @@ esp_err_t esp_ds_sign(const void *message,
* No padding is applied to the message automatically, Please ensure the message is appropriate padded before
* calling the API.
*
- * @param message the message to be signed; its length should be (data->rsa_length + 1)*4 bytes
+ * @param message the message to be signed; its length should be (data->rsa_length + 1)*4 bytes, and those
+ bytes must be in little endian format. It is your responsibility to apply your hash function
+ and padding before calling this function, if required. (e.g. message = padding(hash(inputMsg)))
* @param data the encrypted signing key data (AES encrypted RSA key + IV)
* @param key_id the HMAC key ID determining the HMAC key of the HMAC which will be used to decrypt the
* signing key data
@@ -177,7 +184,8 @@ bool esp_ds_is_busy(void);
/**
* @brief Finish the signing process.
*
- * @param signature the destination of the signature, should be (data->rsa_length + 1)*4 bytes long
+ * @param signature the destination of the signature, should be (data->rsa_length + 1)*4 bytes long,
+ the resultant signature bytes shall be written in little endian format.
* @param esp_ds_ctx the context object retreived by \c esp_ds_start_sign()
*
* @return
|
natpmp: formatting and cleanup old pmp handle | @@ -75,7 +75,7 @@ maxRetries = 3
-- How long to wait between retries.
networkRetryDelay :: Int
-networkRetryDelay = 5 * 1000000
+networkRetryDelay = 5 * 1_000_000
-- Messages sent from the main thread to the port mapping communication thread.
data PortThreadMsg
@@ -172,6 +172,7 @@ portThread q stderr = do
displayShow ("port: sending initial request to NAT-PMP for port ", p)
setPortMapping pmp PTUdp p p portLeaseLifetime >>= \case
Left err | isResetAndRetry err -> do
+ closeNatPmp pmp
attemptReestablishNatPmpThen (\pmp -> handlePTM pmp msg nextRenew)
Left err -> do
logError $
@@ -208,6 +209,7 @@ portThread q stderr = do
p)
setPortMapping pmp PTUdp p p portLeaseLifetime >>= \case
Left err | isResetAndRetry err -> do
+ closeNatPmp pmp
attemptReestablishNatPmpThen (\pmp -> handleRenew pmp nextRenew)
Left err -> do
logError $
|
SOVERSION bump to version 7.13.0 | @@ -72,8 +72,8 @@ set(SYSREPO_VERSION ${SYSREPO_MAJOR_VERSION}.${SYSREPO_MINOR_VERSION}.${SYSREPO_
# Major version is changed with every backward non-compatible API/ABI change, minor version changes
# with backward compatible change and micro version is connected with any internal change of the library.
set(SYSREPO_MAJOR_SOVERSION 7)
-set(SYSREPO_MINOR_SOVERSION 12)
-set(SYSREPO_MICRO_SOVERSION 3)
+set(SYSREPO_MINOR_SOVERSION 13)
+set(SYSREPO_MICRO_SOVERSION 0)
set(SYSREPO_SOVERSION_FULL ${SYSREPO_MAJOR_SOVERSION}.${SYSREPO_MINOR_SOVERSION}.${SYSREPO_MICRO_SOVERSION})
set(SYSREPO_SOVERSION ${SYSREPO_MAJOR_SOVERSION})
|
Limit bounds of start selection area
Clicking outside the grid are was unselecting the notes making it impossible to realize other actions like move as it requires clicking on the pencil icon | @@ -199,6 +199,8 @@ export const RollChannelSelectionAreaFwd = ({
selectionOrigin,
cellSize,
selectCellsInRange,
+ addToSelection,
+ selectedPatternCells,
dispatch,
]
);
@@ -233,12 +235,10 @@ export const RollChannelSelectionAreaFwd = ({
useEffect(() => {
window.addEventListener("mouseup", handleMouseUp);
- window.addEventListener("mousedown", handleMouseDown);
window.addEventListener("mousemove", handleMouseMove);
return () => {
window.removeEventListener("mouseup", handleMouseUp);
- window.removeEventListener("mousedown", handleMouseDown);
window.removeEventListener("mousemove", handleMouseMove);
};
});
@@ -283,6 +283,9 @@ export const RollChannelSelectionAreaFwd = ({
cols={64}
size={cellSize}
canSelect={tool === "selection"}
+ onMouseDown={(e) => {
+ handleMouseDown(e.nativeEvent);
+ }}
onMouseLeave={(e) => {
handleMouseLeave(e.nativeEvent);
}}
|
Improve code to force high to be > low | @@ -989,14 +989,13 @@ void compute_quantized_weights_for_decimation(
// Quantize the weight set using both the specified low/high bounds and standard 0..1 bounds
- /* TODO: WTF issue that we need to examine some time. */
- if (!((high_bound - low_bound) > 0.5f))
+ /* TODO: WTF issue that we need to examine some time. Triggered by test in issue #265. */
+ if (high_bound < low_bound)
{
low_bound = 0.0f;
high_bound = 1.0f;
}
- assert(high_bound > low_bound);
float rscale = high_bound - low_bound;
float scale = 1.0f / rscale;
|
Hall can now perform customizable filtering on incoming messages.
Uses a `|=(telegram ...)` supplied by /app/hall/filter.hoon | /- hall :: structures
/+ hall, hall-legacy :: libraries
/= seed /~ !>(.)
+/= filter-gram
+ /^ $-(telegram:hall telegram:hall)
+ /| /: /%/filter /!noun/
+ /~ |=(t/telegram:hall t)
+ ==
::
::::
::
?. (so-admire aut.gam) +>
:: clean up the message to conform to our rules.
=. sep.gam (so-sane sep.gam)
+ =. gam (filter-gram gam)
:: if we already have it, ignore.
=+ old=(~(get by known) uid.gam)
?. &(?=(^ old) =(gam (snag u.old grams)))
|
fixed custom cursor rendering | @@ -1937,7 +1937,7 @@ static void blitCursor()
tic_mem* tic = impl.studio.tic;
tic80_mouse* m = &tic->ram.input.mouse;
- if(tic->input.mouse && m->x < TIC80_FULLWIDTH && m->y < TIC80_FULLHEIGHT)
+ if(tic->input.mouse && !m->relative && m->x < TIC80_FULLWIDTH && m->y < TIC80_FULLHEIGHT)
{
const tic_bank* bank = &tic->cart.bank0;
|
Silence a ton of clang warnings | # define SIMDE__FUNCTION_ATTRIBUTES HEDLEY_INLINE SIMDE__ARTIFICIAL static
#endif
+#if HEDLEY_HAS_WARNING("-Wused-but-marked-unused")
+# define SIMDE_DIAGNOSTIC_DISABLE_USED_BUT_MARKED_UNUSED _Pragma("clang diagnostic ignored \"-Wused-but-marked-unused\"")
+#else
+# define SIMDE_DIAGNOSTIC_DISABLE_USED_BUT_MARKED_UNUSED
+#endif
+
#if defined(_MSC_VER)
# define SIMDE__BEGIN_DECLS HEDLEY_DIAGNOSTIC_PUSH __pragma(warning(disable:4996 4204)) HEDLEY_BEGIN_C_DECLS
# define SIMDE__END_DECLS HEDLEY_DIAGNOSTIC_POP HEDLEY_END_C_DECLS
#else
-# define SIMDE__BEGIN_DECLS HEDLEY_BEGIN_C_DECLS
-# define SIMDE__END_DECLS HEDLEY_END_C_DECLS
+# define SIMDE__BEGIN_DECLS \
+ HEDLEY_DIAGNOSTIC_PUSH \
+ SIMDE_DIAGNOSTIC_DISABLE_USED_BUT_MARKED_UNUSED \
+ HEDLEY_BEGIN_C_DECLS
+# define SIMDE__END_DECLS \
+ HEDLEY_END_C_DECLS \
+ HEDLEY_DIAGNOSTIC_POP
#endif
#if HEDLEY_HAS_WARNING("-Wpedantic")
|
update-latest: check if hub exists first | @@ -5,4 +5,6 @@ git push origin :refs/tags/$TAG_NAME
git tag -fa -m "$TAG_NAME" $TAG_NAME
git push origin master --tags
+if which hub; then
hub release -f "%T (%S) %n" --include-drafts | grep " (draft)" | awk '{print $1}' | xargs -t -n1 hub release delete
+fi
\ No newline at end of file
|
test-suite: switch to pkgconfig for build test and update module
refresh to match latest syntax | @@ -27,7 +27,7 @@ setup() {
}
@test "[spack] test build" {
- spack install libjpeg-turbo
+ spack install pkgconf
assert_success
}
@@ -36,11 +36,11 @@ setup() {
spack compiler find
assert_success
- spack install libjpeg-turbo%clang
+ spack install pkgconf%clang
assert_success
}
@test "[spack] test module refresh" {
- echo y | spack module refresh
+ echo y | spack module tcl refresh
assert_success
}
|
Fix 0 -> NULL, indentation | @@ -522,7 +522,7 @@ static BIGNUM *asn1_string_to_bn(const ASN1_INTEGER *ai, BIGNUM *bn,
}
ret = BN_bin2bn(ai->data, ai->length, bn);
- if (ret == 0) {
+ if (ret == NULL) {
ASN1err(ASN1_F_ASN1_STRING_TO_BN, ASN1_R_BN_LIB);
return NULL;
}
|
fixup! netcmd/ping: fix build breaks and wrong function name in the logs | @@ -212,14 +212,14 @@ static void ping_recv(int family, int s, struct timespec *ping_time)
fromlen = sizeof(struct sockaddr_in);
} else {
printf("ping_recv: invalid family\n");
- return ERROR;
+ return;
}
/* allocate memory due to difference of size between ipv4/v6 socket structure */
from = malloc(fromlen);
if (from == NULL) {
printf("ping_recv: fail to allocate memory\n");
- return ERROR;
+ return;
}
while (1) {
@@ -311,14 +311,12 @@ static void ping_recv(int family, int s, struct timespec *ping_time)
}
free(from);
- return OK;
+ return;
err_out:
if (from) {
free(from);
from = NULL;
}
-
- return ERROR;
}
static void ping_prepare_echo(int family, struct icmp_echo_hdr *iecho, u16_t len)
@@ -357,7 +355,7 @@ static void ping_prepare_echo(int family, struct icmp_echo_hdr *iecho, u16_t len
}
}
-static int ping_send(int s, struct sockaddr_in *to, int size)
+static int ping_send(int s, struct sockaddr *to, int size)
{
int ret;
size_t icmplen;
@@ -380,7 +378,7 @@ static int ping_send(int s, struct sockaddr_in *to, int size)
iecho = (struct icmp_echo_hdr *)malloc(icmplen);
if (!iecho) {
- printf("ping_send: fail to alloc mem\n");
+ printf("ping_send: fail to allocate memory\n");
return ERROR;
}
|
BugID:17657855:[gen_linkkit_sdk.py] remove tests before export SDK | @@ -61,6 +61,11 @@ def main(argv):
# replace ip address
print("[INFO]: replace test information")
replace(targetFilename, replace_ip_rules)
+
+ # remove tests directory
+ print("[INFO]: remove %s" % os.path.join(build_dir, SDKNAME, "tests"))
+ shutil.rmtree(os.path.join(build_dir, SDKNAME, "tests"))
+
# Generate tarball
root_dir = build_dir
base_dir = SDKNAME
|
Fixed tagXSstrandedData.awk script. | @@ -6,11 +6,9 @@ BEGIN {
{
- printf $0;
-
- if (substr($1,1,1)=="@")
- {# header - nothing to do
- printf "\n";
+ if (substr($1,1,1)=="@" || $4==0)
+ {# header, or unmapped read - just print
+ print;
next;
};
@@ -25,11 +23,11 @@ BEGIN {
};
if (mate>0 && mate <3)
- {# mate is defined
+ {# mate is defined - add XS tag
if (mate!=strType) str=1-str; #revert strand if the mate is opposite
- printf "\t" "XS:A:" strSym[str];
+ print $0 "\t" "XS:A:" strSym[str];
+ } else
+ {# mate is not defined - just print
+ print;
};
-
- printf "\n";
-
}
|
extmod/modlwip: Change #ifdef to #if for check of MICROPY_PY_LWIP.
Otherwise this code will be included if MICROPY_PY_LWIP is defined to 0. | @@ -1500,7 +1500,7 @@ STATIC mp_obj_t lwip_print_pcbs() {
}
MP_DEFINE_CONST_FUN_OBJ_0(lwip_print_pcbs_obj, lwip_print_pcbs);
-#ifdef MICROPY_PY_LWIP
+#if MICROPY_PY_LWIP
STATIC const mp_rom_map_elem_t mp_module_lwip_globals_table[] = {
{ MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_lwip) },
|
BugID:26368870:add include folder for mbmaster | @@ -27,7 +27,7 @@ else ifeq ($(COMPILER),armcc)
GLOBAL_DEFINES += __BSD_VISIBLE
endif
-GLOBAL_INCLUDES += include ./
+GLOBAL_INCLUDES += include ./ ../../../include/bus/modbus
GLOBAL_DEFINES += AOS_COMP_MBMASTER
AOS_COMP_MBMASTER := y
|
Valgrind test fixes (leaks due to unreaped threads.) | @@ -141,10 +141,14 @@ TestMain("Platform Operations", {
Convey("It ran", {
nni_usleep(50000); // for context switch
So(val == 1);
+ nni_thr_fini(&thr);
})
Convey("We can reap it", {
nni_thr_fini(&thr);
})
+ Reset({
+ nni_thr_fini(&thr);
+ })
})
})
Convey("Condition variables work", {
@@ -198,5 +202,9 @@ TestMain("Platform Operations", {
nni_mtx_unlock(&arg.mx);
nni_thr_fini(&thr);
})
+
+ Reset({
+ nni_thr_fini(&thr);
+ })
})
})
|
fix type float complex -> liquid_float_complex | @@ -4097,7 +4097,7 @@ int qpacketmodem_decode_soft(qpacketmodem _q,
unsigned char * _payload);
int qpacketmodem_decode_soft_sym(qpacketmodem _q,
- float complex _symbol);
+ liquid_float_complex _symbol);
int qpacketmodem_decode_soft_payload(qpacketmodem _q,
unsigned char * _payload);
|
add test to avoid searching arenas when possible | @@ -163,8 +163,8 @@ void* _mi_arena_alloc_aligned(size_t size, size_t alignment, bool* commit, bool*
// try to allocate in an arena if the alignment is small enough
// and the object is not too large or too small.
if (alignment <= MI_SEGMENT_ALIGN &&
- // size <= MI_ARENA_MAX_OBJ_SIZE &&
- size >= MI_ARENA_MIN_OBJ_SIZE)
+ size >= MI_ARENA_MIN_OBJ_SIZE &&
+ mi_atomic_load_relaxed(&mi_arena_count) > 0)
{
const size_t bcount = mi_block_count_of_size(size);
const int numa_node = _mi_os_numa_node(tld); // current numa node
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.