message
stringlengths 6
474
| diff
stringlengths 8
5.22k
|
---|---|
siconos jupyter image ... | FROM IMAGENAME
+USER root
+WORKDIR /home
+RUN cd /builds/nonsmooth/siconos/build; make install
USER $NB_USER
+ENV SICONOS_INSTALL_DIR=/home/install-siconos PATH=/home/install-siconos/bin/:$PATH
ENV JUPYTER_ENABLE_LAB yes
RUN git clone https://gricad-gitlab.univ-grenoble-alpes.fr/nonsmooth/siconos-tutorials.git
|
Initial work on LuxF4osd target. Flies :) | #define OmnibusF4SD
//#define OmnibusF4
//#define Alienwhoop_V2
+//#define LuxF4osd
// *************DEFINE FLIGHT CONTROLLER MOTOR OUTPUT - *****warning***** GETTING THIS WRONG CAN SMOKE YOUR BOARD :)
#define BRUSHLESS_TARGET
#define PWM_PB1
#endif
-#if defined(CC3D_REVO_F4) || defined(OmnibusF4SD) || defined(OmnibusF4)
+#if defined(CC3D_REVO_F4) || defined(OmnibusF4SD) || defined(OmnibusF4) || defined(LuxF4osd)
#define F405
#define SYS_CLOCK_FREQ_HZ 168000000
#define PWM_CLOCK_FREQ_HZ 84000000
//#define GYRO_ID_3 0x78
//#define GYRO_ID_4 0x72
//#define SENSOR_ROTATE_90_CCW
+#if defined(LuxF4osd)
+#define SENSOR_ROTATE_90_CCW
+#else
#define SENSOR_FLIP_180
+#endif
+
//#define DISABLE_GYRO_CHECK
#define USART_INVERTER_PORT GPIOC
#define USART1_PA10PA9
#endif
-#if defined(CC3D_REVO_F4) || defined(OmnibusF4)
+#if defined(CC3D_REVO_F4) || defined(OmnibusF4) || defined(LuxF4osd)
#define USART1_PA10PA9
#define USART_INVERTER_PIN GPIO_Pin_0
#define USART_INVERTER_PORT GPIOC
#endif
// MOTOR PINS
-#define MOTOR0_PIN_PB0
-#define MOTOR1_PIN_PB1
-#define MOTOR2_PIN_PA2
-#define MOTOR3_PIN_PA3
+#define MOTOR0_PIN_PA3
+#define MOTOR1_PIN_PA2
+#define MOTOR2_PIN_PB0
+#define MOTOR3_PIN_PB1
//pyroflip
//#define MOTOR0_PIN_PA8
|
Add HDC & hInstance to windows SysWMinfo struct
SDL
includes HWND, HDC, and HINSTANCE in the windows-related SysWMinfo
structure. These are useful values if you have occasion to open up the
guts and do something inadvisable & it would be nice if htey were
available | @@ -70,6 +70,8 @@ type SysWMInfo struct {
// WindowsInfo contains Microsoft Windows window information.
type WindowsInfo struct {
Window unsafe.Pointer // the window handle
+ DeviceContext unsafe.Pointer // the device context handle
+ Instance unsafe.Pointer // the instance handle
}
// X11Info contains X Window System window information.
|
Add AtkComponentCheckBox.Checked | @@ -14,5 +14,7 @@ namespace FFXIVClientStructs.FFXIV.Component.GUI
public unsafe struct AtkComponentCheckBox
{
[FieldOffset(0x0)] public AtkComponentButton AtkComponentButton;
+
+ public bool Checked => (AtkComponentButton.Flags & (1 << 18)) != 0;
}
}
|
pujjo: Support battery amber LED control by ectool
Support battery amber LED control by ectool.
TEST=zmake build pujjo
BRANCH=none | color-map-amber = <100 60>;
/* brightness-range = <red green blue yellow white amber> */
- brightness-range = <100 100 0 0 0 0>;
+ brightness-range = <100 100 0 0 0 100>;
#address-cells = <1>;
#size-cells = <0>;
|
util/cbi-util.c: Format with clang-format
BRANCH=none
TEST=none | @@ -64,24 +64,15 @@ static const struct option opts_create[] = {
{ NULL, 0, 0, 0 }
};
-static const struct option opts_show[] = {
- {"file", 1, 0, OPT_FILENAME},
+static const struct option opts_show[] = { { "file", 1, 0, OPT_FILENAME },
{ "all", 0, 0, OPT_SHOW_ALL },
- {NULL, 0, 0, 0}
-};
+ { NULL, 0, 0, 0 } };
static const char *field_name[] = {
/* Same order as enum cbi_data_tag */
- "BOARD_VERSION",
- "OEM_ID",
- "SKU_ID",
- "DRAM_PART_NUM",
- "OEM_NAME",
- "MODEL_ID",
- "FW_CONFIG",
- "PCB_SUPPLIER",
- "SSFC",
- "REWORK_ID",
+ "BOARD_VERSION", "OEM_ID", "SKU_ID", "DRAM_PART_NUM",
+ "OEM_NAME", "MODEL_ID", "FW_CONFIG", "PCB_SUPPLIER",
+ "SSFC", "REWORK_ID",
};
BUILD_ASSERT(ARRAY_SIZE(field_name) == CBI_TAG_COUNT);
@@ -148,7 +139,8 @@ static void print_help(void)
{
printf("\nUsage: %s <create|show> [ARGS]\n"
"\n"
- "Utility for CBI:Cros Board Info images.\n", cmd_name);
+ "Utility for CBI:Cros Board Info images.\n",
+ cmd_name);
print_help_create();
print_help_show();
}
@@ -489,8 +481,8 @@ static void print_integer(const uint8_t *buf, enum cbi_data_tag tag)
v = *(uint64_t *)d->value;
break;
default:
- printf(" %s: Integer of size %d not supported\n",
- name, d->size);
+ printf(" %s: Integer of size %d not supported\n", name,
+ d->size);
return;
}
printf(" %s: %llu (0x%llx, %u, %u)\n", name, (unsigned long long)v,
|
Remove references for obsolete error code | @@ -99,7 +99,6 @@ psa_status_t psa_its_set(psa_storage_uid_t uid,
*
* \retval #PSA_SUCCESS The operation completed successfully
* \retval #PSA_ERROR_DOES_NOT_EXIST The operation failed because the provided `uid` value was not found in the storage
- * \retval #PSA_ERROR_INVALID_SIZE The operation failed because the data associated with provided uid is larger than `data_size`
* \retval #PSA_ERROR_STORAGE_FAILURE The operation failed because the physical storage has failed (Fatal error)
* \retval #PSA_ERROR_INVALID_ARGUMENT The operation failed because one of the provided pointers(`p_data`, `p_data_length`)
* is invalid. For example is `NULL` or references memory the caller cannot access.
|
sys/metrics: Use "body" log API
i.e., use `log_append_mbuf_body()` rather than
`log_append_mbuf_typed()`. This removes the need to allocate space in
the mbuf for a log entry header. | @@ -124,9 +124,8 @@ metrics_event_end(struct metrics_event_hdr *hdr)
if (hdr->log) {
om = metrics_get_mbuf();
if (om) {
- os_mbuf_extend(om, sizeof(struct log_entry_hdr));
if (!metrics_event_to_cbor(hdr, om)) {
- log_append_mbuf_typed(hdr->log, hdr->log_module, hdr->log_level,
+ log_append_mbuf_body(hdr->log, hdr->log_module, hdr->log_level,
LOG_ETYPE_CBOR, om);
} else {
ret = -1;
|
Quest input fixes; | @@ -321,11 +321,11 @@ static bool vrapi_getAxis(Device device, DeviceAxis axis, float* value) {
} else if (state.deviceType == VRAPI_DEVICE_TYPE_OCULUSQUEST) {
switch (axis) {
case AXIS_THUMBSTICK:
- value[0] = input->TrackpadPosition.x;
- value[1] = input->TrackpadPosition.y;
- break;
- case AXIS_TRIGGER: value[0] = input->IndexTrigger; break;
- case AXIS_GRIP: value[0] = input->GripTrigger; break;
+ value[0] = input->Joystick.x;
+ value[1] = input->Joystick.y;
+ return true;
+ case AXIS_TRIGGER: value[0] = input->IndexTrigger; return true;
+ case AXIS_GRIP: value[0] = input->GripTrigger; return true;
default: return false;
}
}
@@ -441,18 +441,18 @@ static void vrapi_update(float dt) {
ovrInputTrackedRemoteCapabilities info;
info.Header = header;
vrapi_GetInputDeviceCapabilities(state.session, &info.Header);
- Device device = (info.ControllerCapabilities & ovrControllerCaps_LeftHand) ? DEVICE_HAND_LEFT : DEVICE_HAND_RIGHT;
- state.controllerInfo[device] = info;
- state.input[device].Header.ControllerType = header.Type;
- vrapi_GetCurrentInputState(state.session, header.DeviceID, &state.input[device].Header);
+ uint32_t index = (info.ControllerCapabilities & ovrControllerCaps_LeftHand) ? 0 : 1;
+ state.controllerInfo[index] = info;
+ state.input[index].Header.ControllerType = header.Type;
+ vrapi_GetCurrentInputState(state.session, header.DeviceID, &state.input[index].Header);
} else if (header.Type == ovrControllerType_Hand) {
ovrInputHandCapabilities info;
info.Header = header;
vrapi_GetInputDeviceCapabilities(state.session, &info.Header);
- Device device = (info.HandCapabilities & ovrHandCaps_LeftHand) ? DEVICE_HAND_LEFT : DEVICE_HAND_RIGHT;
- state.controllerInfo[device].Header.Type = header.Type;
- state.handInput[device].Header.ControllerType = header.Type;
- vrapi_GetCurrentInputState(state.session, header.DeviceID, &state.handInput[device].Header);
+ uint32_t index = (info.HandCapabilities & ovrHandCaps_LeftHand) ? 0 : 1;
+ state.controllerInfo[index].Header.Type = header.Type;
+ state.handInput[index].Header.ControllerType = header.Type;
+ vrapi_GetCurrentInputState(state.session, header.DeviceID, &state.handInput[index].Header);
}
}
}
|
router_readconfig: check if malloc succeed | @@ -1188,6 +1188,11 @@ router_readconfig(router *orig,
return NULL;
}
cl->name = ra_strdup(ret->a, "blackhole");
+ if (cl->name == NULL) {
+ logerr("malloc failed for blackhole cluster name\n");
+ router_free(ret);
+ return NULL;
+ }
cl->type = BLACKHOLE;
cl->members.forward = NULL;
cl->next = NULL;
|
CoreValidation: Fixed MMU setup to be compatible with Cortex-A7. | @@ -283,7 +283,7 @@ void MMU_CreateTranslationTable(void)
// Create (256 * 4k)=1MB faulting entries to cover private address space. Needs to be marked as Device memory
MMU_TTPage4k (&Image$$TTB$$ZI$$Base, __get_CBAR() ,256, Page_L1_4k, (uint32_t *)PRIVATE_TABLE_L2_BASE_4k, DESCRIPTOR_FAULT);
// Define private address space entry.
- MMU_TTPage4k (&Image$$TTB$$ZI$$Base, __get_CBAR() , 2, Page_L1_4k, (uint32_t *)PRIVATE_TABLE_L2_BASE_4k, Page_4k_Device_RW);
+ MMU_TTPage4k (&Image$$TTB$$ZI$$Base, __get_CBAR() , 3, Page_L1_4k, (uint32_t *)PRIVATE_TABLE_L2_BASE_4k, Page_4k_Device_RW);
// Define L2CC entry. Uncomment if PL310 is present
// MMU_TTPage4k (&Image$$TTB$$ZI$$Base, VE_A9_MP_PL310_BASE , 1, Page_L1_4k, (uint32_t *)PRIVATE_TABLE_L2_BASE_4k, Page_4k_Device_RW);
|
Fix log message for unhandled event in OTA agent | @@ -2386,7 +2386,8 @@ static void prvOTAAgentTask( void * pUnused )
OTA_EventMsg_t xEventMsg = { 0 };
OTA_Err_t xErr = kOTA_Err_Uninitialized;
- uint32_t i;
+ uint32_t ulTransitionTableLen = sizeof( OTATransitionTable ) / sizeof( OTATransitionTable[ 0 ] );
+ uint32_t i = 0;
/*
* OTA Agent is ready to receive and process events so update the state to ready.
@@ -2400,7 +2401,7 @@ static void prvOTAAgentTask( void * pUnused )
*/
if( xQueueReceive( xOTA_Agent.xOTA_EventQueue, &xEventMsg, portMAX_DELAY ) == pdTRUE )
{
- for( i = 0; i < ( sizeof( OTATransitionTable ) / sizeof( OTATransitionTable[ 0 ] ) ); i++ )
+ for( i = 0; i < ulTransitionTableLen; i++ )
{
if( OTATransitionTable[ i ].xCurrentState == xOTA_Agent.eState )
{
@@ -2442,6 +2443,8 @@ static void prvOTAAgentTask( void * pUnused )
}
}
+ if( i == ulTransitionTableLen )
+ {
OTA_LOG_L1( "[%s] Unexpected Event. Current State [%s] Event [%s] \n",
OTA_METHOD_NAME,
pcOTA_AgentState_Strings[ xOTA_Agent.eState ],
@@ -2449,6 +2452,7 @@ static void prvOTAAgentTask( void * pUnused )
}
}
}
+}
BaseType_t OTA_SignalEvent( const OTA_EventMsg_t * const pxEventMsg )
{
|
bluetooth: fix indentation warning | @@ -101,9 +101,9 @@ bool list_insert_after(list_t *list, list_node_t *prev_node, void *data) {
assert(prev_node != NULL);
assert(data != NULL);
list_node_t *node = (list_node_t *)osi_calloc(sizeof(list_node_t));
- if (!node)
+ if (!node) {
return false;
-
+ }
node->next = prev_node->next;
node->data = data;
prev_node->next = node;
|
resolver/filename: fix typo and add missing header | #include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
+#include <string.h>
#include <sys/time.h>
#include <sys/types.h>
#include <unistd.h>
@@ -84,7 +85,7 @@ static void elektraGenTempFilename (ElektraResolved * handle, ElektraResolveTemp
struct timeval tv;
memset (&tv, 0, sizeof (struct timeval));
- settimeofday (&tv, 0);
+ gettimeofday (&tv, 0);
snprintf (tmpFile + len, POSTFIX_SIZE - 1, ".%d:%ld." ELEKTRA_TIME_USEC_F ".tmp", getpid (), tv.tv_sec, tv.tv_usec);
handle->tmpFile = tmpFile;
}
|
Namespace all VS build outputs by platform | <PropertyGroup Label="UserMacros" />
<PropertyGroup>
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
- <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Configuration)\</IntDir>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
+ <IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Platform)\$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</LinkIncremental>
- <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
- <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Configuration)\</IntDir>
+ <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
+ <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Platform)\$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</LinkIncremental>
</PropertyGroup>
|
remove redundant -x hip | @@ -63,7 +63,7 @@ endif
CC =$(AOMP)/bin/clang++
#CFLAGS =-O3 --target=x86_64-pc-linux-gnu -fopenmp -fopenmp-targets=amdgcn-amd-amdhsa -Xopenmp-target amdgcn-amd-amdhsa #--offload-arch=$(AOMP_GPU)
#CFLAGS =-x hip -O3 -target x86_64-pc-linux-gnu -fopenmp -fopenmp-targets=amdgcn-amd-amdhsa -Xopenmp-target=amdgcn-amd-amdhsa -march=gfx900
-CFLAGS =-x hip -O3 -target x86_64-pc-linux-gnu -fopenmp
+CFLAGS =-O3 -target x86_64-pc-linux-gnu -fopenmp
#CFLAGS =-O3 -fopenmp -target x86_64-pc-linux-gnu
# Add cudart only if we have an Nvidia sm_ target
|
Work around excessive LAPACK test failures on Skylake-X
Something in the plain C parts of x86_64 cscal.c and zscal.c appears to be miscompiled by both gfortran9 and ifort when compiling for skylakex-avx512, even when the optimized Haswell microkernel is not in use. | @@ -24,3 +24,6 @@ DGEMM_BETA = dgemm_beta_skylakex.c
CGEMMKERNEL = cgemm_kernel_8x2_skylakex.c
ZGEMMKERNEL = zgemm_kernel_4x2_skylakex.c
+
+CSCALKERNEL = ../arm/zscal.c
+ZSCALKERNEL = ../arm/zscal.c
|
update c3 bootloader ld addr info | @@ -176,17 +176,17 @@ SECTIONS
/**
* Appendix: Memory Usage of ROM bootloader
*
- * +--------+--------------+------+ 0x3FCC_B000
+ * +--------+--------------+------+ 0x3FCC_AE00
* | ^ |
* | | |
* | | data/bss |
* | | |
* | v |
- * +------------------------------+ 0x3FCD_C910
+ * +------------------------------+ 0x3FCD_C710
* | ^ |
* | | |
* | | stack |
* | | |
* | v |
- * +------------------------------+ 0x3FCD_E910
+ * +------------------------------+ 0x3FCD_E710
*/
|
Add recursive to git clone command. | @@ -55,22 +55,22 @@ function bv_visit_ensure_built_or_ready
info "GIT clone of visit ($GIT_ROOT_PATH) . . ."
if [[ "$DO_REVISION" == "yes" && "$GITREVISION" != "" ]] ; then
# Get the specified revision.
- git clone $GIT_ROOT_PATH
+ git clone --recursive $GIT_ROOT_PATH
cd visit
git checkout $GITREVISION
cd ..
elif [[ "$TRUNK_BUILD" == "yes" ]] ; then
# Get the trunk version
- git clone $GIT_ROOT_PATH
+ git clone --recursive $GIT_ROOT_PATH
elif [[ "$RC_BUILD" == "yes" ]] ; then
# Get the RC version
- git clone $GIT_ROOT_PATH
+ git clone --recursive $GIT_ROOT_PATH
cd visit
git checkout ${VISIT_VERSION:0:3}RC
cd ..
elif [[ "$TAGGED_BUILD" == "yes" ]] ; then
# Get the tagged version
- git clone $GIT_ROOT_PATH
+ git clone --recursive $GIT_ROOT_PATH
cd visit
git checkout v${VISIT_VERSION}
cd ..
|
h2o-probes: Fix typo | @@ -68,7 +68,7 @@ provider h2o {
probe h3s_stream_set_state(uint64_t conn_id, uint64_t req_id, unsigned state);
/**
- * HTTP/3 event, indicating that a H3 frame has been received. `base` is available available except when frame_type is DATA.
+ * HTTP/3 event, indicating that a H3 frame has been received. `base` is available except when frame_type is DATA.
*/
probe h3_frame_receive(uint64_t frame_type, const void *base, size_t len);
/**
|
[io] add a trick to take into account the fact that EqualityConditionNSL is implicitely added if there are joints in the scene | @@ -1917,7 +1917,7 @@ class MechanicsHdf5Runner(siconos.io.mechanics_hdf5.MechanicsHdf5):
self._contact_index_set = contact_index_set
# (1) OneStepIntegrators
- joints=list(self.joints())
+
self._osi=osi(theta)
@@ -1929,8 +1929,23 @@ class MechanicsHdf5Runner(siconos.io.mechanics_hdf5.MechanicsHdf5):
nslaw_type_list =[]
for name in self._nslaws_data:
nslaw_type_list.append(self._nslaws_data[name].attrs['type'])
- nb_of_nslaw_type = len(set(nslaw_type_list))
+ #print(set(nslaw_type_list))
+
+ # This trick is used to add the EqualityConditionNSL to the list of nslaw type
+ # this must be improved by adding the EqualityConditionNSL in self._nslaws_data
+ # when a joint is imported.
+ # For the moment, the nslaw is implicitely added when we import_joint but is not stored
+ # self._nslaws_data
+
+ joints=list(self.joints())
+ if len(joints) > 0:
+ nslaw_type_list.append('EqualityConditionNSL')
+
+
+ nb_of_nslaw_type = len(set(nslaw_type_list))
+ # print(set(nslaw_type_list))
+ # input()
if (friction_contact_trace == False) :
if (osi == Kernel.MoreauJeanGOSI):
if (nb_of_nslaw_type >1) or 'NewtonImpactFrictionNSL' not in set(nslaw_type_list):
@@ -1999,6 +2014,7 @@ class MechanicsHdf5Runner(siconos.io.mechanics_hdf5.MechanicsHdf5):
osnspb.setNumericsVerboseMode(numerics_verbose)
+ #Numerics.numerics_set_verbose(3)
# keep previous solution
osnspb.setKeepLambdaAndYState(True)
@@ -2031,7 +2047,7 @@ class MechanicsHdf5Runner(siconos.io.mechanics_hdf5.MechanicsHdf5):
self._simulation = simulation
-
+ # input()
if len(self._plugins) > 0:
print_verbose ('import plugins ...')
@@ -2039,10 +2055,6 @@ class MechanicsHdf5Runner(siconos.io.mechanics_hdf5.MechanicsHdf5):
-
- #input()
-
-
if len(self._external_functions) > 0:
print_verbose ('import external functions ...')
self.import_external_functions()
|
runner: init tmp handler
connection and ctx will be garbage. Make sure connection is
null so tcmulib_reg_name_appeared's check fails if
tcmulib_reg_name_acquired has not yet been called. | @@ -1046,6 +1046,7 @@ int main(int argc, char **argv)
darray_foreach(tmp_r_handler, g_runner_handlers) {
struct tcmulib_handler tmp_handler;
+ memset(&tmp_handler, 0, sizeof(tmp_handler));
tmp_handler.name = (*tmp_r_handler)->name;
tmp_handler.subtype = (*tmp_r_handler)->subtype;
tmp_handler.cfg_desc = (*tmp_r_handler)->cfg_desc;
|
Feat:Modify macro comment | @@ -342,4 +342,4 @@ BOAT_RESULT FibocomHttpPortRequestSync(FibocomHttpPortContext *fibocomhttpport_c
}
-#endif // end of #if RPC_USE_MBEDHTTPPORT == 1
+#endif // end of #if RPC_USE_FIBOCOMHTTPPORT == 1
|
doc: update debian ISO image version number
Documentation mentions a specific Debian 10 ISO image version that no
longer exists. Update to indiate we validated with debian_10.1.0 but
newer versions should also work. | @@ -21,6 +21,11 @@ Use the following instructions to install Debian.
<https://cdimage.debian.org/debian-cd/current/amd64/iso-cd/>`_.
Select and download **debian-10.1.0-amd64-netinst.iso** (scroll down to
the bottom of the page).
+
+ .. note:: These instructions were validated with the
+ debian_10.1.0 ISO image. A newer Debian 10 version
+ should still work as expected.
+
- Follow the `Debian installation guide
<https://www.debian.org/releases/stable/amd64/index.en.html>`_ to
install it on your board; we are using a Kaby Lake Intel NUC (NUC7i7DNHE)
|
Add uint_(least|fast)*_t types
This commit adds typedefs for signed and unsigned variants of the
_fast and _least integer types.
BRANCH=None
TEST=make buildall -J
Commit-Ready: Jeff Andersen
Tested-by: Jeff Andersen | @@ -18,10 +18,31 @@ typedef signed int int32_t;
typedef unsigned long long uint64_t;
typedef signed long long int64_t;
-typedef int intptr_t;
typedef unsigned int uintptr_t;
+typedef int intptr_t;
+/* uint_leastX_t represents the smallest type available with at least X bits.
+ * uint_fastX_t represents the fastest type available with at least X bits.
+ */
typedef uint8_t uint_least8_t;
+typedef uint16_t uint_least16_t;
+typedef uint32_t uint_least32_t;
+typedef uint64_t uint_least64_t;
+
+typedef int8_t int_least8_t;
+typedef int16_t int_least16_t;
+typedef int32_t int_least32_t;
+typedef int64_t int_least64_t;
+
+typedef uint8_t uint_fast8_t;
+typedef uint16_t uint_fast16_t;
+typedef uint32_t uint_fast32_t;
+typedef uint64_t uint_fast64_t;
+
+typedef int8_t int_fast8_t;
+typedef int16_t int_fast16_t;
+typedef int32_t int_fast32_t;
+typedef int64_t int_fast64_t;
#ifndef UINT8_MAX
#define UINT8_MAX (255U)
|
regexdispatcher: add usedby to check/validation metadata | @@ -559,7 +559,7 @@ description= defines which file (path) the value refers to
[check/validation]
status= implemented
-usedby/plugin= validation
+usedby/plugin= validation regexdispatcher
usedby/tool = web
type= regular expression
description= a regular expression to check against
|
Only use one parameter wifi name and password for client and ap mode | @@ -2340,15 +2340,8 @@ int DeRestPluginPrivate::configureWifi(const ApiRequest &req, ApiResponse &rsp)
return REQ_READY_SEND;
}
- if (gwWifiType == "accesspoint")
- {
gwWifiName = name;
}
- else
- {
- gwWifiClientName = name;
- }
- }
if (map.contains("password"))
{
QString password = map["password"].toString();
@@ -2360,14 +2353,8 @@ int DeRestPluginPrivate::configureWifi(const ApiRequest &req, ApiResponse &rsp)
return REQ_READY_SEND;
}
- if (gwWifiType == "accesspoint")
- {
gwWifiPw = password;
- }
- else
- {
- gwWifiClientPw = password;
- }
+
}
if (map.contains("wifi"))
{
|
Minor style tidying around parser's keyword_for. | @@ -4190,16 +4190,13 @@ static void keyword_for(lily_parse_state *parser)
lily_var *loop_var = find_active_var(parser, lex->label);
- if (loop_var == NULL) {
- lily_class *cls = parser->symtab->integer_class;
- loop_var = new_typed_local_var(parser, cls->self_type, lex->label,
+ if (loop_var == NULL)
+ loop_var = new_typed_local_var(parser, integer_type, lex->label,
lex->line_num);
- }
- else if (loop_var->type->cls->id != LILY_ID_INTEGER) {
+ else if (loop_var->type != integer_type)
lily_raise_syn(parser->raiser,
"Loop var must be type Integer, not type '^T'.",
loop_var->type);
- }
lily_var *for_start = new_typed_local_var(parser, integer_type, "", 0);
lily_var *for_end = new_typed_local_var(parser, integer_type, "", 0);
|
BugID:17023347: fix [WhiteScan][424816][OVERRUN] | @@ -355,7 +355,7 @@ int do_auth (CoAPContext *ctx, NetworkAddr* addr, ctl_key_item* ctl_item, void *
char sign[64]={0};
int sign_len = sizeof(sign);
- utils_hmac_sha1_base64(session->randomKey, strlen(session->randomKey), ctl_item->accessToken,
+ utils_hmac_sha1_base64(session->randomKey, RANDOMKEY_LEN, ctl_item->accessToken,
strlen(ctl_item->accessToken), sign, &sign_len);
COAP_INFO ("calc randomKey:%s,token:%s,sign:%.*s", session->randomKey, ctl_item->accessToken, sign_len, sign);
|
Run RPS service tests in separate JVMs
(this closes | </execution>
</executions>
</plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <version>2.19.1</version>
+ <configuration>
+ <!-- run test classes in separate JVMs, as RangerHawqAuthorizerServiceNameTest requires it -->
+ <reuseForks>false</reuseForks>
+ </configuration>
+ </plugin>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<version>3.0.0</version>
|
compilefix for linux | @@ -869,11 +869,15 @@ static void io_connected(neat_ctx *ctx, neat_flow *flow,
unsigned int statuslen;
int rc;
struct sctp_status status;
+#endif // defined(IPPROTO_SCTP) && defined(SCTP_STATUS) && !defined(USRSCTP_SUPPORT)
+#if defined(IPPROTO_SCTP) && defined(SCTP_INTERLEAVING_SUPPORTED) && !defined(USRSCTP_SUPPORT)
int value;
unsigned int valuelen;
-#endif // defined(IPPROTO_SCTP) && defined(SCTP_STATUS) && !defined(USRSCTP_SUPPORT)
+#endif // #if defined(IPPROTO_SCTP) && defined(SCTP_INTERLEAVING_SUPPORTED) && !defined(USRSCTP_SUPPORT)
char proto[16];
+
+
switch (flow->socket->stack) {
case NEAT_STACK_UDP:
snprintf(proto, 16, "UDP");
@@ -895,7 +899,9 @@ static void io_connected(neat_ctx *ctx, neat_flow *flow,
}
// number of outbound streams == number of inbound streams
neat_log(ctx, NEAT_LOG_INFO, "%s - SCTP - number of streams: %d", __func__, flow->socket->sctp_streams_available);
+#endif // defined(IPPROTO_SCTP) && defined(SCTP_STATUS) && !defined(USRSCTP_SUPPORT)
+#if defined(IPPROTO_SCTP) && defined(SCTP_INTERLEAVING_SUPPORTED) && !defined(USRSCTP_SUPPORT)
valuelen = sizeof(value);
rc = getsockopt(flow->socket->fd, IPPROTO_SCTP, SCTP_INTERLEAVING_SUPPORTED, &value, &valuelen);
if (rc < 0) {
@@ -903,9 +909,7 @@ static void io_connected(neat_ctx *ctx, neat_flow *flow,
} else {
neat_log(ctx, NEAT_LOG_WARNING, "I-DATA support: %d", value == 2 ? "enable" : "disabled");
}
- // number of outbound streams == number of inbound streams
- neat_log(ctx, NEAT_LOG_INFO, "%s - SCTP - number of streams: %d", __func__, flow->socket->sctp_streams_available);
-#endif // defined(IPPROTO_SCTP) && defined(SCTP_STATUS) && !defined(USRSCTP_SUPPORT)
+#endif // defined(IPPROTO_SCTP) && defined(SCTP_INTERLEAVING_SUPPORTED) && !defined(USRSCTP_SUPPORT)
break;
case NEAT_STACK_UDPLITE:
snprintf(proto, 16, "UDPLite");
|
review: newSource() gets options table | @@ -50,7 +50,16 @@ static int l_lovrAudioSetVolume(lua_State* L) {
static int l_lovrAudioNewSource(lua_State* L) {
Source* source = NULL;
SoundData* soundData = luax_totype(L, 1, SoundData);
- bool spatial = lua_isboolean(L, 2) ? lua_toboolean(L, 2) : true;
+
+ bool spatial = true;
+ if (lua_istable(L, 2)) {
+ lua_getfield(L, 2, "spatial");
+ if (lua_isboolean(L, -1)) {
+ spatial = lua_toboolean(L, -1);
+ }
+ lua_pop(L, 1);
+ }
+
if (soundData) {
source = lovrSourceCreate(soundData, spatial);
|
DBL_EPSILON is used | #include <sys/socket.h>
#include <sys/ioctl.h>
#include <stdatomic.h>
+#include <float.h>
#if defined(_WIN32) || defined(_WIN64)
#else
#include <netinet/in.h>
@@ -1350,7 +1351,7 @@ int pay_miners(xdag_time_t time)
double *prev_diff = diff + miners_count;
double prev_sum = precalculate_payments(hash, confirmation_index, &data, diff, prev_diff, nonce);
- if(prev_sum == 0) {
+ if(prev_sum <= DBL_EPSILON) {
free(diff);
return -9;
}
|
openwsman: ifdef weak pragma while compiling with MSVC
MSVC have no notion about "pragma weak".
Ifdef such pragmas to eliminate warnings like:
warning C4068: unknown pragma | @@ -1007,9 +1007,13 @@ unsigned long get_total_enum_context(WsContextH cntx){
* preset, hence marking them as weak symbols and testing to see
* if they are resolved before using them.
*/
+#ifndef _MSC_VER /* no such pragma in MSVC */
#pragma weak wsmand_options_get_max_threads
+#endif /* _MSC_VER */
extern int wsmand_options_get_max_threads(void);
+#ifndef _MSC_VER /* no such pragma in MSVC */
#pragma weak wsmand_options_get_max_connections_per_thread
+#endif /* _MSC_VER */
extern int wsmand_options_get_max_connections_per_thread(void);
/**
|
Add error handling in inject
check return status for `PTRACE_SETREGS`/`PTRACE_GETREGS` | @@ -175,7 +175,10 @@ inject(pid_t pid, uint64_t dlopenAddr, char *path, int glibc)
}
// save registers
- ptrace(PTRACE_GETREGS, pid, NULL, &oldregs);
+ if (ptrace(PTRACE_GETREGS, pid, NULL, &oldregs) == -1) {
+ fprintf(stderr, "error: ptrace get register(), library could not be injected\n");
+ return EXIT_FAILURE;
+ }
memcpy(®s, &oldregs, sizeof(struct user_regs_struct));
// find free space in text section
@@ -214,7 +217,10 @@ inject(pid_t pid, uint64_t dlopenAddr, char *path, int glibc)
regs.rsi = RTLD_NOW;
}
#endif
- ptrace(PTRACE_SETREGS, pid, NULL, ®s);
+ if (ptrace(PTRACE_SETREGS, pid, NULL, ®s) == -1) {
+ fprintf(stderr, "error: ptrace set register(), library could not be injected\n");
+ return EXIT_FAILURE;
+ }
// continue execution and wait until the target process is stopped
ptrace(PTRACE_CONT, pid, NULL, NULL);
@@ -230,7 +236,10 @@ inject(pid_t pid, uint64_t dlopenAddr, char *path, int glibc)
if (WIFSTOPPED(status) && WSTOPSIG(status) == SIGTRAP) {
// check if the library has been successfully injected
- ptrace(PTRACE_GETREGS, pid, NULL, ®s);
+ if (ptrace(PTRACE_GETREGS, pid, NULL, ®s) == -1) {
+ fprintf(stderr, "error: ptrace get register(), library could not be injected\n");
+ return EXIT_FAILURE;
+ }
#ifdef __x86_64__
if (regs.rax != 0x0) {
//printf("Appscope library injected at %p\n", (void*)regs.rax);
@@ -240,7 +249,10 @@ inject(pid_t pid, uint64_t dlopenAddr, char *path, int glibc)
#endif
//restore the app's state
ptraceWrite(pid, freeAddr, oldcode, INJECTED_CODE_SIZE_LEN);
- ptrace(PTRACE_SETREGS, pid, NULL, &oldregs);
+ if (ptrace(PTRACE_SETREGS, pid, NULL, &oldregs) == -1) {
+ fprintf(stderr, "error: ptrace set register(), library could not be injected\n");
+ return EXIT_FAILURE;
+ }
ptrace(PTRACE_DETACH, pid, NULL, NULL);
} else {
|
svs: use explicit types in api
Type: fix | option version = "1.0.0";
import "vnet/ip/ip_types.api";
+import "vnet/interface_types.api";
/**
* brief Get the plugin version
@@ -60,7 +61,7 @@ autoreply define svs_table_add_del
{
u32 client_index;
u32 context;
- u8 is_add;
+ bool is_add;
vl_api_address_family_t af;
u32 table_id;
};
@@ -79,7 +80,7 @@ autoreply define svs_route_add_del
{
u32 client_index;
u32 context;
- u8 is_add;
+ bool is_add;
vl_api_prefix_t prefix;
u32 table_id;
u32 source_table_id;
@@ -98,10 +99,10 @@ autoreply define svs_enable_disable
{
u32 client_index;
u32 context;
- u8 is_enable;
+ bool is_enable;
vl_api_address_family_t af;
u32 table_id;
- u32 sw_if_index;
+ vl_api_interface_index_t sw_if_index;
};
/**
@@ -125,7 +126,6 @@ define svs_details
{
u32 context;
u32 table_id;
- u32 sw_if_index;
+ vl_api_interface_index_t sw_if_index;
vl_api_address_family_t af;
};
-
|
tcpci: remove extra write when sending HARD_RST
Per the TCPCI spec, we don't need to try to write the header or
byte count when sending a non SOP* packet.
BRANCH=none
TEST=PS8751 can still send a hard reset | @@ -559,6 +559,16 @@ int tcpci_tcpm_transmit(int port, enum tcpm_transmit_type type,
int reg = TCPC_REG_TX_DATA;
int rv, cnt = 4*PD_HEADER_CNT(header);
+ /* If not SOP* transmission, just write to the transmit register */
+ if (type >= NUM_SOP_STAR_TYPES) {
+ /*
+ * Per TCPCI spec, do not specify retry (although the TCPC
+ * should ignore retry field for these 3 types).
+ */
+ return tcpc_write(port, TCPC_REG_TRANSMIT,
+ TCPC_REG_TRANSMIT_SET_WITHOUT_RETRY(type));
+ }
+
/* TX_BYTE_CNT includes extra bytes for message header */
rv = tcpc_write(port, TCPC_REG_TX_BYTE_CNT, cnt + sizeof(header));
|
filter: for match rule | @@ -190,6 +190,16 @@ void flb_filter_initialize_all(struct flb_config *config)
/* Iterate all active filter instance plugins */
mk_list_foreach_safe(head, tmp, &config->filters) {
in = mk_list_entry(head, struct flb_filter_instance, _head);
+
+ if (!in->match) {
+ flb_warn("[filter] NO match rule for %s filter instance, unloading.",
+ in->name);
+ mk_list_del(&in->_head);
+ flb_free(in);
+ continue;
+ }
+
+
p = in->p;
/* Initialize the input */
|
Removed cruft from Makefile | @@ -2,7 +2,7 @@ all : lib data_recorder test calibrate calibrate_client simple_pose_test
CC?=gcc
-CFLAGS:=-Iinclude/libsurvive -fPIC -g -O0 -Iredist -flto -DUSE_DOUBLE -std=gnu99 -rdynamic -fsanitize=address -fsanitize=undefined -llapacke -lcblas -lm
+CFLAGS:=-Iinclude/libsurvive -fPIC -g -O0 -Iredist -flto -DUSE_DOUBLE -std=gnu99 -rdynamic -llapacke -lcblas -lm
#LDFLAGS:=-L/usr/local/lib -lpthread -lusb-1.0 -lz -lm -flto -g
LDFLAGS:=-L/usr/local/lib -lpthread -lz -lm -flto -g
@@ -92,14 +92,6 @@ test_epnp: ./src/epnp/test_epnp.c ./lib/libsurvive.so
test_epnp_ocv: ./src/epnp/test_epnp.c ./src/epnp/epnp.c
$(CC) -o $@ $^ -DWITH_OPENCV -lpthread -lz -lm -flto -g -lX11 -lusb-1.0 -Iinclude/libsurvive -fPIC -g -O4 -Iredist -flto -DUSE_DOUBLE -std=gnu99 -rdynamic -fsanitize=address -fsanitize=undefined -llapack -lm -lopencv_core
-
-unit_test_epnp: ./src/epnp/unit_test_epnp.c ./lib/libsurvive.so
- $(CC) -o $@ $^ $(LDFLAGS) $(CFLAGS)
-
-test_epnp_results: test_epnp test_epnp_ocv
- -./test_epnp_ocv > opencv_output
- -./test_epnp > our_output
-
lib:
mkdir lib
@@ -111,7 +103,7 @@ calibrate_tcc : $(LIBSURVIVE_C)
tcc -DRUNTIME_SYMNUM $(CFLAGS) -o $@ $^ $(LDFLAGS) calibrate.c redist/os_generic.c $(DRAWFUNCTIONS) redist/symbol_enumerator.c
clean :
- rm -rf *.o src/*.o *~ src/*~ test simple_pose_test data_recorder calibrate testCocoa lib/libsurvive.so redist/*.o redist/*~
+ rm -rf *.o src/*.o *~ src/*~ test simple_pose_test data_recorder calibrate testCocoa lib/libsurvive.so test_minimal_cv test_epnp test_epnp_ocv calibrate_client redist/*.o redist/*~
|
avoid temp path into global path var | @@ -7,5 +7,5 @@ Invoke-Webrequest "https://github.com/tboox/xmake/releases/download/$ver/xmake-$
Start-Process -FilePath "$pid-xmake-installer.exe" -ArgumentList '/S /D=C:\xmake' -Wait
Remove-Item "$pid-xmake-installer.exe"
$env:Path+=";C:\xmake"
-[Environment]::SetEnvironmentVariable("Path",$env:Path,[System.EnvironmentVariableTarget]::User)
+[Environment]::SetEnvironmentVariable("Path",[Environment]::GetEnvironmentVariable("Path",[System.EnvironmentVariableTarget]::User)+";C:\xmake",[System.EnvironmentVariableTarget]::User)
xmake --version
|
driver(uart):update the comment of uart_set_wakeup_threshold
closes | @@ -801,7 +801,7 @@ esp_err_t uart_get_collision_flag(uart_port_t uart_num, bool* collision_flag);
* light sleep. This function allows setting the threshold value.
*
* Stop bit and parity bits (if enabled) also contribute to the number of edges.
- * For example, letter 'a' with ASCII code 97 is encoded as 010001101 on the wire
+ * For example, letter 'a' with ASCII code 97 is encoded as 0100001101 on the wire
* (with 8n1 configuration), start and stop bits included. This sequence has 3
* positive edges (transitions from 0 to 1). Therefore, to wake up the system
* when 'a' is sent, set wakeup_threshold=3.
@@ -813,7 +813,10 @@ esp_err_t uart_get_collision_flag(uart_port_t uart_num, bool* collision_flag);
* correct baud rate all the time, select REF_TICK as UART clock source,
* by setting use_ref_tick field in uart_config_t to true.
*
- * @note in ESP32, UART2 does not support light sleep wakeup feature.
+ * @note in ESP32, the wakeup signal can only be input via IO_MUX (i.e.
+ * GPIO3 should be configured as function_1 to wake up UART0,
+ * GPIO9 should be configured as function_5 to wake up UART1), UART2
+ * does not support light sleep wakeup feature.
*
* @param uart_num UART number
* @param wakeup_threshold number of RX edges for light sleep wakeup, value is 3 .. 0x3ff.
|
Renamed cus in filter to cas. | ?: |((lth a 32) =(a `@c`127))
`@`'?'
:: if desired, remove uppercasing.
- ?: ?& !cus.fit.shape
+ ?: ?& !cas.fit.shape
(gte a 'A')
(lte a 'Z')
==
|
Update hb.c
Change the default state to disabled (uncomment the latter).
Clean the unused commented lines. | * latter to enable the (selected) font features.
*/
-//hb_feature_t features[] = { 0 };
-hb_feature_t features[] = { FEATURE('s','s','0','1'), FEATURE('s','s','0','2'), FEATURE('s','s','0','3'), FEATURE('s','s','0','5'), FEATURE('s','s','0','6'), FEATURE('s','s','0','7'), FEATURE('s','s','0','8'), FEATURE('z','e','r','o') };
+hb_feature_t features[] = { 0 };
+//hb_feature_t features[] = { FEATURE('s','s','0','1'), FEATURE('s','s','0','2'), FEATURE('s','s','0','3'), FEATURE('s','s','0','5'), FEATURE('s','s','0','6'), FEATURE('s','s','0','7'), FEATURE('s','s','0','8'), FEATURE('z','e','r','o') };
void hbtransformsegment(XftFont *xfont, const Glyph *string, hb_codepoint_t *codepoints, int start, int length);
hb_font_t *hbfindfont(XftFont *match);
@@ -73,7 +73,6 @@ void
hbtransform(XftGlyphFontSpec *specs, const Glyph *glyphs, size_t len, int x, int y)
{
int start = 0, length = 1, gstart = 0;
- //hb_codepoint_t *codepoints = calloc(len, sizeof(hb_codepoint_t));
hb_codepoint_t *codepoints = calloc((unsigned int)len, sizeof(hb_codepoint_t));
for (int idx = 1, specidx = 1; idx < len; idx++) {
@@ -139,7 +138,6 @@ hbtransformsegment(XftFont *xfont, const Glyph *string, hb_codepoint_t *codepoin
}
/* Shape the segment. */
- //hb_shape(font, buffer, NULL, 0);
hb_shape(font, buffer, features, sizeof(features));
/* Get new glyph info. */
|
Updated websocket sender to use mg_websocket_write instead of client_write. | @@ -329,7 +329,7 @@ static int psa_websocket_topicPublicationSend(void* handle, unsigned int msgType
json_object_set_new_nocheck(jsMsg, "data", jsData);
const char *msg = json_dumps(jsMsg, 0);
size_t bytes_to_write = strlen(msg);
- int bytes_written = mg_websocket_client_write(sender->sockConnection, MG_WEBSOCKET_OPCODE_TEXT, msg,
+ int bytes_written = mg_websocket_write(sender->sockConnection, MG_WEBSOCKET_OPCODE_TEXT, msg,
bytes_to_write);
free((void *) msg);
json_decref(jsData); //Decrease ref count means freeing the object
|
Add KnowBe4 to the "who's using YARA" list. | @@ -92,6 +92,7 @@ awesome list of [YARA-related stuff](https://github.com/InQuest/awesome-yara).
* [Joe Security](https://www.joesecurity.org)
* [jsunpack-n](http://jsunpack.jeek.org/)
* [Kaspersky Lab](http://www.kaspersky.com)
+* [KnowBe4](https://www.knowbe4.com)
* [Koodous](https://koodous.com/)
* [Laika BOSS](https://github.com/lmco/laikaboss)
* [Lastline, Inc.](http://www.lastline.com)
|
apps/speed.c: initialize buffers
Stop valgrind's complaints about uninitialized values. | @@ -1268,6 +1268,7 @@ int speed_main(int argc, char **argv)
long count = 0;
int size_num = OSSL_NELEM(lengths_list);
int keylen;
+ int buflen;
#ifndef NO_FORK
int multi = 0;
#endif
@@ -1605,12 +1606,12 @@ int speed_main(int argc, char **argv)
}
}
- loopargs[i].buf_malloc =
- app_malloc(lengths[size_num - 1] + MAX_MISALIGNMENT + 1,
- "input buffer");
- loopargs[i].buf2_malloc =
- app_malloc(lengths[size_num - 1] + MAX_MISALIGNMENT + 1,
- "input buffer");
+ buflen = lengths[size_num - 1] + MAX_MISALIGNMENT + 1;
+ loopargs[i].buf_malloc = app_malloc(buflen, "input buffer");
+ loopargs[i].buf2_malloc = app_malloc(buflen, "input buffer");
+ memset(loopargs[i].buf_malloc, 0, buflen);
+ memset(loopargs[i].buf2_malloc, 0, buflen);
+
/* Align the start of buffers on a 64 byte boundary */
loopargs[i].buf = loopargs[i].buf_malloc + misalign;
loopargs[i].buf2 = loopargs[i].buf2_malloc + misalign;
|
netsock_shutdown(): prevent socket use after TX and RX shutdown
If close() is called on a TCP socket after having called shutdown()
with SHUT_RDWR argument, the underlying lwIP structure should not
be touched in the close() function, because it has been deallocated
(or is about to be deallocated) due to the call to tcp_shutdown(). | @@ -706,6 +706,11 @@ static sysreturn netsock_shutdown(struct sock *sock, int how)
return -ENOTCONN;
}
tcp_shutdown(s->info.tcp.lw, shut_rx, shut_tx);
+ if (shut_rx && shut_tx) {
+ /* Shutting down both TX and RX is equivalent to calling
+ * tcp_close(), so the pcb should not be referenced anymore. */
+ s->info.tcp.lw = 0;
+ }
break;
case SOCK_DGRAM:
return -ENOTCONN;
|
options/posix: Implement strncasecmp() | @@ -26,7 +26,17 @@ int strcasecmp(const char *a, const char *b) {
}
int strncasecmp(const char *a, const char *b, size_t size) {
- __ensure(!"Not implemented");
- __builtin_unreachable();
+ for(size_t i = 0; i < size; i++) {
+ unsigned char a_byte = tolower(a[i]);
+ unsigned char b_byte = tolower(b[i]);
+ if(!a_byte && !b_byte)
+ return 0;
+ // If only one char is null, one of the following cases applies.
+ if(a_byte < b_byte)
+ return -1;
+ if(a_byte > b_byte)
+ return 1;
+ }
+ return 0;
}
|
zephyr/emul/emul_ln9310.c: Format with clang-format
BRANCH=none
TEST=none | @@ -30,10 +30,8 @@ enum functional_mode {
/* TODO shutdown_mode, */
/* TODO bypass, */
FUNCTIONAL_MODE_STANDBY = LN9310_SYS_STANDBY,
- FUNCTIONAL_MODE_SWITCHING_21 =
- LN9310_SYS_SWITCHING21_ACTIVE,
- FUNCTIONAL_MODE_SWITCHING_31 =
- LN9310_SYS_SWITCHING31_ACTIVE
+ FUNCTIONAL_MODE_SWITCHING_21 = LN9310_SYS_SWITCHING21_ACTIVE,
+ FUNCTIONAL_MODE_SWITCHING_31 = LN9310_SYS_SWITCHING31_ACTIVE
};
struct ln9310_emul_data {
|
Enable process scan test. | @@ -2059,7 +2059,7 @@ int main(int argc, char** argv)
test_global_rules();
#if !defined(USE_WINDOWS_PROC) && !defined(USE_NO_PROC)
- //test_process_scan();
+ test_process_scan();
#endif
#if defined(HASH_MODULE)
|
Fix an issue with libxsmm_aarch64_instruction_alu_compute_imm24. | @@ -1153,7 +1153,7 @@ void libxsmm_aarch64_instruction_alu_compute_imm24( libxsmm_generated_code* io_g
} else {
libxsmm_aarch64_instruction_alu_compute_imm12( io_generated_code, i_alu_instr, i_gp_reg_src, i_gp_reg_dst,
(unsigned short)(0xfff & i_imm24), 0);
- libxsmm_aarch64_instruction_alu_compute_imm12( io_generated_code, i_alu_instr, i_gp_reg_src, i_gp_reg_dst,
+ libxsmm_aarch64_instruction_alu_compute_imm12( io_generated_code, i_alu_instr, i_gp_reg_dst, i_gp_reg_dst,
(unsigned short)(0xfff & (i_imm24 >> 12)), 1);
}
}
|
Style and micro-optimizations in JSON parsing. | @@ -279,11 +279,13 @@ nxt_conf_json_parse_object(u_char *pos, u_char *end,
nxt_lvlhsh_t *object;
nxt_conf_json_obj_member_t *member;
- object = nxt_mem_zalloc(pool, sizeof(nxt_lvlhsh_t));
+ object = nxt_mem_alloc(pool, sizeof(nxt_lvlhsh_t));
if (nxt_slow_path(object == NULL)) {
return NULL;
}
+ nxt_lvlhsh_init(object);
+
value->type = NXT_CONF_JSON_OBJECT;
value->u.object = object;
@@ -471,11 +473,11 @@ nxt_conf_json_parse_string(u_char *pos, u_char *end,
case '"':
case '\\':
case '/':
- case 'b':
- case 'f':
case 'n':
case 'r':
case 't':
+ case 'b':
+ case 'f':
surplus++;
state = sw_usual;
continue;
@@ -558,14 +560,6 @@ nxt_conf_json_parse_string(u_char *pos, u_char *end,
*s++ = ch;
continue;
- case 'b':
- *s++ = '\b';
- continue;
-
- case 'f':
- *s++ = '\f';
- continue;
-
case 'n':
*s++ = '\n';
continue;
@@ -577,6 +571,14 @@ nxt_conf_json_parse_string(u_char *pos, u_char *end,
case 't':
*s++ = '\t';
continue;
+
+ case 'b':
+ *s++ = '\b';
+ continue;
+
+ case 'f':
+ *s++ = '\f';
+ continue;
}
utf = 0;
|
peview: ignore parent chained image certificate | @@ -163,6 +163,9 @@ BOOLEAN PvpPeAddCertificateInfo(
INT lvItemIndex;
WCHAR number[PH_INT32_STR_LEN_1];
+ if (element->pCertContext == CertificateContext) // skip parent
+ continue;
+
PhPrintUInt32(number, ++Context->Count);
lvItemIndex = PhAddListViewGroupItem(
Context->ListViewHandle,
@@ -175,6 +178,8 @@ BOOLEAN PvpPeAddCertificateInfo(
PvpPeAddCertificateInfo(Context, lvItemIndex, TRUE, element->pCertContext);
}
}
+
+ //CertFreeCertificateChain(chainContext);
}
}
|
fix(actions): Upload UF2 for all compatible boards | @@ -75,7 +75,7 @@ jobs:
args: 'build "-s app -b ${{ matrix.board }} -- -DSHIELD=${{ matrix.shield }}"'
- name: Archive Build
uses: actions/upload-artifact@v2
- if: ${{ matrix.board == 'nice_nano' }}
+ if: ${{ matrix.board != 'proton_c' }}
with:
name: "${{ matrix.board }}-${{ matrix.shield }}-zmk-uf2"
path: build/zephyr/zmk.uf2
|
Fix a build error
Fixed an error when neither of libraries are found the build fails.
JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik | @@ -229,6 +229,8 @@ jerry_debugger_sleep (unsigned milliseconds) /**< suspending time */
, NULL);
#elif defined (HAVE_UNISTD_H)
usleep ((useconds_t) milliseconds * 1000);
+#else /* If neither of the libs found */
+ JERRY_UNUSED (milliseconds);
#endif /* HAVE_TIME_H */
} /* jerry_debugger_sleep */
|
Fix multi-line script call | @@ -129,7 +129,7 @@ hello1: check
--header-size $(BOOT_HEADER_LEN) \
--align $(FLASH_ALIGNMENT) \
--version 1.2 \
- --slot-size 0x60000
+ --slot-size 0x60000 \
$(BUILD_DIR_HELLO1)/zephyr/zephyr.bin \
signed-hello1.bin
|
[NFSU2] prevent sticky input caused by high FPS | @@ -737,6 +737,11 @@ void Init()
injector::WriteMemory(dword_865558, FrameTime, true);
uint32_t* dword_7FB710 = *hook::pattern("D9 05 ? ? ? ? D8 74 ? ? D9 1D ? ? ? ? C3").count(1).get(0).get<uint32_t*>(33);
injector::WriteMemory(dword_7FB710, FrameTime, true);
+
+ // GAME BUGFIX: disable player steering autocentering to prevent sticky input
+ // same thing as NFSU fix, check its dllmain.cpp for more info
+ uint32_t* dword_416D82 = hook::pattern("DD D8 D9 44 24 18 D9 54 24 1C D9 E1 D8 1D ? ? ? ? DF E0 F6 C4 05").count(1).get(0).get<uint32_t>(0x17); //0x416D6B anchor
+ injector::WriteMemory<uint8_t>(dword_416D82, 0xEB, true);
}
if (b60FPSCutscenes)
|
Always rebuild APK; | @@ -658,10 +658,8 @@ elseif(ANDROID)
endif()
# Make an apk
- add_custom_command(
- TARGET lovr
- POST_BUILD
- BYPRODUCTS lovr.apk
+ add_custom_target(
+ buildAPK ALL
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMAND ${CMAKE_COMMAND} -E copy "${ANDROID_MANIFEST}" AndroidManifest.xml
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/src/resources/Activity_${ACTIVITY}.java Activity.java
|
khan: special case removing chan at list head | @@ -64,20 +64,24 @@ _khan_moor_bail(void* ptr_v, ssize_t err_i, const c3_c* err_c)
{
u3_chan* can_u = (u3_chan*)ptr_v;
u3_shan* san_u = can_u->san_u;
- u3_khan* kan_u = san_u->kan_u;
u3_chan* inn_u;
if ( err_i == UV_EOF ) {
// close socket and remove reference.
+ if ( san_u->can_u == can_u ) {
+ san_u->can_u = (u3_chan*)can_u->mor_u.nex_u;
+ }
+ else {
for ( inn_u = san_u->can_u; inn_u; inn_u = (u3_chan*)inn_u->mor_u.nex_u ) {
if ( (u3_chan*)inn_u->mor_u.nex_u == can_u ) {
inn_u->mor_u.nex_u = can_u->mor_u.nex_u;
- can_u->mor_u.nex_u = NULL;
- u3_newt_moat_stop((u3_moat*)&can_u->mor_u, _khan_moat_free);
break;
}
}
}
+ can_u->mor_u.nex_u = NULL;
+ u3_newt_moat_stop((u3_moat*)&can_u->mor_u, _khan_moat_free);
+ }
else {
// TODO retry up to N
u3_noun bal;
|
BugID:23090338: Fix app build error while $(TOOLCHAIN_PATH) is empty
The $(TOOLCHAIN_PATH) is empty if toolchains installed on system. | @@ -19,7 +19,7 @@ ifneq ($(findstring $(HOST_OS),Win32 Win64),)
$(eval OUT_MSG := $(shell cmd /c %cd%$($(HOST_MCU_FAMILY)_LOCATION)\script\postbuild_img2.bat $(ota2_offset) %cd% $(APP_FULL) $(PLATFORM)))
else
@echo $(HOST_OS) $(ota_idx) $(SOURCE_ROOT) $(APP_FULL) $(PLATFORM) $(TOOLCHAIN_PATH)
- $(eval OUT_MSG := $(shell sh $($(HOST_MCU_FAMILY)_LOCATION)/script/manipulate_image.sh $(ota2_offset) $(SOURCE_ROOT) $(APP_FULL) $(PLATFORM) $(TOOLCHAIN_PATH) $(APPDIR)))
+ $(eval OUT_MSG := $(shell sh $($(HOST_MCU_FAMILY)_LOCATION)/script/manipulate_image.sh $(ota2_offset) $(SOURCE_ROOT) $(APP_FULL) $(PLATFORM) "$(TOOLCHAIN_PATH)" $(APPDIR)))
endif
gen_image_bin_2ndboot:
@@ -28,7 +28,7 @@ ifneq ($(findstring $(HOST_OS),Win32 Win64),)
$(eval OUT_MSG := $(shell cmd /c %cd%$($(HOST_MCU_FAMILY)_LOCATION)\script\postbuild_img2.bat $(ota1_offset) %cd% $(APP_FULL) $(PLATFORM)))
else
@echo $(HOST_OS) $(ota_idx) $(SOURCE_ROOT) $(APP_FULL) $(PLATFORM) $(TOOLCHAIN_PATH)
- $(eval OUT_MSG := $(shell sh $($(HOST_MCU_FAMILY)_LOCATION)/script/manipulate_image.sh $(ota1_offset) $(SOURCE_ROOT) $(APP_FULL) $(PLATFORM) $(TOOLCHAIN_PATH) $(APPDIR)))
+ $(eval OUT_MSG := $(shell sh $($(HOST_MCU_FAMILY)_LOCATION)/script/manipulate_image.sh $(ota1_offset) $(SOURCE_ROOT) $(APP_FULL) $(PLATFORM) "$(TOOLCHAIN_PATH)" $(APPDIR)))
endif
#bootloader
|
pbio/control: enforce control limit
This was already used to trigger anti-windup, but the maximum duty value was not enforced in the actual control output signal. | @@ -47,7 +47,9 @@ void control_update(pbio_control_t *ctl, int32_t time_now, int32_t count_now, in
duty_due_to_integral = (ctl->settings.pid_ki*(count_err_integral/US_PER_MS))/MS_PER_SECOND;
duty_feedforward = pbio_math_sign(rate_ref)*ctl->settings.control_offset;
+ // Total duty signal, capped by the actuation limit
duty = duty_due_to_proportional + duty_due_to_integral + duty_due_to_derivative + duty_feedforward;
+ duty = max(-ctl->settings.max_control, min(duty, ctl->settings.max_control));
// This completes the computation of the control signal.
// The next steps take care of handling windup, or triggering a stop if we are on target.
|
State Build Requirements at the Top | # Building MsQuic
-MsQuic uses [CMake](https://cmake.org/) to generate build files.
+The full MsQuic build system relies on [CMake](https://cmake.org/) (3.16 or better), [.NET Core](https://dotnet.microsoft.com/download/dotnet-core) (3.1 SDK) and [Powershell](https://docs.microsoft.com/en-us/powershell/scripting/install/installing-powershell) (7.0 or better) on all platforms.
> **Note** - clone the repo recursively or run `git submodule update --init --recursive`
to get all the submodules.
|
Supporting HTTP/1.0 keep-alive.
The Apache HTTP server benchmarking tool, ab, issues HTTP/1.0 requests with
the 'Connection: Keep-Alive' header and expects a 'Connection: Keep-Alive'
header in the response. | @@ -734,9 +734,16 @@ nxt_h1p_connection(void *ctx, nxt_http_field_t *field, uintptr_t data)
r = ctx;
field->hopbyhop = 1;
- if (field->value_length == 5 && nxt_memcmp(field->value, "close", 5) == 0) {
+ if (field->value_length == 5
+ && nxt_memcasecmp(field->value, "close", 5) == 0)
+ {
r->proto.h1->keepalive = 0;
+ } else if (field->value_length == 10
+ && nxt_memcasecmp(field->value, "keep-alive", 10) == 0)
+ {
+ r->proto.h1->keepalive = 1;
+
} else if (field->value_length == 7
&& nxt_memcasecmp(field->value, "upgrade", 7) == 0)
{
|
components/keyboard_switch: show next keyboard, not current | @@ -47,20 +47,25 @@ static void _render(component_t* component)
UG_S16 w = 0, h = 0;
switch (ks_data->mode) {
case LOWER_CASE:
- UG_MeasureString(&w, &h, "abc");
- UG_PutString((SCREEN_WIDTH - w) / 2 + 2, 1, "abc", false);
- break;
- case UPPER_CASE:
UG_MeasureString(&w, &h, "ABC");
UG_PutString((SCREEN_WIDTH - w) / 2 + 1, 1, "ABC", false);
break;
- case DIGITS:
+ case UPPER_CASE:
UG_MeasureString(&w, &h, "123");
UG_PutString((SCREEN_WIDTH - w) / 2 + 1, 1, "123", false);
break;
- case SPECIAL_CHARS:
+ case DIGITS:
+ if (ks_data->special_chars) {
UG_MeasureString(&w, &h, "&?+");
UG_PutString((SCREEN_WIDTH - w) / 2 + 1, 1, "&?+", false);
+ } else {
+ UG_MeasureString(&w, &h, "abc");
+ UG_PutString((SCREEN_WIDTH - w) / 2 + 2, 1, "abc", false);
+ }
+ break;
+ case SPECIAL_CHARS:
+ UG_MeasureString(&w, &h, "abc");
+ UG_PutString((SCREEN_WIDTH - w) / 2 + 2, 1, "abc", false);
break;
default:
Abort("Keyboard mode unrecognized");
|
in_netif: fix uninitialized variable to malloc | @@ -71,13 +71,13 @@ static int init_entry_linux(struct flb_in_netif_config *ctx)
{
int i;
+ ctx->entry_len = sizeof(entry_name_linux) / sizeof(struct entry_define);
ctx->entry = flb_malloc(sizeof(struct netif_entry) * ctx->entry_len);
if (!ctx->entry) {
flb_errno();
return -1;
}
- ctx->entry_len = sizeof(entry_name_linux) / sizeof(struct entry_define);
for(i = 0; i < ctx->entry_len; i++) {
ctx->entry[i].name = entry_name_linux[i].name;
ctx->entry[i].name_len = strlen(entry_name_linux[i].name);
|
doc: hide doxygen duplicate definition warnings
Sphinx/Breathe have a known problem with processing unnamed nested
structs and unions that cause a "Duplicate definition" warning.
Use our .known-issues filter to hide these in the HLD content. | #
-# Emulated devices
+# HLD warnings
#
-#
-^(?P<filename>[-._/\w]+/hld/hv-io-emulation.rst):(?P<lineno>[0-9]+): WARNING: Duplicate declaration.
+#^(?P<filename>[-._/\w]+/hld/hv-cpu-virt.rst):(?P<lineno>[0-9]+): WARNING: Duplicate declaration.
+^(?P<filename>[-._/\w]+/hld/[-._/\w]+.rst):(?P<lineno>[0-9]+): WARNING: Duplicate declaration.
|
mpi-families/openmpi: bump version to v3.1.3 | @@ -34,7 +34,7 @@ Summary: A powerful implementation of MPI
Name: %{pname}%{RMS_DELIM}-%{compiler_family}%{PROJ_DELIM}
-Version: 3.1.2
+Version: 3.1.3
Release: 1%{?dist}
License: BSD-3-Clause
Group: %{PROJ_NAME}/mpi-families
|
arch/xtensa: Add GPIO input floating mode in esp32 gpio driver.
Add GPIO input floating mode. | @@ -163,6 +163,8 @@ static int esp32_gpio_pull(FAR struct gpio_lowerhalf_s *lower, unsigned long arg
priv->pincfg |= PULLUP;
} else if (arg == GPIO_DRIVE_PULLDOWN) {
priv->pincfg |= PULLDOWN;
+ } else if (arg == GPIO_DRIVE_FLOAT) {
+ priv->pincfg &= ~(PULLDOWN | PULLUP);
} else {
return -EINVAL;
}
|
Fix pattern found after rename to snap. | @@ -91,7 +91,7 @@ fi
if [ $search -eq 1 ]; then
echo -n "Trying demo_search ... "
- cmd="./examples/demo_search -C${snap_card} -E 84 \
+ cmd="./examples/demo_search -C${snap_card} -E 98 \
-i examples/demo_search.txt -p snap > \
examples/demo_search.log 2>&1"
eval ${cmd}
|
[CI] Check in dependencies script | +#!/usr/bin/python3
+from pathlib import Path
+
+from build_utils import run_and_check
+
+
+def install_dependencies():
+ print(f"Installing dependencies...")
+ run_and_check(["sudo", "apt", "update"])
+ dependencies = [
+ "build-essential",
+ "bison",
+ "flex",
+ "libgmp3-dev",
+ "libmpc-dev",
+ "libmpfr-dev",
+ "texinfo",
+ "xorriso",
+ ]
+ run_and_check(["sudo", "apt", "install", "-y", *dependencies])
+
+ requirements_file = Path(__file__).parents[1] / "python-dependencies.txt"
+ run_and_check(["pip3", "install", "-r", requirements_file.as_posix()])
+
+
+def main() -> None:
+ install_dependencies()
+
+
+if __name__ == '__main__':
+ main()
|
Flush stdout after PRINTLN
This allows debug PRINTLN statements to run even if
subsequent rgbasm directives cause a crash. | @@ -1164,8 +1164,14 @@ popc : T_POP_POPC { charmap_Pop(); }
print : T_POP_PRINT print_exprs trailing_comma
;
-println : T_POP_PRINTLN { putchar('\n'); }
- | T_POP_PRINTLN print_exprs trailing_comma { putchar('\n'); }
+println : T_POP_PRINTLN {
+ putchar('\n');
+ fflush(stdout);
+ }
+ | T_POP_PRINTLN print_exprs trailing_comma {
+ putchar('\n');
+ fflush(stdout);
+ }
;
print_exprs : print_expr
|
VMS: have mkdef.pl parse lettered versions properly
Fixes | @@ -1288,7 +1288,7 @@ EOF
} elsif ($VMS) {
print OUT ")\n";
(my $libvmaj, my $libvmin, my $libvedit) =
- $currversion =~ /^(\d+)_(\d+)_(\d+)$/;
+ $currversion =~ /^(\d+)_(\d+)_(\d+)[a-z]{0,2}$/;
# The reason to multiply the edit number with 100 is to make space
# for the possibility that we want to encode the patch letters
print OUT "GSMATCH=LEQUAL,",($libvmaj * 100 + $libvmin),",",($libvedit * 100),"\n";
|
nimble/monitor: Add support for BabbleSim | #error "Cannot enable monitor over UART and RTT at the same time!"
#endif
+#ifdef BABBLESIM
+#define _GNU_SOURCE
+#include <stdio.h>
+#endif
+
#include <stdarg.h>
#include <stdio.h>
#include <inttypes.h>
@@ -258,6 +263,7 @@ monitor_write_header(uint16_t opcode, uint16_t len)
monitor_write(&ts_hdr, sizeof(ts_hdr));
}
+#ifndef BABBLESIM
static size_t
btmon_write(FILE *instance, const char *bp, size_t n)
{
@@ -271,6 +277,7 @@ static FILE *btmon = (FILE *) &(struct File) {
.write = btmon_write,
},
};
+#endif
#if MYNEWT_VAL(BLE_MONITOR_RTT) && MYNEWT_VAL(BLE_MONITOR_RTT_BUFFERED)
static void
@@ -436,9 +443,24 @@ ble_monitor_log(int level, const char *fmt, ...)
monitor_write(&ulog, sizeof(ulog));
monitor_write(id, sizeof(id));
+#ifdef BABBLESIM
+ do {
+ char *tmp;
+ int len;
+
+ va_start(va, fmt);
+ len = vasprintf(&tmp, fmt, va);
+ assert(len >= 0);
+ va_end(va);
+
+ monitor_write(tmp, len);
+ free(tmp);
+ } while (0);
+#else
va_start(va, fmt);
vfprintf(btmon, fmt, va);
va_end(va);
+#endif
/* null-terminate string */
monitor_write("", 1);
|
HLS: Adding actions subdir to clean rule | subdirs += software
hardware_subdirs += hardware
+action_subdirs += hardware/action_examples
all: $(subdirs)
@@ -43,11 +44,10 @@ config model image:
done
clean:
- @for dir in $(subdirs) $(hardware_subdirs); do \
+ @for dir in $(subdirs) $(hardware_subdirs) $(action_subdirs); do \
if [ -d $$dir ]; then \
$(MAKE) -C $$dir $@ || exit 1; \
fi \
done
@find . -depth -name '*~' -exec rm -rf '{}' \; -print
@find . -depth -name '.#*' -exec rm -rf '{}' \; -print
-
|
restyled: use Clang 12 | -restylers_version: '20191216'
+restylers_version: 'v0.35.0'
auto: true
restylers:
- clang-format:
- image: restyled/restyler-clang-format:v9.0.0
+ image: restyled/restyler-clang-format:12.0.0
include:
- "!tests/shell/gen/**/*"
- "!**/*.js"
|
Update docs for `space_managment_evict_do()` | @@ -58,11 +58,11 @@ struct eviction_policy_ops {
extern struct eviction_policy_ops evict_policy_ops[ocf_eviction_max];
/*
- * Deallocates space from low priority partitions.
+ * Deallocates space according to eviction priorities.
*
- * Returns -1 on error
- * or the destination partition ID for the free buffers
- * (it matches label and is part of the object (#core_id) IO group)
+ * @returns:
+ * 'LOOKUP_HIT' if evicted enough cachelines to serve @req
+ * 'LOOKUP_MISS' otherwise
*/
int space_managment_evict_do(ocf_cache_t cache,
struct ocf_request *req, uint32_t evict_cline_no);
|
add /etc/template_generator/templates/etc/logrotate.d/:App to files allowed for yacare to generate in ya package | @@ -699,7 +699,7 @@ macro YCR_GENERATE_CONFIGS_INTL(Package, App, Configs...) {
}
macro YCR_GENERATE_CONFIGS(Package, App) {
- .CMD=$YCR_GENERATE_CONFIGS_INTL($Package $App ${pre=etc/yandex/maps/yacare/:App.conf} ${pre=etc/logrotate.d/:App} ${pre=etc/monrun/conf.d/:App.conf} ${pre=etc/nginx/sites-available/:App.conf} ${pre=etc/syslog-ng/conf-available/:App.conf} ${pre=usr/lib/yandex/maps/yacare/checks/:App} ${pre=usr/lib/yandex/maps/yacare/stat/:App} ${pre=etc/template_generator/config.d/:App.yaml} ${pre=/juggler/checks-available/yacare_;suf=/MANIFEST.json:App} ${pre=etc/yandex/maps/roquefort/:App.conf} ${pre=usr/lib/yandex/maps/yacare/lua/init_worker.d/rate_limiter_:App.lua} ${pre=usr/lib/yandex/maps/yacare/lua/init_worker.d/tvm_:App.lua} ${pre=usr/lib/yandex/maps/yacare/lua/init.d/tvm_:App.lua})
+ .CMD=$YCR_GENERATE_CONFIGS_INTL($Package $App ${pre=etc/yandex/maps/yacare/:App.conf} ${pre=etc/logrotate.d/:App} ${pre=etc/template_generator/templates/etc/logrotate.d/:App} ${pre=etc/monrun/conf.d/:App.conf} ${pre=etc/nginx/sites-available/:App.conf} ${pre=etc/syslog-ng/conf-available/:App.conf} ${pre=usr/lib/yandex/maps/yacare/checks/:App} ${pre=usr/lib/yandex/maps/yacare/stat/:App} ${pre=etc/template_generator/config.d/:App.yaml} ${pre=/juggler/checks-available/yacare_;suf=/MANIFEST.json:App} ${pre=etc/yandex/maps/roquefort/:App.conf} ${pre=usr/lib/yandex/maps/yacare/lua/init_worker.d/rate_limiter_:App.lua} ${pre=usr/lib/yandex/maps/yacare/lua/init_worker.d/tvm_:App.lua} ${pre=usr/lib/yandex/maps/yacare/lua/init.d/tvm_:App.lua})
}
YCR_LINK_EXE=$LINK_EXE && $YCR_GENERATE_CONFIGS($REALPRJNAME $REALPRJNAME)
|
Fix crash on destroying NULL swapchain
Vulkan spec allows calling vkDestroySwapchainKHR with VK_NULL_HANDLE swapchain.
mesa MR#5616 | @@ -1837,6 +1837,12 @@ static void overlay_DestroySwapchainKHR(
VkSwapchainKHR swapchain,
const VkAllocationCallbacks* pAllocator)
{
+ if (swapchain == VK_NULL_HANDLE) {
+ struct device_data *device_data = FIND(struct device_data, device);
+ device_data->vtable.DestroySwapchainKHR(device, swapchain, pAllocator);
+ return;
+ }
+
struct swapchain_data *swapchain_data =
FIND(struct swapchain_data, swapchain);
|
os400qc3.h: define EC types to fix building
File: os400qc3.h
Notes: define missing EC types which prevents building
Credit: hjindra | #define LIBSSH2_RSA 1
#define LIBSSH2_DSA 0
+#define LIBSSH2_ECDSA 0
+#define LIBSSH2_ED25519 0
#define MD5_DIGEST_LENGTH 16
#define SHA_DIGEST_LENGTH 20
#define SHA256_DIGEST_LENGTH 32
#define SHA512_DIGEST_LENGTH 64
+#define EC_MAX_POINT_LEN ((528 * 2 / 8) + 1)
+
+#if LIBSSH2_ECDSA
+#else
+#define _libssh2_ec_key void
+#endif
/*******************************************************************
*
|
Fixed wget incorrect URL on README | @@ -82,7 +82,7 @@ AOMP needs certain support for Linux to function properly, such as the KFD drive
On Ubuntu 18.04 LTS (bionic beaver), run these commands:
```
-wget https://github.com/ROCm-Developer-Tools/aomp/releases/download/r/aomp_Ubuntu1804_0.6-2_amd64.deb
+wget https://github.com/ROCm-Developer-Tools/aomp/releases/download/rel_0.6-2/aomp_Ubuntu1804_0.6-2_amd64.deb
sudo dpkg -i aomp_Ubuntu1804_0.6-2_amd64.deb
```
The AOMP bin directory (which includes the standard clang and llvm binaries) is not intended to be in your PATH for typical operation.
@@ -100,7 +100,7 @@ By default, the packages install their content to the release directory /opt/roc
To install the debian package without root access into your home directory, you can run these commands.
```
- wget https://github.com/ROCm-Developer-Tools/aomp/releases/download/r/aomp_Ubuntu1604_0.6-2_amd64.deb
+ wget https://github.com/ROCm-Developer-Tools/aomp/releases/download/rel_0.6-2/aomp_Ubuntu1604_0.6-2_amd64.deb
dpkg -x aomp_Ubuntu1604_0.6-2_amd64.deb /tmp/temproot
mv /tmp/temproot/opt/rocm $HOME
export PATH=$PATH:$HOME/rocm/aomp/bin
@@ -115,7 +115,7 @@ By default, the packages install their content to the release directory /opt/roc
To install the rpm package without root access into your home directory, you can run these commands.
```
mkdir /tmp/temproot ; cd /tmp/temproot
- wget https://github.com/ROCm-Developer-Tools/aomp/releases/download/r/aomp-0.6-2.x86_64.rpm
+ wget https://github.com/ROCm-Developer-Tools/aomp/releases/download/rel_0.6-2/aomp-0.6-2.x86_64.rpm
rpm2cpio aomp-0.6-2.x86_64.rpm | cpio -idmv
mv /tmp/temproot/opt/rocm $HOME
export PATH=$PATH:$HOME/rocm/aomp/bin
|
I merged a change to the utah custom launcher from the 2.13RC to the trunk. | @@ -17,15 +17,15 @@ class UtahLauncher(MainLauncher):
def Customize(self):
msg = """
-NOTE: Using a specific MPI implementation (mvapich2/2.1.g) which the release versions of VisIt are known to be compiled against.
+NOTE: Using a specific MPI implementation (mvapich2/2.2g49-c7) which the release versions of VisIt are known to be compiled against.
If you are a *developer*, it's very likely I've chosen the wrong MPI implementation; you might have to hack internallauncher to load the module you need.\n"""
- print msg
+# print msg
sys.path.insert(0,"/uufs/chpc.utah.edu/sys/installdir/lmod/lmod-c7/init")
from env_modules_python import module
module("purge")
- module("load","visit/2.13.0 gcc/4.9.2 mvapich2/2.2.g libxml2")
+ module("load","visit/2.13.1 gcc/4.9.2 mvapich2/2.2.g libxml2")
# Launcher creation function
|
[Kernel] rename list_for_each/list_first_entry. | @@ -114,25 +114,25 @@ rt_inline int rt_list_isempty(const rt_list_t *l)
((type *)((char *)(node) - (unsigned long)(&((type *)0)->member)))
/**
- * list_for_each_entry - iterate over list of given type
+ * rt_list_for_each_entry - iterate over list of given type
* @pos: the type * to use as a loop cursor.
* @head: the head for your list.
* @member: the name of the list_struct within the struct.
*/
-#define list_for_each_entry(pos, head, member) \
+#define rt_list_for_each_entry(pos, head, member) \
for (pos = rt_list_entry((head)->next, typeof(*pos), member); \
&pos->member != (head); \
pos = rt_list_entry(pos->member.next, typeof(*pos), member))
/**
- * list_first_entry - get the first element from a list
+ * rt_list_first_entry - get the first element from a list
* @ptr: the list head to take the element from.
* @type: the type of the struct this is embedded in.
* @member: the name of the list_struct within the struct.
*
* Note, that list is expected to be not empty.
*/
-#define list_first_entry(ptr, type, member) \
+#define rt_list_first_entry(ptr, type, member) \
rt_list_entry((ptr)->next, type, member)
/*@}*/
|
volteer: disable ppc_dump command to save space
Increases flash space on Volteer by 872 bytes.
BRANCH=none
TEST=make buildall
Tested-by: Abe Levkoy | #undef CONFIG_CMD_ACCEL_INFO
#undef CONFIG_CMD_ACCELSPOOF
#undef CONFIG_CMD_BATTFAKE
+#undef CONFIG_CMD_PPC_DUMP
#define CONFIG_USB_POWER_DELIVERY
#define CONFIG_USB_PD_ALT_MODE
#define CONFIG_USB_MUX_RUNTIME_CONFIG
#define CONFIG_USBC_PPC
-#define CONFIG_CMD_PPC_DUMP
/* Note - SN5S330 support automatically adds
* CONFIG_USBC_PPC_POLARITY
* CONFIG_USBC_PPC_SBU
|
Supposedly fixed Masternode Key Verification | @@ -1002,6 +1002,7 @@ bool AppInit2(boost::thread_group& threadGroup)
std::string errorMessage;
CKey key;
+ key.MakeNewKey(false); // Pretty important.
CPubKey pubkey;
if(!darkSendSigner.SetKey(strMasterNodePrivKey, errorMessage, key, pubkey))
|
crypto_openssl: call EVP_EncryptFinal_ex only if needed | @@ -69,6 +69,7 @@ openssl_ops_enc_cbc (vlib_main_t * vm, vnet_crypto_op_t * ops[], u32 n_ops,
EVP_EncryptInit_ex (ctx, cipher, NULL, op->key, op->iv);
EVP_EncryptUpdate (ctx, op->dst, &out_len, op->src, op->len);
+ if (out_len < op->len)
EVP_EncryptFinal_ex (ctx, op->dst + out_len, &out_len);
op->status = VNET_CRYPTO_OP_STATUS_COMPLETED;
}
@@ -90,6 +91,7 @@ openssl_ops_dec_cbc (vlib_main_t * vm, vnet_crypto_op_t * ops[], u32 n_ops,
EVP_DecryptInit_ex (ctx, cipher, NULL, op->key, op->iv);
EVP_DecryptUpdate (ctx, op->dst, &out_len, op->src, op->len);
+ if (out_len < op->len)
EVP_DecryptFinal_ex (ctx, op->dst + out_len, &out_len);
op->status = VNET_CRYPTO_OP_STATUS_COMPLETED;
}
|
[BSP] add -nostartfiles in link flags of sam7x bsp | @@ -42,7 +42,7 @@ if PLATFORM == 'gcc':
DEVICE = ' -mcpu=arm7tdmi'
CFLAGS = DEVICE
AFLAGS = ' -c' + DEVICE + ' -x assembler-with-cpp'
- LFLAGS = DEVICE + ' -Wl,--gc-sections,-Map=sam7x_rom_gcc.map,-cref,-u,_start -T sam7x_rom.ld'
+ LFLAGS = DEVICE + ' -Wl,--gc-sections,-Map=sam7x_rom_gcc.map,-cref,-u,_start -T sam7x_rom.ld -nostartfiles'
CPATH = ''
LPATH = ''
|
Fix uninitialized slot variable | @@ -492,7 +492,7 @@ M3Result _PushAllocatedSlotAndEmit (IM3Compilation o, u8 i_type, bool i_doEmit
{
M3Result result = m3Err_none;
- u16 slot;
+ u16 slot = c_slotUnused;
_ (AllocateSlots (o, & slot, i_type));
_ (Push (o, i_type, slot));
@@ -568,7 +568,7 @@ _ (Push (o, i_type, slot));
if (not matchFound)
{
- u16 slot;
+ u16 slot = c_slotUnused;
result = AllocateConstantSlots (o, & slot, i_type);
if (result) // no more constant table space; use inline constants
|
safer DMA on DMA_doDMA(..)
Make sure the VDP write issuing DMA command is a memory word write for safer DMA operation (see Sega technical bulletin to have more information about possible issue here) | @@ -425,12 +425,20 @@ void DMA_doDma(u8 location, u32 from, u16 to, u16 len, s16 step)
break;
}
- const u16 cmdh = cmd >> 16;
- const u16 cmdl = cmd;
-
- pw = (vu16*) GFX_CTRL_PORT;
pwz = (vu16*) Z80_HALT_PORT;
+ {
+ vu32 cmdbuf[1];
+ u16* cmdbufp;
+
+ // force storing DMA command into memory
+ cmdbuf[0] = cmd;
+
+ // then force issuing DMA from memory word operand
+ cmdbufp = (u16*) cmdbuf;
+ // first command word
+ *pw = *cmdbufp++;
+
// DISABLE Z80
*pwz = 0x0100;
#if (HALT_Z80_ON_DMA == 0)
@@ -442,9 +450,9 @@ void DMA_doDma(u8 location, u32 from, u16 to, u16 len, s16 step)
*pwz = z80restore;
#endif
- // trigger DMA
- *pw = cmdh;
- *pw = cmdl;
+ // trigger DMA (second word command wrote from memory to avoid possible failure on some MD)
+ *pw = *cmdbufp;
+ }
#if (HALT_Z80_ON_DMA != 0)
// re-enable Z80 after DMA (safer method)
|
New contexts_difference with iso8601 in logs | },
"contexts_difference": {
"formula": {
- "sandbox_id": 656514194,
+ "sandbox_id": 662668618,
"match": "contexts_difference"
},
"executable": {
|
sdl/render: allow nil indices parameter in Renderer.RenderGeometry() | @@ -1176,9 +1176,10 @@ func (renderer *Renderer) RenderGeometry(texture *Texture, vertices []Vertex, in
_texture := texture.cptr()
_vertices := (*C.SDL_Vertex)(unsafe.Pointer(&vertices[0]))
_num_vertices := C.int(len(vertices))
- _indices := (*C.int)(unsafe.Pointer(&indices[0]))
+ var _indices *C.int
_num_indices := C.int(0)
if indices != nil {
+ _indices = (*C.int)(unsafe.Pointer(&indices[0]))
_num_indices = C.int(len(indices))
}
err = errorFromInt(int(C.SDL_RenderGeometry(renderer.cptr(), _texture, _vertices, _num_vertices, _indices, _num_indices)))
|
Increase ARENA_FILE_VERSION because of the changes in the arena file format introduced in | @@ -37,7 +37,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define ARENA_FLAGS_FIXED_SIZE 1
#define ARENA_FLAGS_COALESCED 2
-#define ARENA_FILE_VERSION ((13 << 16) | MAX_THREADS)
+#define ARENA_FILE_VERSION ((14 << 16) | MAX_THREADS)
#define EOL ((size_t) -1)
|
Null check for GLSurfaceOnTouch after onDestroy. | @@ -1175,6 +1175,11 @@ implements SensorEventListener
public static void popupKeyboard(final int inMode, final String inContent, final int inType)
{
+ if(activity == null) {
+ Log.i("VIEW","popupKeyboard occured after destruction, ignoring...");
+ return;
+ }
+
activity.mHandler.post(new Runnable() {
@Override public void run()
{
|
ram_disk_path -> ram_drive_path | @@ -770,7 +770,7 @@ class Ya(object):
ram_disk_path = os.environ.get("DISTBUILD_RAM_DISK_PATH")
if ram_disk_path:
- self._test_params["ram_disk_path"] = ram_disk_path
+ self._test_params["ram_drive_path"] = ram_disk_path
if test_params:
for p in test_params:
|
search regions always from the lowest index | @@ -318,7 +318,7 @@ void* _mi_mem_alloc_aligned(size_t size, size_t alignment, bool commit, size_t*
// find a range of free blocks
void* p = NULL;
size_t count = mi_atomic_read(®ions_count);
- size_t idx = tld->region_idx; // start index is per-thread to reduce contention
+ size_t idx = 0; // tld->region_idx; // start index is per-thread to reduce contention
for (size_t visited = 0; visited < count; visited++, idx++) {
if (idx >= count) idx = 0; // wrap around
if (!mi_region_try_alloc_blocks(idx, blocks, size, commit, &p, id, tld)) return NULL; // error
|
And another attempt to match CR3. | @@ -144,8 +144,8 @@ void SoloFeature::collapseUMI_CR(uint32 iCB, uint32 *umiArray)
if ( maxg+1==0 )
continue; //this umi is not counted for any gene
- for (auto &ig : umiGeneHash0[iu.first]) {//check that this umi/gene had also top count for uncorrected umis
- if (ig.second>umiGeneHash0[iu.first][maxg]) {
+ for (auto &ig : umiGeneHash0[iu.first]) {//check that this umi/gene has >= read count than any uncorrected
+ if (ig.second>maxu && ig.first!=maxg) {
maxg=-1;
break;
};
|
[chainmaker]modify BoatContractResult compile warning | @@ -107,7 +107,7 @@ typedef struct TBoatContractResult
BUINT64 gas_used;
BoatContractResultCode contract_code;
BCHAR *contract_message;
- BoatFieldVariable payload
+ BoatFieldVariable payload;
} BoatContractResult;
typedef struct TBoatResponseData
|
CI: add missing permission section to AppVeyor status workflow
Follow up to | @@ -31,6 +31,9 @@ concurrency:
group: ${{ github.workflow }}-${{ github.event.sha }}-${{ github.event.target_url }}
cancel-in-progress: true
+permissions:
+ statuses: write
+
jobs:
split:
runs-on: ubuntu-latest
|
add repro/debug section | @@ -8,21 +8,33 @@ This directory is used for fuzzing.
[OSS-Fuzz] uses [LibFuzzer] by default which is included in clang.
Refer [Libfuzzer] official document if you want more detail.
-## Running
-You can prepare environment, build and run code by yourself, but you can use convenient scripts from [OSS-Fuzz]
+## Run locally
+You can build and run code by yourself. [OSS-Fuzz] offers convenient scripts
```sh
-$ cp $PATH_TO_MSQUIC/src/fuzzing/$YOUR_COOL_FUZZING.cc $PATH_TO_OSS_FUZZ/projects/msquic/
$ cd $PATH_TO_OSS_FUZZ
# build Docker image
$ python infra/helper.py build_image msquic
-# build fuzzing code
+# build fuzzing code, memory sanitizer is not supported yet
$ python infra/helper.py build_fuzzers --sanitizer <address/memory/undefined> msquic
# run fuzzing
$ python infra/helper.py run_fuzzer msquic $YOUR_COOL_FUZZING
```
Refer [OSS-Fuzz official document] for more detail
+## Reproduce and debug issue
+[Reproduce]
+[Debug]
+
+## Monitor your fuzzing
+Once fuzzing is deployed on OSS-Fuzz infra, it continuously run and report issue if it detects
+### Receive notification
+List your email under [auto_ccs] or [vendor_ccs] section in [project.yaml]
+Most of developer should be under [vendor_ccs]. Please follow instruction in [vendor_ccs] and feel free to create PR and let us know on issue or discussion.
+
+### Login OSS-Fuzz dashabord
+Your email need to be associated with google account
+
## Before adding change....
Please go to [msquic project directory] in [OSS-Fuzz] whether your change can be run without issue.
You might need to change `Dockerfile` and/or `build.sh` for installing libraries, COPYing fuzzing source, configuration files and build options.
@@ -33,3 +45,8 @@ You might need to change `Dockerfile` and/or `build.sh` for installing libraries
[OSS-Fuzz official document]: https://google.github.io/oss-fuzz
[msquic project directory]: https://github.com/google/oss-fuzz/tree/master/projects/msquic
[LibFuzzer]: https://llvm.org/LibFuzzer
+[Reproduce]: https://google.github.io/oss-fuzz/advanced-topics/reproducing/
+[Debug]: https://google.github.io/oss-fuzz/advanced-topics/debugging/
+[project.yaml]: https://github.com/google/oss-fuzz/blob/master/projects/msquic/project.yaml
+[auto_ccs]: https://google.github.io/oss-fuzz/getting-started/new-project-guide/#primary
+[vendor_ccs]: https://google.github.io/oss-fuzz/getting-started/new-project-guide/#vendor
|
common/mkbp_input_devices.c: Format with clang-format
BRANCH=none
TEST=none | @@ -89,7 +89,6 @@ void mkbp_update_switches(uint32_t sw, int state)
(const uint8_t *)&mkbp_switch_state);
}
-
/*****************************************************************************/
/* Hooks */
@@ -99,8 +98,7 @@ void mkbp_update_switches(uint32_t sw, int state)
*/
static void keyboard_power_button(void)
{
- mkbp_button_update(KEYBOARD_BUTTON_POWER,
- power_button_is_pressed());
+ mkbp_button_update(KEYBOARD_BUTTON_POWER, power_button_is_pressed());
}
DECLARE_HOOK(HOOK_POWER_BUTTON_CHANGE, keyboard_power_button,
HOOK_PRIO_DEFAULT);
@@ -239,7 +237,6 @@ static int command_mkbp_keyboard_press(int argc, char **argv)
return EC_SUCCESS;
}
DECLARE_CONSOLE_COMMAND(kbpress, command_mkbp_keyboard_press,
- "[col row [0 | 1]]",
- "Simulate keypress");
+ "[col row [0 | 1]]", "Simulate keypress");
#endif /* !defined(HAS_TASK_KEYSCAN) */
|
enclave-tls: support to show the build mode info for HW_RELEASE log | @@ -80,8 +80,12 @@ else ifeq ($(build_mode),HW_PRERELEASE)
@echo "The project has been built in pre-release hardware mode."
else ifeq ($(build_mode),SIM_PRERELEASE)
@echo "The project has been built in pre-release simulation mode."
-else
+else ifeq ($(build_mode),HW_RELEASE)
+ @echo "The project has been built in release hardware mode."
+else ifeq ($(build_mode),SIM_RELEASE)
@echo "The project has been built in release simulation mode."
+else
+ $(error "Unknown build mode.")
endif
$(sgx_enclave_signer) sign -key $(enclave_signing_key) -enclave $< \
-out $@ -config $(enclave_config_file)
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.