message
stringlengths 6
474
| diff
stringlengths 8
5.22k
|
---|---|
perf-tools/msr-safe: add kernel-rpm-macros requirement for rhel | @@ -40,6 +40,7 @@ BuildRequires: kernel-default-devel
BuildRequires: kernel
BuildRequires: kernel-devel
BuildRequires: kernel-abi-whitelists kernel-rpm-macros elfutils-libelf-devel
+BuildRequires: kernel-rpm-macros
%endif
%kernel_module_package default
|
EV3: Revert make debug output | @@ -280,8 +280,6 @@ libffi:
../configure $(CROSS_COMPILE_HOST) --prefix=$$PWD/out --disable-structs CC="$(CC)" CXX="$(CXX)" LD="$(LD)" CFLAGS="-Os -fomit-frame-pointer -fstrict-aliasing -ffast-math -fno-exceptions"; \
$(MAKE) install-exec-recursive; $(MAKE) -C include install-data-am
-
-$(info $$CC is [${CC}])
axtls: $(BUILD)/libaxtls.a
$(BUILD)/libaxtls.a: $(TOP)/lib/axtls/README | $(OBJ_DIRS)
|
TSCH: define SYNC_IE_BOUND from timing in use rather than default | /* Truncate received drift correction information to maximum half
* of the guard time (one fourth of TSCH_DEFAULT_TS_RX_WAIT) */
-#define SYNC_IE_BOUND ((int32_t)US_TO_RTIMERTICKS(TSCH_DEFAULT_TS_RX_WAIT / 4))
+#define SYNC_IE_BOUND ((int32_t)US_TO_RTIMERTICKS(tsch_timing_us[tsch_ts_rx_wait] / 4))
/* By default: check that rtimer runs at >=32kHz and use a guard time of 10us */
#if RTIMER_SECOND < (32 * 1024)
|
Updated --max-merge to README | @@ -209,6 +209,7 @@ Compression tools:
--(no-)implicit-rdpcm : Implicit residual DPCM. Currently only supported
with lossless coding. [disabled]
--(no-)tmvp : Temporal motion vector prediction [enabled]
+ --max-merge <integer> : Maximum number of merge candidates, 1..5 [5]
Parallel processing:
--threads <integer> : Number of threads to use [auto]
@@ -314,6 +315,7 @@ where the names have been abbreviated to fit the layout in GitHub.
| me-early-termination | sens. | sens. | sens. | sens. | sens. | on | on | off | off | off |
| intra-rdo-et | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
| fast-residual-cost | 28 | 28 | 28 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
+| max-merge | 5 | 5 | 5 | 5 | 5 | 5 | 5 | 5 | 5 | 5 |
## Kvazaar library
|
Fix treeview regression during theme changes | @@ -2104,6 +2104,8 @@ VOID PhTnpUpdateThemeData(
_In_ PPH_TREENEW_CONTEXT Context
)
{
+ Context->DefaultBackColor = GetSysColor(COLOR_WINDOW);
+ Context->DefaultForeColor = GetSysColor(COLOR_WINDOWTEXT);
Context->ThemeActive = !!IsThemeActive();
if (Context->ThemeData)
|
change __uid_t and __gid_t to uid_t and gid_t | @@ -93,8 +93,8 @@ static int validateKey (Key * key, Key * parentKey)
// I assume the path exists and only validate permission
static int validatePermission (Key * key, Key * parentKey)
{
- __uid_t currentUID = geteuid ();
- __gid_t currentGID = getegid ();
+ uid_t currentUID = geteuid ();
+ gid_t currentGID = getegid ();
const Key * userMeta = keyGetMeta (key, "check/permission/user");
const Key * userTypes = keyGetMeta (key, "check/permission/types");
|
explicit cast to remove warning | @@ -176,7 +176,7 @@ static void set_m(AaWork *a, aa_int len) {
r = a->regularization * (nrm_y * nrm_y + nrm_s * nrm_s);
if (a->verbosity > 2) {
printf("iter: %i, len: %i, norm: Y %.2e, norm: S %.2e, r: %.2e\n",
- a->iter, len, nrm_y, nrm_s, r);
+ (int)a->iter, (int)len, nrm_y, nrm_s, r);
}
for (i = 0; i < len; ++i) {
a->M[i + len * i] += r;
|
[brotli] Ensure there's a minimal good buffer size
Make sure that a misconfigured or malicious downstream with a very small
content-length doesn't lead to many allocated buffers.
This also fixes the issue of CL:0 leading to a crash due to memory
exhaustion. | @@ -120,6 +120,8 @@ h2o_compress_context_t *h2o_compress_brotli_open(h2o_mem_pool_t *pool, int quali
self->buf_capacity = estimated_content_length;
if (self->buf_capacity > 65536)
self->buf_capacity = 65536;
+ if (self->buf_capacity < BUFSIZ)
+ self->buf_capacity = BUFSIZ;
expand_buf(self);
BrotliEncoderSetParameter(self->state, BROTLI_PARAM_QUALITY, quality);
|
Add demo use of WASI libc function. | +import std.algorithm: min, max;
import tic80;
extern(C):
+// From WASI libc:
+int snprintf(scope char* s, size_t n, scope const char* format, scope const ...);
+
int t, x, y;
const char* m = "HELLO WORLD FROM D!";
+int r = 0;
+MouseData md;
void BOOT() {
t = 1;
@@ -12,13 +18,30 @@ void BOOT() {
}
void TIC() {
+ cls(13);
+
+ // The standard demo.
if (btn(0) > 0) { y--; }
if (btn(1) > 0) { y++; }
if (btn(2) > 0) { x--; }
if (btn(3) > 0) { x++; }
- cls(13);
spr(1+t%60/30*2, x, y, null, 0, 3, 0, 0, 2, 2);
print(m, 60, 84, 15, 1, 1, 0);
t++;
+
+ // Mouse example demonstrating use of libc function.
+ mouse(&md);
+ if (md.left) { r = r + 2; }
+ r--;
+ r = max(0, min(32, r));
+ line(md.x, 0, md.x, 136, 11);
+ line(0, md.y, 240, md.y, 11);
+ circ(md.x, md.y, r, 11);
+
+ const BUFSIZ = 10;
+ char[BUFSIZ] buf;
+ char* bufptr = cast(char*)buf;
+ snprintf(bufptr, BUFSIZ, "(%03d,%03d)", md.x, md.y);
+ print(bufptr, 3, 3, 15, 0, 1, 1);
}
|
tools: webd - fix more styling issues | @@ -112,7 +112,9 @@ export default function initInstanceRoutes(app) {
if (!instance || !instance.host) {
throw new APIError("Instance not found or invalid (no host)");
}
- return remoteKdb.get(instance.host, { sessionId: getSessionID(instance.id, req.session) });
+ return remoteKdb.get(instance.host, {
+ sessionId: getSessionID(instance.id, req.session)
+ });
})
.then(instanceRes =>
setSessionID(req.params.id, req.session, instanceRes)
|
do not refresh db on dll built | @@ -553,7 +553,7 @@ namespace SLua
Directory.Delete(GenPath, true);
Directory.CreateDirectory(GenPath);
File.Move (WrapperName, GenPath + WrapperName);
- AssetDatabase.Refresh();
+ // AssetDatabase.Refresh();
File.Delete(ArgumentFile);
}
else
|
MPIPL: Clear tags and metadata
Post dump process, kernel sends FREE_PRESERVE_MEMEORY notification
to OPAL. OPAL will clear metadata section and tags. Subsequent
opal_mpipl_query_tag() call will return OPAL_EMPTY.
[oliver: rebased] | @@ -301,6 +301,12 @@ static int64_t opal_mpipl_update(enum opal_mpipl_ops ops,
prlog(PR_NOTICE, "Payload unregistered for MPIPL\n");
break;
case OPAL_MPIPL_FREE_PRESERVED_MEMORY:
+ /* Clear tags */
+ memset(&opal_mpipl_tags, 0, (sizeof(u64) * MAX_OPAL_MPIPL_TAGS));
+ opal_mpipl_max_tags = 0;
+ /* Release memory */
+ free(opal_mpipl_data);
+ opal_mpipl_data = NULL;
/* Clear MDRT table */
memset((void *)MDRT_TABLE_BASE, 0, MDRT_TABLE_SIZE);
/* Set MDRT count to max allocated count */
|
Return null rather than invalid BitmapData | @@ -378,6 +378,8 @@ class BitmapData extends Surface implements IBitmapDrawable
{
var result = new BitmapData(0, 0);
result.nmeHandle = Surface.nme_bitmap_data_load(inFilename, format);
+ if (result.width<1 || result.height<1)
+ return null;
return result;
}
@@ -399,6 +401,8 @@ class BitmapData extends Surface implements IBitmapDrawable
{
var result = new BitmapData(0, 0);
result.nmeLoadFromBytes(inBytes, inRawAlpha);
+ if (result.width<1 || result.height<1)
+ return null;
return result;
}
|
Fix coding style format | @@ -41,7 +41,8 @@ nsFileOpenWithMode(const char *pathname, int flags, mode_t mode, uid_t nsUid, gi
return fd;
}
-int nsFileMkdir(const char *pathname, mode_t mode, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
+int
+nsFileMkdir(const char *pathname, mode_t mode, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
scope_setegid(nsGid);
scope_seteuid(nsUid);
@@ -52,7 +53,8 @@ int nsFileMkdir(const char *pathname, mode_t mode, uid_t nsUid, gid_t nsGid, uid
return res;
}
-int nsFileMksTemp(char *template, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
+int
+nsFileMksTemp(char *template, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
scope_setegid(nsGid);
scope_seteuid(nsUid);
@@ -63,7 +65,8 @@ int nsFileMksTemp(char *template, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gi
return res;
}
-int nsFileRename(const char *oldpath, const char *newpath, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
+int
+nsFileRename(const char *oldpath, const char *newpath, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
scope_setegid(nsGid);
scope_seteuid(nsUid);
@@ -74,7 +77,8 @@ int nsFileRename(const char *oldpath, const char *newpath, uid_t nsUid, gid_t ns
return res;
}
-FILE *nsFileFopen(const char *restrict pathname, const char *restrict mode, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
+FILE *
+nsFileFopen(const char *restrict pathname, const char *restrict mode, uid_t nsUid, gid_t nsGid, uid_t restoreUid, gid_t restoreGid) {
scope_setegid(nsGid);
scope_seteuid(nsUid);
|
components/phy: add IRAM_ATTR attribute to the two APIs used in phy calibration
1. the two APIs used in phy calibration are called in bluetooth baseband ISR, so locate the them in IRAM | @@ -46,12 +46,12 @@ static int s_phy_rf_init_count = 0;
static _lock_t s_phy_rf_init_lock;
-uint32_t phy_enter_critical(void)
+uint32_t IRAM_ATTR phy_enter_critical(void)
{
return portENTER_CRITICAL_NESTED();
}
-void phy_exit_critical(uint32_t level)
+void IRAM_ATTR phy_exit_critical(uint32_t level)
{
portEXIT_CRITICAL_NESTED(level);
}
|
Add IntRange.ContainsNonNegative | @@ -241,6 +241,18 @@ func (x IntRange) ContainsNegative() bool {
return x[1] == nil || x[0].Cmp(x[1]) <= 0
}
+// ContainsNonNegative returns whether x contains at least one non-negative
+// value.
+func (x IntRange) ContainsNonNegative() bool {
+ if x[1] == nil {
+ return true
+ }
+ if x[1].Sign() < 0 {
+ return false
+ }
+ return x[0] == nil || x[0].Cmp(x[1]) <= 0
+}
+
// ContainsPositive returns whether x contains at least one positive value.
func (x IntRange) ContainsPositive() bool {
if x[1] == nil {
@@ -818,7 +830,7 @@ func andBothNonNeg(x IntRange, y IntRange) (z IntRange) {
}
func andOneNegOneNonNeg(neg IntRange, non IntRange) (z IntRange) {
- if neg.Empty() || neg.ContainsZero() || neg.ContainsPositive() || non.Empty() || non.ContainsNegative() {
+ if neg.Empty() || neg.ContainsNonNegative() || non.Empty() || non.ContainsNegative() {
panic("pre-condition failure")
}
|
build CHANGE use -Og instead of -O0 for debug builds | @@ -108,7 +108,7 @@ endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_FLAGS_COVERAGE} -Wall -Wextra -Wno-missing-field-initializers -std=c99")
set(CMAKE_C_FLAGS_RELEASE "-O2 -DNDEBUG")
set(CMAKE_C_FLAGS_PACKAGE "-g -O2 -DNDEBUG")
-set(CMAKE_C_FLAGS_DEBUG "-g -O0")
+set(CMAKE_C_FLAGS_DEBUG "-g -Og")
include_directories(${PROJECT_BINARY_DIR}/src ${PROJECT_SOURCE_DIR}/src)
configure_file(${PROJECT_SOURCE_DIR}/src/config.h.in ${PROJECT_BINARY_DIR}/src/config.h @ONLY)
|
omit_nil fixed for rails mode | @@ -1284,6 +1284,9 @@ hash_cb(VALUE key, VALUE value, Out out) {
long size;
int rtype = rb_type(key);
+ if (out->omit_nil && Qnil == value) {
+ return ST_CONTINUE;
+ }
if (rtype != T_STRING && rtype != T_SYMBOL) {
key = rb_funcall(key, oj_to_s_id, 0);
rtype = rb_type(key);
|
the file description is modified to local variable in function
static void copydir(const char * src, const char * dst) | @@ -568,7 +568,6 @@ void rm(const char *filename)
}
}
FINSH_FUNCTION_EXPORT(rm, remove files or directories);
-
void cat(const char* filename)
{
rt_uint32_t length;
@@ -655,8 +654,8 @@ static void copydir(const char * src, const char * dst)
struct dirent dirent;
struct stat stat;
int length;
-
- if (dfs_file_open(&fd, src, DFS_O_DIRECTORY) < 0)
+ struct dfs_fd cpfd;
+ if (dfs_file_open(&cpfd, src, DFS_O_DIRECTORY) < 0)
{
rt_kprintf("open %s failed\n", src);
return ;
@@ -665,7 +664,7 @@ static void copydir(const char * src, const char * dst)
do
{
rt_memset(&dirent, 0, sizeof(struct dirent));
- length = dfs_file_getdents(&fd, &dirent, sizeof(struct dirent));
+ length = dfs_file_getdents(&cpfd, &dirent, sizeof(struct dirent));
if (length > 0)
{
char * src_entry_full = RT_NULL;
@@ -708,7 +707,7 @@ static void copydir(const char * src, const char * dst)
}
}while(length > 0);
- dfs_file_close(&fd);
+ dfs_file_close(&cpfd);
}
static const char *_get_path_lastname(const char *path)
|
4. use explicit nock %9 formulas for gate calls in %velo | => ?: =(nex hoon-version)
[hot=`*`raw .]
~& [%hoon-compile-upgrade nex]
- =/ hot .*(cop(+< [%noun hun]) -.cop)
+ =/ hot
+ .*(cop [%9 2 %10 [6 %1 [%noun hun]] %0 1])
.(cop .*(0 +.hot))
:: extract the hoon core from the outer gate (+ride)
::
=/ hoc .*(cop [%0 7])
- :: compute the span of the hoon.hoon core
+ :: compute the type of the hoon.hoon core
::
- =/ hyp -:.*(cop(+< [-.hot '+>']) -.cop)
+ =/ hyp
+ -:.*(cop [%9 2 %10 [6 %1 [-.hot '+>']] %0 1])
:: compile arvo
::
=/ rav
~& [%compile-arvo `@p`(mug hyp) `@p`(mug van)]
- .*(cop(+< [hyp van]) -.cop)
- :: activate arvo
+ .*(cop [%9 2 %10 [6 %1 [hyp van]] %0 1])
+ :: activate arvo, and extract the arvo core from the outer gate
::
- =/ arv .*(hoc +.rav)
- :: extract the arvo core from the outer gate
- ::
- =/ voc .*(arv [%0 7])
- :: compute the span of the arvo.hoon core
- ::
- =/ vip -:.*(cop(+< [-.rav '+>']) -.cop)
+ =/ voc .*(hoc [%7 +.rav %0 7])
:: entry gate: ++load for the normal case, ++come for upgrade
::
=/ gat
- .*(voc +:.*(cop(+< [vip ?:(=(nex hoon-version) 'load' 'come')]) -.cop))
+ =/ arm ?:(=(nex hoon-version) 'load' 'come')
+ :: compute the type of the arvo.hoon core
+ ::
+ =/ vip -:.*(cop [%9 2 %10 [6 %1 [-.rav '+>']] %0 1])
+ :: compute the formula for the upgrade gate
+ ::
+ =/ fol +:.*(cop [%9 2 %10 [6 %1 [vip arm]] %0 1])
+ :: produce the upgrade gate
+ ::
+ .*(voc fol)
:: sample: [entropy actions vases]
::
=/ sam
(turn vanes |=([label=@tas =vane] [label vase.vane]))
:: call into the new kernel
::
- =/ out .*(gat(+< sam) -.gat)
+ =/ out
+ .*(gat [%9 2 %10 [6 %1 sam] %0 1])
:: tack a reset notification onto the product
::
[[[~ %vega ~] ((list ovum) -.out)] +.out]
|
interop: Fix ngtcp2 branch | @@ -11,7 +11,7 @@ RUN apt-get update && \
cd nghttp3 && autoreconf -i && \
./configure --enable-lib-only && \
make -j$(nproc) && make install-strip && cd .. && rm -rf nghttp3 && \
- git clone --depth 1 -b interop https://github.com/ngtcp2/ngtcp2 && \
+ git clone --depth 1 https://github.com/ngtcp2/ngtcp2 && \
cd ngtcp2 && autoreconf -i && \
./configure && \
make -j$(nproc) && make install-strip && cp examples/server examples/client /usr/local/bin && cd .. && rm -rf ngtcp2 && \
|
Bypass multiblock and send individual records when using KTLS. | @@ -426,6 +426,7 @@ int ssl3_write_bytes(SSL *s, int type, const void *buf_, size_t len,
len >= 4 * (max_send_fragment = ssl_get_max_send_fragment(s)) &&
s->compress == NULL && s->msg_callback == NULL &&
!SSL_WRITE_ETM(s) && SSL_USE_EXPLICIT_IV(s) &&
+ (BIO_get_ktls_send(s->wbio) == 0) &&
EVP_CIPHER_flags(EVP_CIPHER_CTX_cipher(s->enc_write_ctx)) &
EVP_CIPH_FLAG_TLS1_1_MULTIBLOCK) {
unsigned char aad[13];
|
udp: Ipv4/6 can be bound to the same port | @@ -124,7 +124,7 @@ static FAR struct udp_conn_s *udp_find_conn(uint8_t domain,
if (domain == PF_INET)
#endif
{
- if (conn->lport == portno &&
+ if (conn->domain == PF_INET && conn->lport == portno &&
(net_ipv4addr_cmp(conn->u.ipv4.laddr, ipaddr->ipv4.laddr) ||
net_ipv4addr_cmp(conn->u.ipv4.laddr, INADDR_ANY)))
{
@@ -138,7 +138,7 @@ static FAR struct udp_conn_s *udp_find_conn(uint8_t domain,
else
#endif
{
- if (conn->lport == portno &&
+ if (conn->domain == PF_INET6 && conn->lport == portno &&
(net_ipv6addr_cmp(conn->u.ipv6.laddr, ipaddr->ipv6.laddr) ||
net_ipv6addr_cmp(conn->u.ipv6.laddr, g_ipv6_unspecaddr)))
{
|
Build: Fix change directory warning during compilation | @@ -73,7 +73,8 @@ if [ "$BUILD_UTILITIES" = "1" ]; then
make || exit 1
cd - || exit 1
done
+ cd .. || exit 1
fi
-cd ../Library/OcConfigurationLib || exit 1
+cd Library/OcConfigurationLib || exit 1
./CheckSchema.py OcConfigurationLib.c || exit 1
|
Yan LR: Only generate parse tree listeners | @@ -20,7 +20,7 @@ if (DEPENDENCY_PHASE)
set (GRAMMAR_NAME YAML)
set (GRAMMAR_FILE ${CMAKE_CURRENT_SOURCE_DIR}/${GRAMMAR_NAME}.g4)
- set (GENERATED_SOURCE_FILES_NAMES Lexer Parser BaseListener BaseVisitor Listener Visitor)
+ set (GENERATED_SOURCE_FILES_NAMES Lexer Parser BaseListener Listener)
foreach (file ${GENERATED_SOURCE_FILES_NAMES})
set (filepath ${CMAKE_CURRENT_BINARY_DIR}/${GRAMMAR_NAME}${file}.cpp)
set_source_files_properties (${filepath} PROPERTIES GENERATED TRUE)
@@ -30,7 +30,7 @@ if (DEPENDENCY_PHASE)
add_custom_command (
OUTPUT ${GENERATED_SOURCE_FILES}
- COMMAND antlr4 -Werror -Dlanguage=Cpp -listener -visitor -o ${CMAKE_CURRENT_BINARY_DIR} -package antlr ${GRAMMAR_FILE}
+ COMMAND antlr4 -Werror -Dlanguage=Cpp -o ${CMAKE_CURRENT_BINARY_DIR} -package antlr ${GRAMMAR_FILE}
DEPENDS ${GRAMMAR_FILE}
)
endif (DEPENDENCY_PHASE)
|
sysdeps/managarm: Convert sys_mkfifoat to bragi | @@ -3250,40 +3250,28 @@ int sys_openat(int dirfd, const char *path, int flags, int *fd) {
int sys_mkfifoat(int dirfd, const char *path, mode_t mode) {
SignalGuard sguard;
- HelAction actions[3];
-
- globalQueue.trim();
- managarm::posix::CntRequest<MemoryAllocator> req(getSysdepsAllocator());
- req.set_request_type(managarm::posix::CntReqType::MKFIFOAT);
+ managarm::posix::MkfifoAtRequest<MemoryAllocator> req(getSysdepsAllocator());
req.set_fd(dirfd);
req.set_path(frg::string<MemoryAllocator>(getSysdepsAllocator(), path));
req.set_mode(mode);
- frg::string<MemoryAllocator> ser(getSysdepsAllocator());
- req.SerializeToString(&ser);
- actions[0].type = kHelActionOffer;
- actions[0].flags = kHelItemAncillary;
- actions[1].type = kHelActionSendFromBuffer;
- actions[1].flags = kHelItemChain;
- actions[1].buffer = ser.data();
- actions[1].length = ser.size();
- actions[2].type = kHelActionRecvInline;
- actions[2].flags = 0;
- HEL_CHECK(helSubmitAsync(getPosixLane(), actions, 3,
- globalQueue.getQueue(), 0, 0));
-
- auto element = globalQueue.dequeueSingle();
- auto offer = parseSimple(element);
- auto send_req = parseSimple(element);
- auto recv_resp = parseInline(element);
+ auto [offer, send_head, send_tail, recv_resp] =
+ exchangeMsgsSync(
+ getPosixLane(),
+ helix_ng::offer(
+ helix_ng::sendBragiHeadTail(req, getSysdepsAllocator()),
+ helix_ng::recvInline()
+ )
+ );
- HEL_CHECK(offer->error);
- HEL_CHECK(send_req->error);
- HEL_CHECK(recv_resp->error);
+ HEL_CHECK(offer.error());
+ HEL_CHECK(send_head.error());
+ HEL_CHECK(send_tail.error());
+ HEL_CHECK(recv_resp.error());
managarm::posix::SvrResponse<MemoryAllocator> resp(getSysdepsAllocator());
- resp.ParseFromArray(recv_resp->data, recv_resp->length);
+ resp.ParseFromArray(recv_resp.data(), recv_resp.length());
if(resp.error() == managarm::posix::Errors::FILE_NOT_FOUND) {
return ENOENT;
}else if(resp.error() == managarm::posix::Errors::ALREADY_EXISTS) {
|
zephyr test: Clear SYV682x interrupts after test
Clear interrupt-generating conditions in STATUS and CONTROL_4 after each
test.
TEST=zmake testall
BRANCH=none | @@ -38,6 +38,9 @@ static void syv682x_test_after(void *data)
ARG_UNUSED(data);
+ syv682x_emul_set_condition(emul, SYV682X_STATUS_NONE,
+ SYV682X_CONTROL_4_NONE);
+
/* Clear the mock read/write functions */
i2c_common_emul_set_read_func(emul, NULL, NULL);
i2c_common_emul_set_write_func(emul, NULL, NULL);
|
accidentally pushed cmake comment | @@ -1423,7 +1423,7 @@ IF(NOT VISIT_BUILD_MINIMAL_PLUGINS OR VISIT_SELECTED_DATABASE_PLUGINS)
INCLUDE(${VISIT_SOURCE_DIR}/CMake/FindMDSplus.cmake)
# Configure Uintah support.
- #INCLUDE(${VISIT_SOURCE_DIR}/CMake/FindUintah.cmake)
+ INCLUDE(${VISIT_SOURCE_DIR}/CMake/FindUintah.cmake)
# Configure PIDX support.
INCLUDE(${VISIT_SOURCE_DIR}/CMake/FindPIDX.cmake)
|
Fix clipboard paste condition
To avoid possible copy-paste loops between the computer and the device,
the device clipboard is not set if it already contains the expected
content.
But the condition was wrong: it was not set also if it was empty.
Refs
Fixes <https://github.com/Genymobile/scrcpy/issues/1658> | @@ -223,7 +223,7 @@ public final class Device {
}
String currentClipboard = getClipboardText();
- if (currentClipboard == null || currentClipboard.equals(text)) {
+ if (currentClipboard != null && currentClipboard.equals(text)) {
// The clipboard already contains the requested text.
// Since pasting text from the computer involves setting the device clipboard, it could be set twice on a copy-paste. This would cause
// the clipboard listeners to be notified twice, and that would flood the Android keyboard clipboard history. To workaround this
|
Notify users when gphdfs tables exist during the upgrade process | @@ -21,6 +21,7 @@ static void check_covering_aoindex(void);
static void check_partition_indexes(void);
static void check_orphaned_toastrels(void);
static void check_online_expansion(void);
+static void check_gphdfs_external_tables(void);
/*
* check_greenplum
@@ -38,6 +39,7 @@ check_greenplum(void)
check_covering_aoindex();
check_partition_indexes();
check_orphaned_toastrels();
+ check_gphdfs_external_tables();
}
/*
@@ -456,3 +458,76 @@ check_partition_indexes(void)
else
check_ok();
}
+
+/*
+ * check_gphdfs_external_tables
+ *
+ * Check if there are any remaining gphdfs external tables in the database.
+ * We error if any gphdfs external tables remain and let the users know that,
+ * any remaining gphdfs external tables have to be removed.
+ */
+static void
+check_gphdfs_external_tables(void)
+{
+ char output_path[MAXPGPATH];
+ FILE *script = NULL;
+ bool found = false;
+ int dbnum;
+
+ prep_status("Checking for gphdfs external tables");
+
+ snprintf(output_path, sizeof(output_path), "gphdfs_external_tables.txt");
+
+
+ for (dbnum = 0; dbnum < old_cluster.dbarr.ndbs; dbnum++)
+ {
+ PGresult *res;
+ int ntups;
+ int rowno;
+ DbInfo *active_db = &old_cluster.dbarr.dbs[dbnum];
+ PGconn *conn;
+
+ conn = connectToServer(&old_cluster, active_db->db_name);
+ res = executeQueryOrDie(conn,
+ "SELECT d.objid::regclass as tablename "
+ "FROM pg_catalog.pg_depend d "
+ " JOIN pg_catalog.pg_exttable x ON ( d.objid = x.reloid ) "
+ " JOIN pg_catalog.pg_extprotocol p ON ( p.oid = d.refobjid ) "
+ " JOIN pg_catalog.pg_class c ON ( c.oid = d.objid ) "
+ " WHERE d.refclassid = 'pg_extprotocol'::regclass "
+ " AND p.ptcname = 'gphdfs';");
+
+ ntups = PQntuples(res);
+
+ if (ntups > 0)
+ {
+ found = true;
+
+ if (script == NULL && (script = fopen(output_path, "w")) == NULL)
+ pg_log(PG_FATAL, "Could not create necessary file: %s\n",
+ output_path);
+
+ for (rowno = 0; rowno < ntups; rowno++)
+ {
+ fprintf(script, "gphdfs external table \"%s\" in database \"%s\"\n",
+ PQgetvalue(res, rowno, PQfnumber(res, "tablename")),
+ active_db->db_name);
+ }
+ }
+
+ PQclear(res);
+ PQfinish(conn);
+ }
+ if (found)
+ {
+ fclose(script);
+ pg_log(PG_REPORT, "fatal\n");
+ pg_log(PG_FATAL,
+ "| Your installation contains gphdfs external tables. These \n"
+ "| tables need to be dropped before upgrade. A list of\n"
+ "| external gphdfs tables to remove is provided in the file:\n"
+ "| \t%s\n\n", output_path);
+ }
+ else
+ check_ok();
+}
|
Resolve Codacy-detected issues. | @@ -2739,7 +2739,7 @@ test_wifi_join_cb(
if (!ssid || !*ssid || !psk)
{
- fprintf(stderr, "test_wifi_join_cb: Bad SSID '%s' or PSK '%s'.\n", ssid, psk);
+ fprintf(stderr, "test_wifi_join_cb: Bad SSID '%s' or PSK '%s'.\n", ssid ? ssid : "(null)", psk ? psk : "(null)");
return (false);
}
|
Catch exception when accessing Application::Current in WindowsRTPlatformEventHandler deconstructor like in the constructor as both have the same risk of throwing the exception | @@ -62,6 +62,8 @@ namespace Microsoft {
}
PlatformEventHandler::~PlatformEventHandler()
+ {
+ try
{
if (this->m_suspendToken.Value != 0)
{
@@ -78,6 +80,11 @@ namespace Microsoft {
Application::Current->UnhandledException -= this->m_unhandledExceptionToken;
}
}
+ catch (Exception^ e)
+ {
+ // Access to Application::Current can generate COM exceptions.
+ }
+ }
void PlatformEventHandler::OnSuspending(Object ^ sender, SuspendingEventArgs^ e)
{
|
todo: removed finished task | @@ -96,13 +96,6 @@ many globbing statements
== DATA STRUCTURES ==
-Implement order preserving perfect hashing functions
- O(1) lookup, but keep O(n) ordered iteration
- http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.51.5566&rep=rep1&type=pdf
- ksLookup(,, KDB_O_HASH) or KDB_O_HASH_HEURISTIC to avoid
- rebuilding on seldom lookups
- if hash is available it will be used regardless of options
-
improve memory footprint C structures:
http://www.catb.org/esr/structure-packing/?src=yc
|
Updated deb packaging to upload artifacts. | @@ -63,10 +63,18 @@ jobs:
sudo wget https://deb.goaccess.io/provision/provision.sh
sudo chmod +x ./provision.sh
sudo ./provision.sh
+ sudo ls -lath "/tmp"
echo "Success!!"
- name: Show the artifact
# Items placed in /artifacts in the container will be in
# ${PWD}/artifacts on the host.
run: |
- ls -al "${PWD}/artifacts"
+ ls -lath "${PWD}/artifacts"
+
+ - name: 'Upload deb package'
+ uses: actions/upload-artifact@v3
+ with:
+ name: deb-package
+ path: "${PWD}/artifacts/*.deb"
+ retention-days: 1
|
Tests: waitforfiles function introduced. | @@ -29,12 +29,9 @@ class TestUnit(unittest.TestCase):
'--log', self.testdir + '/unit.log',
'--control', 'unix:' + self.testdir + '/control.unit.sock'])
- time_wait = 0
- while time_wait < 5 and not (os.path.exists(self.testdir + '/unit.pid')
- and os.path.exists(self.testdir + '/unit.log')
- and os.path.exists(self.testdir + '/control.unit.sock')):
- time.sleep(0.1)
- time_wait += 0.1
+ if not self._waitforfiles([self.testdir + '/unit.pid',
+ self.testdir + '/unit.log', self.testdir + '/control.unit.sock']):
+ exit("Could not start unit")
# TODO dependency check
@@ -44,10 +41,13 @@ class TestUnit(unittest.TestCase):
subprocess.call(['kill', pid])
- time_wait = 0
- while time_wait < 5 and os.path.exists(self.testdir + '/unit.pid'):
+ for i in range(1, 50):
+ if not os.path.exists(self.testdir + '/unit.pid'):
+ break
time.sleep(0.1)
- time_wait += 0.1
+
+ if os.path.exists(self.testdir + '/unit.pid'):
+ exit("Could not terminate unit")
if '--log' in sys.argv:
with open(self.testdir + '/unit.log', 'r') as f:
@@ -56,6 +56,24 @@ class TestUnit(unittest.TestCase):
if '--leave' not in sys.argv:
shutil.rmtree(self.testdir)
+ def _waitforfiles(self, files):
+ if isinstance(files, str):
+ files = [files]
+
+ count = 0
+ for i in range(1, 50):
+ for f in files:
+ if os.path.exists(f):
+ count += 1
+
+ if count == len(files):
+ return 1
+
+ count = 0
+ time.sleep(0.1)
+
+ return 0
+
class TestUnitControl(TestUnit):
# TODO socket reuse
|
Fix stack corruption caught by address sanitizer | @@ -959,6 +959,7 @@ static bool RunExternalTool(const char* options, ...)
const char* cmdline_to_use;
char option_str[1024];
+ char cmdline[1024];
va_list args;
va_start(args, options);
vsnprintf(option_str, sizeof option_str, options, args);
@@ -979,7 +980,6 @@ static bool RunExternalTool(const char* options, ...)
if (strchr(dag_gen_path, ' '))
quotes = "\"";
- char cmdline[1024];
snprintf(cmdline, sizeof cmdline, "%s%s%s %s", quotes, dag_gen_path, quotes, option_str);
cmdline[sizeof(cmdline)-1] = '\0';
|
out_influxdb: escape special characters in kv | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <ctype.h>
#include <fluent-bit.h>
+#include "influxdb.h"
#include "influxdb_bulk.h"
static const uint64_t ONE_BILLION = 1000000000;
+static int influxdb_escape(char *out, const char *str, int size) {
+ int out_size = 0;
+ int i;
+ for (i = 0; i < size; ++i) {
+ char ch = str[i];
+ if (isspace(ch) || ch == ',' || ch == '=' || ch == '"') {
+ out[out_size++] = '\\';
+ }
+ out[out_size++] = ch;
+ }
+ return out_size;
+}
+
static int influxdb_bulk_buffer(struct influxdb_bulk *bulk, int required)
{
int new_size;
@@ -124,7 +139,8 @@ int influxdb_bulk_append_kv(struct influxdb_bulk *bulk,
int ret;
int required;
- required = k_len + 1 + v_len + 1 + 1;
+ /* Reserve double space for keys and values in case of escaping */
+ required = k_len * 2 + 1 + v_len * 2 + 1 + 1;
if (quote) {
required += 2;
}
@@ -141,8 +157,7 @@ int influxdb_bulk_append_kv(struct influxdb_bulk *bulk,
}
/* key */
- memcpy(bulk->ptr + bulk->len, key, k_len);
- bulk->len += k_len;
+ bulk->len += influxdb_escape(bulk->ptr + bulk->len, key, k_len);
/* separator */
bulk->ptr[bulk->len] = '=';
@@ -153,8 +168,7 @@ int influxdb_bulk_append_kv(struct influxdb_bulk *bulk,
bulk->ptr[bulk->len] = '"';
bulk->len++;
}
- memcpy(bulk->ptr + bulk->len, val, v_len);
- bulk->len += v_len;
+ bulk->len += influxdb_escape(bulk->ptr + bulk->len, val, v_len);
if (quote) {
bulk->ptr[bulk->len] = '"';
bulk->len++;
|
fixed petsc typo | @@ -314,7 +314,7 @@ function build_uintah
$ZLIB_ARGS \
--prefix=\"$VISITDIR/uintah/$UINTAH_VERSION/$VISITARCH\" \
${cf_build_type} \
- --enable-optimize --without-petc --without-hypre" \
+ --enable-optimize --without-petsc --without-hypre" \
$ZLIBARGS
sh -c "../src/configure CXX=\"$PAR_COMPILER_CXX\" CC=\"$PAR_COMPILER\" \
@@ -324,7 +324,7 @@ function build_uintah
$ZLIB_ARGS \
--prefix=\"$VISITDIR/uintah/$UINTAH_VERSION/$VISITARCH\" \
${cf_build_type} \
- --enable-optimize --without-petc --without-hypre" \
+ --enable-optimize --without-petsc --without-hypre" \
$ZLIBARGS
fi
|
publish: new.js uses spinner and disables button | @@ -15,6 +15,7 @@ export class NewScreen extends Component {
groups: [],
ships: []
},
+ disabled: false,
createGroup: false,
awaiting: false,
};
@@ -29,6 +30,7 @@ export class NewScreen extends Component {
const { props, state } = this;
if (props.notebooks && (("~" + window.ship) in props.notebooks)) {
if (state.awaiting in props.notebooks["~" + window.ship]) {
+ props.api.setSpinner(false);
let notebook = `/~${window.ship}/${state.awaiting}`;
props.history.push("/~publish/notebook" + notebook);
}
@@ -92,7 +94,8 @@ export class NewScreen extends Component {
}
}
- this.setState({awaiting: bookId}, () => {
+ this.setState({awaiting: bookId, disabled: true}, () => {
+ props.api.setSpinner(true);
props.api.action("publish", "publish-action", action);
});
}
@@ -103,7 +106,7 @@ export class NewScreen extends Component {
: "relative bg-gray4 bg-gray1-d br3 h1 toggle v-mid z-0";
let createClasses = "pointer db f9 green2 bg-gray0-d ba pv3 ph4 mv7 b--green2";
- if (!this.state.idName) {
+ if (!this.state.idName || this.state.disabled) {
createClasses = "pointer db f9 gray2 ba bg-gray0-d pa2 pv3 ph4 mv7 b--gray3";
}
@@ -187,6 +190,7 @@ export class NewScreen extends Component {
/>
{createGroupToggle}
<button
+ disabled={this.state.disabled}
onClick={this.onClickCreate.bind(this)}
className={createClasses}>
Create Notebook
|
Ensure module index is reset on each iteration. | @@ -2517,6 +2517,7 @@ clean_partial_match_hashes (int date) {
if (*p != '|')
continue;
+ idx = 0;
FOREACH_MODULE (idx, module_list) {
module = module_list[idx];
free_partial_match_uniqmap (module, kh_value (hash, k));
|
Controller:getHand for WebVR; | @@ -184,7 +184,12 @@ int lovrHeadsetControllerIsPresent(Controller* controller) {
}
ControllerHand lovrHeadsetControllerGetHand(Controller* controller) {
- return HAND_UNKNOWN;
+ switch (emscripten_vr_controller_get_hand(controller->id)) {
+ case 0: return HAND_UNKNOWN;
+ case 1: return HAND_LEFT;
+ case 2: return HAND_RIGHT;
+ default: return HAND_UNKNOWN;
+ }
}
void lovrHeadsetControllerGetPosition(Controller* controller, float* x, float* y, float* z) {
|
Fix Coverity & uninitialised read | @@ -2232,6 +2232,7 @@ int SSL_shutdown(SSL *s)
if ((s->mode & SSL_MODE_ASYNC) && ASYNC_get_current_job() == NULL) {
struct ssl_async_args args;
+ memset(&args, 0, sizeof(args));
args.s = s;
args.type = OTHERFUNC;
args.f.func_other = s->method->ssl_shutdown;
@@ -3914,6 +3915,7 @@ int SSL_do_handshake(SSL *s)
if ((s->mode & SSL_MODE_ASYNC) && ASYNC_get_current_job() == NULL) {
struct ssl_async_args args;
+ memset(&args, 0, sizeof(args));
args.s = s;
ret = ssl_start_async_job(s, &args, ssl_do_handshake_intern);
|
Ensure we require a valid host token even when we're not validating the IP. | @@ -948,6 +948,13 @@ parse_specifier (GLogItem * logitem, char **str, const char *p, const char *end)
free (tkn);
return 1;
}
+ /* require a valid host token (e.g., ord38s18-in-f14.1e100.net) even when we're
+ * not validating the IP */
+ if (conf.no_ip_validation && *tkn == '\0') {
+ spec_err (logitem, SPEC_TOKN_INV, *p, tkn);
+ free (tkn);
+ return 1;
+ }
logitem->host = tkn;
break;
/* request method */
|
comboview config | @@ -9,13 +9,13 @@ static const int systraypinningfailfirst = 1; /* 1: if pinning fails, display sy
static const int showsystray = 1; /* 0 means no systray */
static const int showbar = 1; /* 0 means no bar */
static const int topbar = 1; /* 0 means bottom bar */
-static const char *fonts[] = {"Monaco-Nerd-Font-Complete-Mono:size=12"};
-static const char dmenufont[] = "Monaco-Nerd-Font-Complete-Mono:size=12";
-static const char col_gray1[] = "#282a36"; /* top bar d */
-static const char col_gray2[] = "#bd93f9";/*unfocused fonts d */
-static const char col_gray3[] = "#6272a4";/*unfocused border d */
-static const char col_gray4[] = "#8be9fd";/*focused fonts d */
-static const char col_gray5[] = "#50fa7b";/*focused windows d */
+static const char *fonts[] = {"SF-Mono-Bold:size=12"};
+static const char dmenufont[] = "SF-Mono-Bold:size=12";
+static const char col_gray1[] = "#fafafa"; /* top bar d */
+static const char col_gray2[] = "#4c4c4c";/*unfocused fonts d */
+static const char col_gray3[] = "#8e8e93";/*unfocused border d */
+static const char col_gray4[] = "#fafafa";/*focused fonts d */
+static const char col_gray5[] = "#28CD41";/*focused windows d */
static const char col_cyan[] = "#007aff";/*focused dmenu or topbar d */
static const char *colors[][3] = {
/* fg bg border */
@@ -64,9 +64,9 @@ static const Layout layouts[] = {
/* key definitions */
#define MODKEY Mod4Mask
#define TAGKEYS(KEY, TAG) \
- {MODKEY, KEY, view, {.ui = 1 << TAG}}, \
+ {MODKEY, KEY, comboview, {.ui = 1 << TAG}}, \
{MODKEY | ControlMask, KEY, toggleview, {.ui = 1 << TAG}}, \
- {MODKEY | ShiftMask, KEY, tag, {.ui = 1 << TAG}}, \
+ {MODKEY | ShiftMask, KEY, combotag, {.ui = 1 << TAG}}, \
{MODKEY | ControlMask | ShiftMask, KEY, toggletag, {.ui = 1 << TAG}},
/* helper for spawning shell commands in the pre dwm-5.0 fashion */
|
doc: Add example to OPAL_CEC_POWER_DOWN | @@ -9,6 +9,24 @@ OPAL_CEC_POWER_DOWN
int64 opal_cec_power_down(uint64 request)
+As powering down the system is likely an asynchronous operation that we
+have to wait for a service processor to do, :ref:`OPAL_CEC_POWER_DOWN`
+should be called like the example code below:
+
+.. code-block:: c
+
+ int rc = OPAL_BUSY;
+
+ do {
+ rc = opal_cec_power_down(0);
+ if (rc == OPAL_BUSY_EVENT)
+ opal_poll_events(NULL);
+ } while (rc == OPAL_BUSY || rc == OPAL_BUSY_EVENT);
+
+ for (;;)
+ opal_poll_events(NULL);
+
+
Arguments
---------
|
Fixed some smaller issues in homebridge script | @@ -189,7 +189,7 @@ function checkHomebridge {
systemctl disable homebridge
fi
pkill homebridge
-
+ sleep 5
rm -rf /home/$MAINUSER/.homebridge/persist
fi
@@ -393,7 +393,7 @@ function checkHomebridge {
# config created by deCONZ - check if apikey is still correct
if [ -z "$(cat /home/$MAINUSER/.homebridge/config.json | grep "$APIKEY")" ]; then
# apikey not found - update config
- sed -i '/\"${BRIDGEID}\":/c\ \"${BRIDGEID}\": \"$APIKEY\"' /home/$MAINUSER/.homebridge/config.json
+ sed -i "/\"${BRIDGEID}\":/c\ \"${BRIDGEID}\": \"$APIKEY\"" /home/$MAINUSER/.homebridge/config.json
fi
fi
else
|
Fighting the static analyzer, takes 3 | @@ -1716,6 +1716,13 @@ int picoquic_prepare_packet_server_init(picoquic_cnx_t* cnx, picoquic_path_t * p
uint8_t* bytes = packet->bytes;
uint32_t length = 0;
+ /* The only purpose of the test below is to appease the static analyzer, so it
+ * wont complain of possible NULL deref. On windows we could use "__assume(path_x != NULL)"
+ * but the documentation does not say anything about that for GCC and CLANG */
+ if (path_x == NULL) {
+ return PICOQUIC_ERROR_UNEXPECTED_ERROR;
+ }
+
if (cnx->crypto_context[2].aead_encrypt != NULL &&
cnx->tls_stream[0].send_queue == NULL) {
epoch = 2;
@@ -1723,10 +1730,6 @@ int picoquic_prepare_packet_server_init(picoquic_cnx_t* cnx, picoquic_path_t * p
packet_type = picoquic_packet_handshake;
}
- if (path_x == NULL) {
- path_x = cnx->path[0];
- }
-
send_buffer_max = (send_buffer_max > path_x->send_mtu) ? path_x->send_mtu : send_buffer_max;
@@ -1889,8 +1892,11 @@ int picoquic_prepare_packet_closing(picoquic_cnx_t* cnx, picoquic_path_t * path_
uint32_t length = 0;
picoquic_packet_context_enum pc = picoquic_packet_context_application;
+ /* The only purpose of the test below is to appease the static analyzer, so it
+ * wont complain of possible NULL deref. On windows we could use "__assume(path_x != NULL)"
+ * but the documentation does not say anything about that for GCC and CLANG */
if (path_x == NULL) {
- path_x = cnx->path[0];
+ return PICOQUIC_ERROR_UNEXPECTED_ERROR;
}
send_buffer_max = (send_buffer_max > path_x->send_mtu) ? path_x->send_mtu : send_buffer_max;
|
Pkgs set dflt eventq in init function.
X-Original-Commit: | @@ -110,7 +110,6 @@ STATS_NAME_END(ble_hs_stats)
static struct os_eventq *
ble_hs_evq_get(void)
{
- os_eventq_ensure(&ble_hs_evq, &ble_hs_ev_start);
return ble_hs_evq;
}
@@ -609,4 +608,6 @@ ble_hs_init(void)
/* Configure the HCI transport to communicate with a host. */
ble_hci_trans_cfg_hs(ble_hs_hci_rx_evt, NULL, ble_hs_rx_data, NULL);
+
+ ble_hs_evq_set(os_eventq_dflt_get());
}
|
Increase stack size for Xilinx Shadow demo | #define democonfigNETWORK_TYPES ( AWSIOT_NETWORK_TYPE_ETH )
#define democonfigSHADOW_DEMO_NUM_TASKS ( 2 )
-#define democonfigSHADOW_DEMO_TASK_STACK_SIZE ( configMINIMAL_STACK_SIZE * 4 )
+#define democonfigSHADOW_DEMO_TASK_STACK_SIZE ( 1024 )
#define democonfigSHADOW_DEMO_TASK_PRIORITY ( tskIDLE_PRIORITY )
#define shadowDemoUPDATE_TASK_STACK_SIZE ( configMINIMAL_STACK_SIZE * 5 )
|
plugin: fix static builds after removing module name form ELEKTRA_PLUGIN_EXPORT | #include <string.h>
#ifdef ELEKTRA_STATIC
-#ifdef ELEKTRA_VARIANT
-#define ELEKTRA_PLUGIN_EXPORT ELEKTRA_PLUGIN_EXPORT2 (ELEKTRA_PLUGIN_NAME_C, ELEKTRA_VARIANT)
-#define ELEKTRA_PLUGIN_EXPORT2(module, variant) ELEKTRA_PLUGIN_EXPORT3 (module, variant)
-#define ELEKTRA_PLUGIN_EXPORT3(module, variant) libelektra_##module##_##variant##_LTX_elektraPluginSymbol (void)
-#else
#define ELEKTRA_PLUGIN_EXPORT ELEKTRA_PLUGIN_EXPORT2 (ELEKTRA_PLUGIN_NAME_C)
#define ELEKTRA_PLUGIN_EXPORT2(module) ELEKTRA_PLUGIN_EXPORT3 (module)
#define ELEKTRA_PLUGIN_EXPORT3(module) libelektra_##module##_LTX_elektraPluginSymbol (void)
-#endif
#else
#define ELEKTRA_PLUGIN_EXPORT elektraPluginSymbol (void)
#endif
|
AVX: add native calls for _mm256_insertf128_{pd,ps,si256} | @@ -3613,6 +3613,9 @@ simde__m256d simde_mm256_insertf128_pd(simde__m256d a, simde__m128d b, int imm8)
return simde__m256d_from_private(a_);
}
+#if defined(SIMDE_X86_AVX_NATIVE)
+ #define simde_mm256_insertf128_pd(a, b, imm8) _mm256_insertf128_pd(a, b, imm8)
+#endif
#if defined(SIMDE_X86_AVX_ENABLE_NATIVE_ALIASES)
#undef _mm256_insertf128_pd
#define _mm256_insertf128_pd(a, b, imm8) simde_mm256_insertf128_pd(a, b, imm8)
@@ -3628,6 +3631,9 @@ simde__m256 simde_mm256_insertf128_ps(simde__m256 a, simde__m128 b, int imm8)
return simde__m256_from_private(a_);
}
+#if defined(SIMDE_X86_AVX_NATIVE)
+ #define simde_mm256_insertf128_ps(a, b, imm8) _mm256_insertf128_ps(a, b, imm8)
+#endif
#if defined(SIMDE_X86_AVX_ENABLE_NATIVE_ALIASES)
#undef _mm256_insertf128_ps
#define _mm256_insertf128_ps(a, b, imm8) simde_mm256_insertf128_ps(a, b, imm8)
@@ -3643,6 +3649,9 @@ simde__m256i simde_mm256_insertf128_si256(simde__m256i a, simde__m128i b, int im
return simde__m256i_from_private(a_);
}
+#if defined(SIMDE_X86_AVX_NATIVE)
+ #define simde_mm256_insertf128_si256(a, b, imm8) _mm256_insertf128_si256(a, b, imm8)
+#endif
#if defined(SIMDE_X86_AVX_ENABLE_NATIVE_ALIASES)
#undef _mm256_insertf128_si256
#define _mm256_insertf128_si256(a, b, imm8) simde_mm256_insertf128_si256(a, b, imm8)
|
[update] ci test. | @@ -38,7 +38,7 @@ For more details about this board, please refer to the ST official documentation
Each peripheral supporting condition for this BSP is as follows:
| On-board Peripheral | **Support** | **Remark** |
-| :----------------------------- | :---------: | :-----------------: |
+| :----------------------------- | :---------: | :----------------: |
| USB TO UART | YES | |
| PWR | YES | |
| RCC | YES | |
@@ -52,7 +52,7 @@ Each peripheral supporting condition for this BSP is as follows:
| SPI | YES | |
| TIM | YES | |
| LPTIM | YES | |
-| I2C | YES | Software & Hardware |
+| I2C | YES | Software |
| ADC | YES | |
| DAC | YES | |
| WWDG | YES | |
|
make %swap-files poke use file-ovum properly | :: OR
:: :aqua &pill +solid
::
+:: XX: update these examples
:: Then try stuff:
:: :aqua [%init ~[~bud ~dev]]
:: :aqua [%dojo ~[~bud ~dev] "[our eny (add 3 5)]"]
=^ ms state (poke-pill pil)
(emit-cards ms)
::
- [%swap-files ~]
+ [%swap-files @tas]
+ =/ =desk +.val
=. userspace-ova.pil
=/ slim-dirs=(list path)
~[/app /ted /gen /lib /mar /sur /hoon/sys /arvo/sys /zuse/sys]
:_ ~
%- unix-event:pill-lib
- %- %*(. file-ovum:pill-lib directories slim-dirs)
- /(scot %p our.hid)/work/(scot %da now.hid)
+ %+ %*(. file-ovum:pill-lib directories slim-dirs)
+ desk /(scot %p our.hid)/[desk]/(scot %da now.hid)
=^ ms state (poke-pill pil)
(emit-cards ms)
::
|
Googletest's macros don't play nice with some compiler warnings. | namespace testing {
-
+#pragma warning(push)
+#pragma warning(disable:4263) // Method does not override base function doesn't play nice with googlemock macros.
+#pragma warning(disable:4264) // Method does not override base function doesn't play nice with googlemock macros.
class MockILogManagerInternal : public ARIASDK_NS::ILogManagerInternal
{
public:
@@ -45,6 +47,6 @@ namespace testing {
MOCK_METHOD4(GetLogger, ARIASDK_NS::ILogger * (std::string const &, ARIASDK_NS::ContextFieldsProvider*, std::string const &, std::string const &));
MOCK_METHOD1(sendEvent, void(ARIASDK_NS::IncomingEventContextPtr const &));
};
-
+#pragma warning(pop)
} // namespace testing
|
[ZARCH] fix sgemv_t_4.c | @@ -158,8 +158,6 @@ static void sgemv_kernel_4x4(BLASLONG n, FLOAT **ap, FLOAT *x, FLOAT *y)
"brctg %%r0,2b \n\t"
"3: \n\t"
- "agfi %%r1,128 \n\t"
- "brctg %%r0,0b \n\t"
"vrepf %%v4,%%v0,1 \n\t"
"aebr %%f0,%%f4 \n\t"
"vrepf %%v4,%%v0,2 \n\t"
@@ -352,6 +350,9 @@ static void sgemv_kernel_4x1(BLASLONG n, FLOAT *a0, FLOAT *x, FLOAT *y)
"vl %%v31,112(%%r1,%1) \n\t"
"vfmasb %%v0,%%v23,%%v31,%%v0 \n\t"
+ "agfi %%r1,128 \n\t"
+ "brctg %%r0,0b \n\t"
+
"1: \n\t"
"lghi %%r0,28 \n\t"
"ngr %%r0,%0 \n\t"
|
ntpc: optimize stack used | @@ -1222,8 +1222,8 @@ sock_error:
static int ntpc_daemon(int argc, FAR char **argv)
{
- struct ntp_sample_s samples[CONFIG_NETUTILS_NTPCLIENT_NUM_SAMPLES];
- struct ntp_servers_s srvs;
+ FAR struct ntp_sample_s *samples;
+ FAR struct ntp_servers_s *srvs;
int exitcode = EXIT_SUCCESS;
int retries = 0;
int nsamples;
@@ -1233,7 +1233,19 @@ static int ntpc_daemon(int argc, FAR char **argv)
DEBUGASSERT(argc > 1 && argv[1] != NULL && *argv[1] != '\0');
- memset(&srvs, 0, sizeof(srvs));
+ samples = malloc(sizeof(struct ntp_sample_s) *
+ CONFIG_NETUTILS_NTPCLIENT_NUM_SAMPLES);
+ if (samples == NULL)
+ {
+ return EXIT_FAILURE;
+ }
+
+ srvs = calloc(1, sizeof(*srvs));
+ if (srvs == NULL)
+ {
+ free(samples);
+ return EXIT_FAILURE;
+ }
/* Indicate that we have started */
@@ -1268,15 +1280,17 @@ static int ntpc_daemon(int argc, FAR char **argv)
sched_lock();
while (g_ntpc_daemon.state != NTP_STOP_REQUESTED)
{
- struct timespec start_realtime, start_monotonic;
+ struct timespec start_realtime;
+ struct timespec start_monotonic;
int errval = 0;
int i;
- free(srvs.hostlist_str);
- memset(&srvs, 0, sizeof(srvs));
- srvs.ntp_servers = argv[1];
+ free(srvs->hostlist_str);
+ memset(srvs, 0, sizeof(*srvs));
+ srvs->ntp_servers = argv[1];
- memset(samples, 0, sizeof(samples));
+ memset(samples, 0, sizeof(*samples) *
+ CONFIG_NETUTILS_NTPCLIENT_NUM_SAMPLES);
clock_gettime(CLOCK_REALTIME, &start_realtime);
#ifdef CONFIG_CLOCK_MONOTONIC
@@ -1290,7 +1304,7 @@ static int ntpc_daemon(int argc, FAR char **argv)
{
/* Get next sample. */
- ret = ntpc_get_ntp_sample(&srvs, samples, nsamples);
+ ret = ntpc_get_ntp_sample(srvs, samples, nsamples);
if (ret < 0)
{
errval = errno;
@@ -1417,7 +1431,9 @@ static int ntpc_daemon(int argc, FAR char **argv)
g_ntpc_daemon.state = NTP_STOPPED;
sem_post(&g_ntpc_daemon.sync);
- free(srvs.hostlist_str);
+ free(srvs->hostlist_str);
+ free(srvs);
+ free(samples);
return exitcode;
}
|
Disabled warnings we don't need | @@ -71,7 +71,7 @@ LST= $(SRC_C:.c=.lst)
LSTS= $(addprefix out/, $(LST))
INCS= -I$(INCLUDE) -I$(SRC) -I$(RES) -I$(LIBINCLUDE) -I$(LIBRES)
-DEFAULT_FLAGS= -m68000 -Wall -Wextra -Wno-shift-negative-value -fno-builtin $(INCS) -B$(BIN)
+DEFAULT_FLAGS= -m68000 -Wall -Wextra -Wno-shift-negative-value -Wno-main -Wno-unused-parameter -fno-builtin $(INCS) -B$(BIN)
FLAGSZ80= -i$(SRC) -i$(INCLUDE) -i$(RES) -i$(LIBSRC) -i$(LIBINCLUDE)
|
fix(coder) Fix function calls with zero parameters
Previously we would generate C code like `f(L, )`, which is a syntax error | @@ -653,7 +653,8 @@ generate_exp = function(exp) -- TODO
then
-- Directly calling a toplevel function
- local arg_cstatss, arg_cvalues = {}, {}
+ local arg_cstatss = {}
+ local arg_cvalues = {"L"}
for _, arg_exp in ipairs(fargs.args) do
local cstats, cvalue = generate_exp(arg_exp)
table.insert(arg_cstatss, cstats)
@@ -669,7 +670,7 @@ generate_exp = function(exp) -- TODO
local cstats = util.render([[
${ARG_STATS}
- ${TMP_DECL} = ${FUN_NAME}(L, ${ARGS});
+ ${TMP_DECL} = ${FUN_NAME}(${ARGS});
]], {
FUN_NAME = tl_node._titan_entry_point,
ARG_STATS = table.concat(arg_cstatss, "\n"),
|
docs: Fix esp-netif migration guide removing compat mode | @@ -137,10 +137,3 @@ IP Addresses
You are advised to use esp-netif defined IP structures. Please note that with default compatibility enabled, the LwIP structs will still work.
* :component_file:`esp-netif IP address definitions <esp_netif/include/esp_netif_ip_addr.h#L96>`
-
-Next Steps
-^^^^^^^^^^
-
-To port an application which may fully benefit from the :doc:`/api-reference/network/esp_netif`, you also need to disable the tcpip_adapter compatibility layer in the component configuration option. Please go to ``ESP NETIF Adapter`` > ``Enable backward compatible tcpip_adapter interface``. After that, check if your project compiles.
-
-The TCP/IP adapter includes many dependencies. Thus, disabling its compatibility might help separate the application from using specific TCP/IP stack API directly.
|
khan: initial state version is %0 | $> ?(%arow %avow) gift :: thread result
== == ::
+$ khan-state ::
- [%2 hey=duct] :: current unix duct
+ [%0 hey=duct] :: current unix duct
-- ::
=>
|%
:: +load: migrate an old state to a new khan version
::
++ load
- |= $= old
- $% [?(%0 %1) hey=duct *]
- khan-state
- ==
+ |= old=khan-state
^+ khan-gate
- =/ new=khan-state
- ?: ?=(%2 -.old)
- old
- [%2 hey.old]
- khan-gate(state new)
+ khan-gate(state old)
:: +scry: nothing to see as yet
::
++ scry
|
Fix the symbol_presence test with a shlib_variant
If a shlib_variant is used then the dynamic version information for
symbols will be different from what the symbol presence test was
expecting. We just make it more liberal about what it accepts as dynamic
version information.
Fixes | @@ -76,7 +76,7 @@ foreach my $libname (@libnames) {
# Drop the first space and everything following it
s| .*||;
# Drop OpenSSL dynamic version information if there is any
- s|\@\@OPENSSL_[0-9._]+[a-z]?$||;
+ s|\@\@.+$||;
# Return the result
$_
}
|
Fixed error in which VerifyMultiEqtideThermint is called for every body, even if neither module was set. | @@ -810,7 +810,9 @@ void VerifyModuleMultiEqtideThermint(BODY *body,UPDATE *update,CONTROL *control,
iEqtide = fiGetModuleIntEqtide(module,iBody);
control->fnPropsAux[iBody][iEqtide] = &PropsAuxNULL;
*/
+ if (body[iBody].bEqtide && body[iBody].bThermint) {
control->fnPropsAuxMulti[iBody][(*iModuleProps)++] = &PropsAuxEqtideThermint;
+ }
/*
}
}
|
Refactor vnet.am to expose arp feature
vppsb router plugin need include arp.h file. | @@ -117,7 +117,6 @@ API_FILES += vnet/cop/cop.api
# Layer 2 protocol: Ethernet
########################################
libvnet_la_SOURCES += \
- vnet/ethernet/arp.c \
vnet/ethernet/format.c \
vnet/ethernet/init.c \
vnet/ethernet/interface.c \
@@ -132,7 +131,6 @@ libvnet_multiversioning_sources += \
vnet/l2/l2_output.c
nobase_include_HEADERS += \
- vnet/ethernet/arp_packet.h \
vnet/ethernet/error.def \
vnet/ethernet/ethernet.h \
vnet/ethernet/packet.h \
@@ -422,6 +420,16 @@ libvnet_multiversioning_sources += \
vnet/ip/ip4_forward.c \
vnet/ip/ip4_input.c
+########################################
+# Layer 2/3 ARP
+########################################
+libvnet_la_SOURCES += \
+ vnet/ethernet/arp.c
+
+nobase_include_HEADERS += \
+ vnet/ethernet/arp_packet.h \
+ vnet/ethernet/arp.h
+
########################################
# Bidirectional Forwarding Detection
########################################
|
ommit ohpc-filesystem from patterns | @@ -5,7 +5,7 @@ rm -f ${logfile}.*
echo ++++ search and log OpenHPC patterns
-for meta_package in `rpm -qa | grep -e "ohpc-" | grep -v "release" | sort`; do
+for meta_package in `rpm -qa | grep -e "ohpc-" | grep -v "ohpc-release" | grep -v "ohpc-filesystem | sort`; do
echo "parsing $meta_package"
info=`rpm -qi $meta_package | grep -A1 "Description :" | tail -1`
|
Fix CID : Explicit null dereferenced (in test) | @@ -841,6 +841,8 @@ static int test_fromdata_ecx(int tst)
size = ED448_KEYLEN;
alg = "ED448";
break;
+ default:
+ goto err;
}
ctx = EVP_PKEY_CTX_new_from_name(NULL, alg, NULL);
|
Add TU_BREAKPOINT for mips architecture
_mips is provided by xc32-gcc | #elif defined(__riscv)
#define TU_BREAKPOINT() do { __asm("ebreak\n"); } while(0)
+#elif defined(_mips)
+ #define TU_BREAKPOINT() do { __asm("sdbbp 0"); } while (0)
+
#else
#define TU_BREAKPOINT() do {} while (0)
#endif
|
[update] Sort the source file path | @@ -557,6 +557,7 @@ def AddDepend(option):
def MergeGroup(src_group, group):
src_group['src'] = src_group['src'] + group['src']
+ src_group['src'].sort()
if 'CFLAGS' in group:
if 'CFLAGS' in src_group:
src_group['CFLAGS'] = src_group['CFLAGS'] + group['CFLAGS']
|
Update: udp_toothbrush.py: Updated to run with Python3 (as well as Py2) | import subprocess
import socket
import time
-from statistics import mean
import argparse
parser = argparse.ArgumentParser()
@@ -46,9 +45,9 @@ for it in range(iterations):
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
# Read in toothbrush file and extract expected statements
- contents = []
+ contents = ["*volume=0\0", "*motorbabbling=false\0"]
expected = set()
- with open("./../examples/nal/toothbrush.nal") as input_file:
+ with open("./../../examples/nal/toothbrush.nal") as input_file:
for line in input_file:
if "//expected:" in line:
expected.add(line.split("//expected: ")[1].rstrip())
@@ -60,7 +59,6 @@ for it in range(iterations):
stdout=subprocess.PIPE,
universal_newlines=True)
out_file = process.stdout
-
# Check that the startup statements are present
out_file.readline()
out_file.readline()
@@ -84,7 +82,7 @@ for it in range(iterations):
if debug: print("TARGET FOUND IN: " + next_line.rstrip())
if debug: print("RESUMING INPUTS...")
# Dont specify number of cycles, change volume/settings, or include comments
- if line[:-1].isnumeric() or line[0] == "*" or line[0] == "/":
+ if all(x.isdigit() for x in line[:-1]) or line[0] == "/":
continue
# If not waiting on expected, provide next input
else:
@@ -97,4 +95,4 @@ for it in range(iterations):
times.append(run_time)
process.terminate()
-print("Average time: " + str(mean(times)))
+print("Average time: " + str(sum(times)/float(len(times))))
|
sane: address review comments | :: - Subscriptions are correctly setup for hooks
:: - Graph store integration
::
-::
-
::
/- *metadata-store, contacts=contact-store, *group
/+ default-agent, verb, dbug, resource
~[subscribe-to-agent-builds]
++ on-save !>(state)
::
-::
++ on-load
|= =vase
- =/ old
- !<(state-zero vase)
+ =/ old !<(state-zero vase)
`this(mode mode.old)
::
-::
++ on-poke
|= [=mark =vase]
^- (quip card _this)
?. =(%noun mark)
(on-poke:def mark vase)
- ~! action
- =/ act=action
- !<(action vase)
+ =/ act=action !<(action vase)
?: ?=(^mode act)
`this(mode act)
%- (check-sane:sc act)
`this
::
-::
++ on-agent on-agent:def
-::
++ on-watch on-watch:def
-::
++ on-leave on-leave:def
-
+::
++ on-peek
|= =path
^- (unit (unit cage))
|= [=wire =sign-arvo]
?> ?=([%rebuilds ~] wire)
?> ?=([%c %wris *] sign-arvo)
- =/ ucheck
- check-type:sc
+ =/ ucheck check-type:sc
:_ this
%. ~[subscribe-to-agent-builds]
?~ ucheck same
--
::
|_ =bowl:gall
+::
++ subscribe-to-agent-builds
^- card
~& >> "Subscribing..."
::
++ xor
|* [a=(set) b=(set)]
- %-
- %~ uni in (~(dif in a) b)
- (~(dif in b) a)
+ (~(uni in (~(dif in a) b)) (~(dif in b) a))
::
++ check-sane
|= =check
~| %crashing-to-abort-merge
(bex (bex 256))
same
-:: +store-hook-desync: check desync between store and hookk
+:: +store-hook-desync: check desync between store and hook
::
:: check desync between store and hook for contacts,
:: metadata, group and graph
=. issues
contact-desync
issues
+ ::
++ report-desync
|= [app=term =(set path)]
^+ issues
=/ desyncs=(set path)
(xor groups group-syncs)
(report-desync %metadata-store desyncs)
+ ::
++ contact-desync
^+ issues
=/ contacts
=/ desyncs
(xor contact-syncs contacts)
(report-desync %contact-store desyncs)
+ ::
--
:: +metadata-group-desync: check desync between metadata and groups
::
++ metadata-group-desync
^- issues
- =/ groups=(set path)
- group-store-paths
- =/ metadata
- metadata-store-paths
- =/ desyncs
- (xor groups metadata)
+ =/ groups=(set path) group-store-paths
+ =/ metadata metadata-store-paths
+ =/ desyncs (xor groups metadata)
%+ turn
~(tap in desyncs)
|= =path
::
++ contact-group-desync
^- issues
- =/ groups=(set path)
- managed-group-store-paths
- =/ contacts
- contact-store-paths
- =/ desyncs
- (xor contacts groups)
+ =/ groups=(set path) managed-group-store-paths
+ =/ contacts contact-store-paths
+ =/ desyncs (xor contacts groups)
%+ turn
~(tap in desyncs)
|= =path
|
add warning if blacklistentry is wrong | @@ -209,12 +209,17 @@ if((fh_black = fopen(blacklistname, "r")) == NULL)
printf("opening blacklist failed %s\n", blacklistname);
return;
}
+
c = 0;
while((len = fgetline(fh_black, 14, linein)) != -1)
{
if(len != 12)
continue;
- hex2bin(linein, &mac_black_ap[c][0], 6);
+ if(hex2bin(linein, &mac_black_ap[c][0], 6) == false)
+ {
+ printf("reading blacklist entry failed %s\n", blacklistname);
+ break;
+ }
c++;
if(c >= BLACKLISTESIZEMAX)
{
|
GRIB2 templates for chemicals should use forecastTime and not startStep | @@ -45,6 +45,4 @@ template_nofail default_step_units "grib2/localConcepts/[centre:s]/default_step_
codetable[1] stepUnits 'stepUnits.table' = defaultStepUnits : transient,dump,no_copy;
# Forecast time in units defined by indicatorOfUnitOfTimeRange
-signed[4] startStep : dump;
-
-alias forecastTime=startStep;
+signed[4] forecastTime : dump;
|
Implement unscheduled Hellos.
This also removes special casing of late Hellos. | @@ -134,27 +134,18 @@ update_neighbour(struct neighbour *neigh, int hello, int hello_interval)
missed_hellos = 0;
rc = 1;
} else if(missed_hellos < 0) {
- if(hello_interval > neigh->hello_interval) {
- /* This neighbour has increased its hello interval,
- and we didn't notice. */
neigh->reach <<= -missed_hellos;
missed_hellos = 0;
- } else {
- /* Late hello. Probably due to the link layer buffering
- packets during a link outage. Ignore it, but reset
- the expected seqno. */
- neigh->hello_seqno = hello;
- hello = -1;
- missed_hellos = 0;
- }
rc = 1;
}
} else {
missed_hellos = 0;
}
+ if(hello_interval != 0) {
neigh->hello_time = now;
neigh->hello_interval = hello_interval;
}
+ }
if(missed_hellos > 0) {
neigh->reach >>= missed_hellos;
|
links: add soundcloud embeds | @@ -7,7 +7,8 @@ export class LinkPreview extends Component {
constructor(props) {
super(props);
this.state = {
- timeSinceLinkPost: this.getTimeSinceLinkPost()
+ timeSinceLinkPost: this.getTimeSinceLinkPost(),
+ embed: ""
};
}
@@ -67,6 +68,12 @@ export class LinkPreview extends Component {
/(?:(?:(?:(?:watch\?)?(?:time_continue=(?:[0-9]+))?.+v=)?([a-zA-Z0-9_-]+))(?:\?t\=(?:[0-9a-zA-Z]+))?)/.source // id
);
+ let soundcloudRegex = new RegExp('' +
+ /(https?:\/\/(?:www.)?soundcloud.com\/[\w-]+\/?(?:sets\/)?[\w-]+)/.source
+ );
+
+ let isSoundcloud = soundcloudRegex.exec(props.url);
+
let ytMatch = youTubeRegex.exec(props.url);
let embed = "";
@@ -91,13 +98,26 @@ export class LinkPreview extends Component {
);
}
+ if (isSoundcloud && this.state.embed === "") {
+ fetch(
+ 'https://soundcloud.com/oembed?format=json&url=' +
+ encodeURIComponent(props.url))
+ .then((response) => {
+ return response.json();
+ })
+ .then((json) => {
+ console.log(json)
+ this.setState({embed: json.html})
+ })
+ }
+
let nameClass = props.nickname ? "inter" : "mono";
return (
<div className="pb6 w-100">
<div
className={"w-100 tc " + (ytMatch ? "embed-container" : "")}>
- {embed}
+ {embed || <div dangerouslySetInnerHTML={{__html: this.state.embed}}/>}
</div>
<div className="flex flex-column ml2 pt6 flex-auto">
<a href={props.url} className="w-100 flex" target="_blank">
|
Fix crash on --no-control
Relative mouse mode assumed that a mouse processor was always available,
but this is not the case if --no-control is passed. | @@ -773,6 +773,9 @@ sc_screen_is_mouse_capture_key(SDL_Keycode key) {
void
sc_screen_handle_event(struct sc_screen *screen, SDL_Event *event) {
+ // screen->im.mp may be NULL if --no-control
+ bool relative_mode = screen->im.mp && screen->im.mp->relative_mode;
+
switch (event->type) {
case EVENT_NEW_FRAME: {
bool ok = sc_screen_update_frame(screen);
@@ -810,14 +813,14 @@ sc_screen_handle_event(struct sc_screen *screen, SDL_Event *event) {
sc_screen_render(screen, true);
break;
case SDL_WINDOWEVENT_FOCUS_LOST:
- if (screen->im.mp->relative_mode) {
+ if (relative_mode) {
sc_screen_capture_mouse(screen, false);
}
break;
}
return;
case SDL_KEYDOWN:
- if (screen->im.mp->relative_mode) {
+ if (relative_mode) {
SDL_Keycode key = event->key.keysym.sym;
if (sc_screen_is_mouse_capture_key(key)) {
if (!screen->mouse_capture_key_pressed) {
@@ -834,7 +837,7 @@ sc_screen_handle_event(struct sc_screen *screen, SDL_Event *event) {
}
break;
case SDL_KEYUP:
- if (screen->im.mp->relative_mode) {
+ if (relative_mode) {
SDL_Keycode key = event->key.keysym.sym;
SDL_Keycode cap = screen->mouse_capture_key_pressed;
screen->mouse_capture_key_pressed = 0;
@@ -851,7 +854,7 @@ sc_screen_handle_event(struct sc_screen *screen, SDL_Event *event) {
case SDL_MOUSEWHEEL:
case SDL_MOUSEMOTION:
case SDL_MOUSEBUTTONDOWN:
- if (screen->im.mp->relative_mode && !screen->mouse_captured) {
+ if (relative_mode && !screen->mouse_captured) {
// Do not forward to input manager, the mouse will be captured
// on SDL_MOUSEBUTTONUP
return;
@@ -860,14 +863,14 @@ sc_screen_handle_event(struct sc_screen *screen, SDL_Event *event) {
case SDL_FINGERMOTION:
case SDL_FINGERDOWN:
case SDL_FINGERUP:
- if (screen->im.mp->relative_mode) {
+ if (relative_mode) {
// Touch events are not compatible with relative mode
// (coordinates are not relative)
return;
}
break;
case SDL_MOUSEBUTTONUP:
- if (screen->im.mp->relative_mode && !screen->mouse_captured) {
+ if (relative_mode && !screen->mouse_captured) {
sc_screen_capture_mouse(screen, true);
return;
}
|
Add unknown key stderr debug (ifdefd out) | @@ -588,6 +588,11 @@ int main(int argc, char** argv) {
// situations where max throughput is necessary.
needs_remarking = true;
}
+#if 0
+ else {
+ fprintf(stderr, "Unknown key number: %d\n", key);
+ }
+#endif
break;
}
|
Live reload ascii/frame/avatar images into DialoguePreview | @@ -103,19 +103,19 @@ export const DialoguePreview: FC<DialoguePreviewProps> = ({
projectRoot,
"ui",
frameAsset
- )}`;
+ )}?_v=${uiVersion}`;
const asciiFilename = `file:///${assetFilename(
projectRoot,
"ui",
asciiAsset
- )}`;
+ )}?_v=${uiVersion}`;
const avatarFilename = avatarAsset ? `file:///${assetFilename(
projectRoot,
"sprites",
avatarAsset
- )}` : "";
+ )}?_v=${avatarAsset._v || 0}` : "";
// Load frame image
useEffect(() => {
|
OcAppleKernelLib: Fix compiler warnings | @@ -127,6 +127,7 @@ PatchAppleCpuPmCfgLock (
}
} else {
DEBUG ((DEBUG_INFO, "OCAK: Failed to find com.apple.driver.AppleIntelCPUPowerManagement - %r\n", Status));
+ Status2 = Status;
}
//
|
Check "x op= y". | @@ -60,22 +60,47 @@ func (c *typeChecker) checkStatement(n *a.Node) error {
case a.KAssign:
o := n.Assign()
- l := o.LHS()
- r := o.RHS()
- if err := c.checkExpr(l); err != nil {
+ lhs := o.LHS()
+ rhs := o.RHS()
+ if err := c.checkExpr(lhs); err != nil {
return err
}
- if err := c.checkExpr(r); err != nil {
+ if err := c.checkExpr(rhs); err != nil {
return err
}
- lTyp := l.MType()
- rTyp := r.MType()
- // TODO, look at o.Operator().
+ lTyp := lhs.MType()
+ rTyp := rhs.MType()
+
+ if o.Operator() == t.IDEq {
if (rTyp == TypeExprIdealNumber && lTyp.IsNumType()) || lTyp.EqIgnoringRefinements(rTyp) {
return nil
}
return fmt.Errorf("check: cannot assign %q of type %q to %q of type %q",
- r.String(c.idMap), rTyp.String(c.idMap), l.String(c.idMap), lTyp.String(c.idMap))
+ rhs.String(c.idMap), rTyp.String(c.idMap), lhs.String(c.idMap), lTyp.String(c.idMap))
+ }
+
+ if !lTyp.IsNumType() {
+ return fmt.Errorf("check: assignment %q: assignee %q, of type %q, does not have numeric type",
+ c.idMap.ByID(o.Operator()), lhs.String(c.idMap), lTyp.String(c.idMap))
+ }
+
+ switch o.Operator() {
+ case t.IDShiftLEq, t.IDShiftREq:
+ if rTyp.IsNumType() {
+ return nil
+ }
+ return fmt.Errorf("check: assignment %q: shift %q, of type %q, does not have numeric type",
+ c.idMap.ByID(o.Operator()), rhs.String(c.idMap), rTyp.String(c.idMap))
+ }
+
+ if rTyp == TypeExprIdealNumber || lTyp.EqIgnoringRefinements(rTyp) {
+ return nil
+ }
+ return fmt.Errorf("check: assignment %q: %q and %q, of types %q and %q, do not have compatible types",
+ c.idMap.ByID(o.Operator()),
+ lhs.String(c.idMap), rhs.String(c.idMap),
+ lTyp.String(c.idMap), rTyp.String(c.idMap),
+ )
case a.KVar:
o := n.Var()
|
config_tools: fix the issue that fail to read XSD file
fix the path issue that fail to read XSD file. | @@ -116,7 +116,7 @@ def main(board_name, board_xml, args):
module.extract(args, board_etree)
# Validate the XML against XSD assertions
- count = validator.validate_board("schema/boardchecks.xsd", board_etree)
+ count = validator.validate_board(os.path.join(script_dir, 'schema', 'boardchecks.xsd'), board_etree)
if count == 0:
logging.info("All board checks passed.")
|
Honour maximum requests when using embedded mode. | @@ -349,6 +349,10 @@ WSGISocketPrefix %(server_root)s/wsgi
WSGISocketRotation Off
</IfDefine>
+<IfDefine EMBEDDED_MODE>
+MaxConnectionsPerChild %(maximum_requests)s
+</IfDefine>
+
<IfDefine !ONE_PROCESS>
<IfDefine !EMBEDDED_MODE>
WSGIRestrictEmbedded On
|
Fix WinCE config target
vc_wince_info()->{defines} was left around, when it should be
vc_wince_info()->{cppflags} | @@ -1433,7 +1433,7 @@ my %targets = (
: " /MC"; }),
debug => "/Od",
release => "/O1i"),
- cppflags => sub { vc_wince_info()->{defines}; },
+ cppflags => sub { vc_wince_info()->{cppflags}; },
defines =>
picker(default => [ "UNICODE", "_UNICODE", "OPENSSL_SYS_WINCE",
"WIN32_LEAN_AND_MEAN", "L_ENDIAN", "DSO_WIN32",
|
bloog: add SKU IDs
BRANCH=octopus
TEST=make buildall -j
Commit-Ready: ChromeOS CL Exonerator Bot | @@ -211,12 +211,13 @@ unsigned int motion_sensor_count = ARRAY_SIZE(motion_sensors);
int board_is_convertible(void)
{
/*
- * Bloog: 33, 34, 35
- * Blooguard: 49, 50
+ * Bloog: 33, 34, 35, 36
+ * Blooguard: 49, 50, 51, 52
* Unprovisioned: 255
*/
- return sku_id == 33 || sku_id == 34 || sku_id == 35 || sku_id == 49
- || sku_id == 50 || sku_id == 255;
+ return sku_id == 33 || sku_id == 34 || sku_id == 35 || sku_id == 36
+ || sku_id == 49 || sku_id == 50 || sku_id == 51 || sku_id == 52
+ || sku_id == 255;
}
static void board_update_sensor_config_from_sku(void)
@@ -312,7 +313,7 @@ uint32_t board_override_feature_flags0(uint32_t flags0)
/*
* Remove keyboard backlight feature for devices that don't support it.
*/
- if (sku_id == 33)
+ if (sku_id == 33 || sku_id == 36 || sku_id == 51 || sku_id == 52)
return (flags0 & ~EC_FEATURE_MASK_0(EC_FEATURE_PWM_KEYB));
else
return flags0;
|
Crypto: Simplify CMake code | include (LibAddPlugin)
if (DEPENDENCY_PHASE)
- set (plugin crypto)
find_package (Libgcrypt QUIET)
if (NOT LIBGCRYPT_FOUND)
- remove_plugin (${plugin} "libgcrypt development files not found")
+ remove_plugin (crypto "libgcrypt development files not found")
endif ()
-
- # clean up for dependency phase
- unset (plugin)
endif ()
#
|
Add RedSocks Security to "who's using YARA". | @@ -86,6 +86,7 @@ helpful extension to YARA developed and open-sourced by Bayshore Networks.
* [Picus Security](http://www.picussecurity.com/)
* [Radare2](http://rada.re)
* [Raytheon Cyber Products, Inc.](http://www.raytheoncyber.com/capabilities/products/sureview-threatprotection/)
+* [RedSocks Security](https://redsocks.eu/)
* [ReversingLabs](http://reversinglabs.com)
* [root9B](https://www.root9b.com)
* [RSA ECAT](http://www.emc.com/security/rsa-ecat.htm)
|
EVP_PKEY_gettable_params.pod: Update argument names
CLA: trivial | @@ -22,10 +22,10 @@ EVP_PKEY_get_octet_string_param
BIGNUM **bn);
int EVP_PKEY_get_utf8_string_param(const EVP_PKEY *pkey, const char *key_name,
char *str, size_t max_buf_sz,
- size_t *out_sz);
+ size_t *out_len);
int EVP_PKEY_get_octet_string_param(const EVP_PKEY *pkey, const char *key_name,
unsigned char *buf, size_t max_buf_sz,
- size_t *out_sz);
+ size_t *out_len);
=head1 DESCRIPTION
@@ -70,7 +70,7 @@ All other methods return 1 if a value associated with the key's I<key_name> was
successfully returned, or 0 if there was an error.
An error may be returned by methods EVP_PKEY_get_utf8_string_param() and
EVP_PKEY_get_octet_string_param() if I<max_buf_sz> is not big enough to hold the
-value. If I<out_sz> is not NULL, I<*out_sz> will be assigned the required
+value. If I<out_len> is not NULL, I<*out_len> will be assigned the required
buffer size to hold the value.
=head1 EXAMPLES
|
Don't worry about function name mangling for now. | @@ -130,7 +130,6 @@ end
-- @param varname: (string) C variable name
-- @returns A syntactically valid variable declaration
local function c_declaration(ctyp, varname)
- -- This would be harder if we also allowed array or function pointers...
return ctyp .. " " .. varname
end
@@ -138,9 +137,7 @@ end
--
--
--- This name-mangling scheme is designed to avoid clashes between the function
--- names created in separate models.
-local function mangle_function_name(_modname, funcname, kind)
+local function function_name(funcname, kind)
return string.format("function_%s_%s", funcname, kind)
end
@@ -262,9 +259,9 @@ generate_program = function(prog, modname)
for _, tl_node in ipairs(prog) do
if tl_node._tag == ast.Toplevel.Func then
tl_node._titan_entry_point =
- mangle_function_name(modname, tl_node.name, "titan")
+ function_name(tl_node.name, "titan")
tl_node._lua_entry_point =
- mangle_function_name(modname, tl_node.name, "lua")
+ function_name(tl_node.name, "lua")
end
end
|
[sectools] switched to pgx v4 | @@ -495,7 +495,6 @@ ALLOW security/impulse/api/internal/db -> vendor/github.com/jackc/pgx
ALLOW security/impulse/api/repositories/scaninstance -> vendor/github.com/jackc/pgx
ALLOW security/impulse/api/repositories/vulnerability -> vendor/github.com/jackc/pgx
ALLOW security/impulse/api/usecases/idm -> vendor/github.com/jackc/pgx
-ALLOW security/sectools-web/internal/db -> vendor/github.com/jackc/pgx
ALLOW transfer_manager/go/cmd/load_generator -> vendor/github.com/jackc/pgx
ALLOW transfer_manager/go/pkg/configurator -> vendor/github.com/jackc/pgx
ALLOW transfer_manager/go/pkg/dbaas -> vendor/github.com/jackc/pgx
|
Skip the no derivation functions when in FIPS mode because they are not
applicable. | @@ -257,7 +257,8 @@ static int test_cavs_kats(const struct drbg_kat *test[], int i)
#ifdef FIPS_MODE
/* FIPS mode doesn't support instantiating without a derivation function */
if ((td->flags & USE_DF) == 0)
- return 1;
+ return TEST_skip("instantiating without derivation function "
+ "is not supported in FIPS mode");
#endif
switch (td->type) {
case NO_RESEED:
|
just cleaning yuitora's code | @@ -486,14 +486,16 @@ class Beatmap:
osuobj["end y"] += space
-def split(delimiters, string):
- lines = string.split("\n")
- curheader = "dummy"
- info = {curheader: ""}
- newheader = False
+def split(delimiters: list, string: str):
+ lines = string.split('\n')
+ info = {'dummy': ''}
+
for line in lines:
+ newheader = False
+ curheader = 'dummy'
line = line.strip()
- if line == "":
+
+ if not line:
continue
for header in delimiters:
@@ -504,25 +506,31 @@ def split(delimiters, string):
curheader = header
if not newheader:
- info[curheader] += line + "\n"
- newheader = False
+ info[curheader] += line + '\n'
+
+
+
return info
+
+
def read_file(filename, scale=1, colors=None, hr=False, dt=False, mods=None, lazy=True):
if hr or dt:
- logger.warning("hr args is depecrated")
+ logger.warning("HR args is deprecated.")
# checks if filename is a path
if os.path.isdir(filename):
raise NotAnBeatmap()
- fiel = open(filename, "r", encoding="utf-8")
- content = fiel.read()
- delimiters = ["[General]", "[Editor]", "[Metadata]", "[Difficulty]", "[Events]", "[TimingPoints]", "[Colours]",
- "[HitObjects]"]
- info = split(delimiters, content)
- fiel.close()
+
+ delimiters = ["[General]", "[Editor]", "[Metadata]", "[Difficulty]",
+ "[Events]", "[TimingPoints]", "[Colours]", "[HitObjects]"]
+
+ with open(filename , 'r', encoding='utf-8') as file:
+ info = split(delimiters, file.read())
+
+
bmap = Beatmap(info, scale, colors, mods=mods, lazy=lazy)
bmap.path = filename
bmap.hash = osuhash(filename)
|
Add missing typecast | @@ -44,7 +44,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
{
YR_COMPILER* compiler;
- char* buffer = malloc(size + 1);
+ char* buffer = (char*) malloc(size + 1);
if (!buffer)
return 1;
|
Update version to 8.0.0-dev | @@ -14,8 +14,8 @@ extern "C" {
/***************************
* CURRENT VERSION OF LVGL
***************************/
-#define LVGL_VERSION_MAJOR 7
-#define LVGL_VERSION_MINOR 7
+#define LVGL_VERSION_MAJOR 8
+#define LVGL_VERSION_MINOR 0
#define LVGL_VERSION_PATCH 0
#define LVGL_VERSION_INFO "dev"
|
give recommendation on ESSID changes | @@ -660,7 +660,7 @@ if(essidcount > 0) printf("ESSID (total unique).....................: %ld\n",
if(essiddupemax > 0)
{
if((essidsvalue > 1) || (donotcleanflag == true)) printf("ESSID changes (detected maximum).........: %ld\n", essiddupemax);
- else printf("ESSID changes (detected maximum).........: %ld (information: option --max-essids=<digit> and --all recommended)\n", essiddupemax);
+ else printf("ESSID changes (detected maximum).........: %ld (information: option --max-essids=%ld and --all recommended)\n", essiddupemax, essiddupemax +1);
}
if(eaptimegapmax > 0) printf("EAPOLTIME gap (measured maximum usec)....: %" PRId64 "\n", eaptimegapmax);
if((eapolnccount > 0) && (eapolmpcount > 0))
|
Reduce paramter hrr from ssl_tls13_parse_server_hello | @@ -1021,8 +1021,7 @@ static int ssl_tls13_cipher_suite_is_offered( mbedtls_ssl_context *ssl,
*/
static int ssl_tls13_parse_server_hello( mbedtls_ssl_context *ssl,
const unsigned char *buf,
- const unsigned char *end,
- int hrr )
+ const unsigned char *end)
{
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
const unsigned char *p = buf;
@@ -1166,6 +1165,9 @@ static int ssl_tls13_parse_server_hello( mbedtls_ssl_context *ssl,
{
unsigned int extension_type;
size_t extension_data_len;
+#if defined(MBEDTLS_KEY_EXCHANGE_WITH_CERT_ENABLED)
+ int hrr;
+#endif /* MBEDTLS_KEY_EXCHANGE_WITH_CERT_ENABLED */
MBEDTLS_SSL_CHK_BUF_READ_PTR( p, extensions_end, 4 );
extension_type = MBEDTLS_GET_UINT16_BE( p, 0 );
@@ -1224,13 +1226,16 @@ static int ssl_tls13_parse_server_hello( mbedtls_ssl_context *ssl,
#if defined(MBEDTLS_KEY_EXCHANGE_WITH_CERT_ENABLED)
case MBEDTLS_TLS_EXT_KEY_SHARE:
+ hrr = ssl_server_hello_is_hrr( ssl, buf, end );
MBEDTLS_SSL_DEBUG_MSG( 3, ( "found key_shares extension" ) );
- if( hrr )
+ if( hrr == SSL_SERVER_HELLO_COORDINATE_HRR )
ret = ssl_tls13_hrr_check_key_share_ext( ssl,
p, p + extension_data_len );
- else
+ else if( hrr == SSL_SERVER_HELLO_COORDINATE_HELLO )
ret = ssl_tls13_parse_key_share_ext( ssl,
p, p + extension_data_len );
+ else
+ ret = hrr;
if( ret != 0 )
{
MBEDTLS_SSL_DEBUG_RET( 1,
@@ -1440,8 +1445,7 @@ static int ssl_tls13_process_server_hello( mbedtls_ssl_context *ssl )
* the respective parsing function.
*/
MBEDTLS_SSL_PROC_CHK( ssl_tls13_parse_server_hello( ssl, buf,
- buf + buf_len,
- hrr ) );
+ buf + buf_len ) );
if( hrr == SSL_SERVER_HELLO_COORDINATE_HRR )
MBEDTLS_SSL_PROC_CHK( mbedtls_ssl_reset_transcript_for_hrr( ssl ) );
|
SOVERSION bump to version 5.0.7 | @@ -39,7 +39,7 @@ set(SYSREPO_VERSION ${SYSREPO_MAJOR_VERSION}.${SYSREPO_MINOR_VERSION}.${SYSREPO_
# with backward compatible change and micro version is connected with any internal change of the library.
set(SYSREPO_MAJOR_SOVERSION 5)
set(SYSREPO_MINOR_SOVERSION 0)
-set(SYSREPO_MICRO_SOVERSION 6)
+set(SYSREPO_MICRO_SOVERSION 7)
set(SYSREPO_SOVERSION_FULL ${SYSREPO_MAJOR_SOVERSION}.${SYSREPO_MINOR_SOVERSION}.${SYSREPO_MICRO_SOVERSION})
set(SYSREPO_SOVERSION ${SYSREPO_MAJOR_SOVERSION})
|
[numerics] fix compilation when PATH is not enabled | #include "LinearComplementarityProblem.h"
#include "SolverOptions.h"
+#include "LCP_Solvers.h"
#ifdef HAVE_PATHFERRIS
#include <stdlib.h>
#include <string.h>
#include <math.h>
-#include "LCP_Solvers.h"
#include "SimpleLCP.h"
#include "numerics_verbose.h"
|
generic: return EINVAL from sys_open() if illegal arguments are passed | @@ -3409,6 +3409,8 @@ int sys_openat(int dirfd, const char *path, int flags, int *fd) {
return ENXIO;
}else if(resp.error() == managarm::posix::Errors::IS_DIRECTORY) {
return EISDIR;
+ }else if(resp.error() == managarm::posix::Errors::ILLEGAL_ARGUMENTS) {
+ return EINVAL;
}else{
__ensure(resp.error() == managarm::posix::Errors::SUCCESS);
*fd = resp.fd();
|
fixed 6GHz frequency handling | @@ -820,7 +820,7 @@ if(radiotappresent == true)
c = 0;
fprintf(stdout, "\nfrequency statistics from radiotap header (frequency: received packets)\n"
"-----------------------------------------------------------------------\n");
- for(p = 2400; p < 7000; p ++)
+ for(p = 2412; p <= 7115; p ++)
{
if(usedfrequency[p] != 0)
{
|
Add comment to compile_o_to_so()
Specify why we are not using the '-x' flag when compiling object files. | @@ -56,6 +56,8 @@ function c_compiler.compile_s_to_o(in_filename, out_filename)
end
function c_compiler.compile_o_to_so(in_filename, out_filename)
+ -- There is no need to add the '-x' flag when compiling an object file without a '.o' extension.
+ -- According to GCC, any file name with no recognized suffix is treated as an object file.
return run_cc({
c_compiler.CFLAGS_SHARED,
"-o", util.shell_quote(out_filename),
|
VERSION bump to version 0.12.64 | @@ -34,7 +34,7 @@ set(CMAKE_C_FLAGS_DEBUG "-g -O0")
# set version
set(LIBNETCONF2_MAJOR_VERSION 0)
set(LIBNETCONF2_MINOR_VERSION 12)
-set(LIBNETCONF2_MICRO_VERSION 63)
+set(LIBNETCONF2_MICRO_VERSION 64)
set(LIBNETCONF2_VERSION ${LIBNETCONF2_MAJOR_VERSION}.${LIBNETCONF2_MINOR_VERSION}.${LIBNETCONF2_MICRO_VERSION})
set(LIBNETCONF2_SOVERSION ${LIBNETCONF2_MAJOR_VERSION}.${LIBNETCONF2_MINOR_VERSION})
|
xive: Don't assert if xive_get_vp() fails
Just return NULL to the caller | @@ -764,7 +764,8 @@ static struct xive_vp *xive_get_vp(struct xive *x, unsigned int idx)
assert(idx < (x->vp_ind_count * VP_PER_PAGE));
p = (struct xive_vp *)(x->vp_ind_base[idx / VP_PER_PAGE] &
VSD_ADDRESS_MASK);
- assert(p);
+ if (!p)
+ return NULL;
return &p[idx % VP_PER_PAGE];
#else
|
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.