mirror of
https://github.com/rkd77/elinks.git
synced 2024-09-26 02:46:13 -04:00
Merge branch 'master' into css
This commit is contained in:
commit
ddc6e8381c
@ -846,7 +846,7 @@ else
|
|||||||
CONFIG_SCRIPTING_SPIDERMONKEY=no
|
CONFIG_SCRIPTING_SPIDERMONKEY=no
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CXXFLAGS="$CXXFLAGS -fpermissive -Wno-sign-compare -std=gnu++17"
|
CXXFLAGS="$CXXFLAGS -fpermissive -Wno-sign-compare"
|
||||||
|
|
||||||
if test "x$CONFIG_ECMASCRIPT_SMJS" = xyes ||
|
if test "x$CONFIG_ECMASCRIPT_SMJS" = xyes ||
|
||||||
test "x$CONFIG_SCRIPTING_SPIDERMONKEY" = xyes; then
|
test "x$CONFIG_SCRIPTING_SPIDERMONKEY" = xyes; then
|
||||||
|
@ -446,7 +446,9 @@ static INIT_LIST_OF(struct screen_driver, active_screen_drivers);
|
|||||||
void
|
void
|
||||||
set_screen_dirty(struct terminal_screen *screen, int from, int to)
|
set_screen_dirty(struct terminal_screen *screen, int from, int to)
|
||||||
{
|
{
|
||||||
for (unsigned int i = from; i <= to; i++) {
|
unsigned int i;
|
||||||
|
|
||||||
|
for (i = from; i <= to; i++) {
|
||||||
set_bitfield_bit(screen->dirty, i);
|
set_bitfield_bit(screen->dirty, i);
|
||||||
}
|
}
|
||||||
screen->was_dirty = 1;
|
screen->was_dirty = 1;
|
||||||
|
@ -553,6 +553,7 @@ string_replace(struct string *res, struct string *inp, struct string *what, stru
|
|||||||
char *found;
|
char *found;
|
||||||
char *ins;
|
char *ins;
|
||||||
char *tmp_cnt;
|
char *tmp_cnt;
|
||||||
|
int i;
|
||||||
|
|
||||||
if (!init_string(&tmp)) {
|
if (!init_string(&tmp)) {
|
||||||
return;
|
return;
|
||||||
@ -579,7 +580,7 @@ string_replace(struct string *res, struct string *inp, struct string *what, stru
|
|||||||
ins = tmp_cnt + what->length;
|
ins = tmp_cnt + what->length;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i=0;i<count;i++) {
|
for (i = 0; i < count; i++) {
|
||||||
// find occurence of string
|
// find occurence of string
|
||||||
found=strstr(head,what->source);
|
found=strstr(head,what->source);
|
||||||
// count chars before and after occurence
|
// count chars before and after occurence
|
||||||
|
@ -187,10 +187,10 @@ struct string {
|
|||||||
* @relates string */
|
* @relates string */
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
#ifdef DEBUG_MEMLEAK
|
#ifdef DEBUG_MEMLEAK
|
||||||
[[nodiscard]] struct string *init_string__(const char *file, int line, struct string *string);
|
struct string *init_string__(const char *file, int line, struct string *string);
|
||||||
#define init_string(string) init_string__(__FILE__, __LINE__, string)
|
#define init_string(string) init_string__(__FILE__, __LINE__, string)
|
||||||
#else
|
#else
|
||||||
[[nodiscard]] struct string *init_string(struct string *string);
|
struct string *init_string(struct string *string);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
@ -267,10 +267,11 @@ write_start_of_link(struct link *link, struct dump_output *out)
|
|||||||
{
|
{
|
||||||
char buf[D_BUF];
|
char buf[D_BUF];
|
||||||
char *where = link->where ?: link->where_img;
|
char *where = link->where ?: link->where_img;
|
||||||
|
char *st;
|
||||||
|
|
||||||
snprintf(buf, D_BUF, "\033]8;;%s\033\\", where);
|
snprintf(buf, D_BUF, "\033]8;;%s\033\\", where);
|
||||||
|
|
||||||
for (char *st = buf; *st; st++) {
|
for (st = buf; *st; st++) {
|
||||||
write_char(*st, out);
|
write_char(*st, out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -279,8 +280,9 @@ static void
|
|||||||
write_end_of_link(struct dump_output *out)
|
write_end_of_link(struct dump_output *out)
|
||||||
{
|
{
|
||||||
char buf[] = "\033]8;;\033\\";
|
char buf[] = "\033]8;;\033\\";
|
||||||
|
char *st;
|
||||||
|
|
||||||
for (char *st = buf; *st; st++) {
|
for (st = buf; *st; st++) {
|
||||||
write_char(*st, out);
|
write_char(*st, out);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user