summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2021-06-05LibJS: Replace StringOrSymbol::from_value with Value::to_property_keyIdan Horowitz
This is a more specification compliant implementation of the abstract operation 7.1.19 ToPropertyKey which should handle boxed symbols correctly.
2021-06-05Ports/PHP: Enable OpenSSL extensionJelle Raaijmakers
2021-06-05Ports/PHP: Disable PCRE JITJelle Raaijmakers
The PCRE JIT creates memory that needs to be readable, writable and executable at the same time. Serenity does not like this, so disable it. This JIT is of limited use for the current applications of PHP within Serenity anyway :-)
2021-06-05Ports/PHP: Enable Zlib extensionJelle Raaijmakers
2021-06-05Ports/PHP: Enable Phar extensionJelle Raaijmakers
2021-06-05Kernel: Perform output processing on echoDaniel Bertalan
Previously, we would echo characters back just as they were passed to us, even in canonical mode. This caused newlines to not work correctly in some programs. Fixes #7802
2021-06-05LibJS: Use PropertyName::as_string() in Object::get()Andreas Kling
After we've already checked is_string(), we can use as_string() to avoid a temporary String.
2021-06-05AK: Always inline FlyString::view()Andreas Kling
2021-06-05LibWasm: Move Wasm::BytecodeInterpreter into its own headerSahan Fernando
2021-06-05TreeView: Don't try to move cursor with invalid indexMarcus Nilsson
When clicking on the TreeView in profiler without selecting a node and then pressing up or pgup, cursor_index was in an invalid state. Instead select the first node in the index.
2021-06-05rm: Allow empty paths if -f is specifiedTim Schumacher
On most (if not all) systems rm ignores an empty paths array if -f or --force is specified. This helps with scripts that may pass an empty variable where the file paths are supposed to go.
2021-06-05Ports: Add port for freecivGunnar Beutner
2021-06-05LibC: Let setlocale() pretend that setting the locale succeededGunnar Beutner
By returning nullptr we're telling the caller that setlocale() failed. Some programs expect setlocale() to succeed so let's pretend that it did.
2021-06-05Ports: Specify missing library when linking SDL2_ttfGunnar Beutner
2021-06-05Ports: Build shared library for freetypeGunnar Beutner
2021-06-05Ports: fix gcc for mac usersyegor
BSD sed differs from GNU sed with the `-i` option. This commit changes the sed line in package.sh to be portable across macOS and Linux.
2021-06-05AK: Stop using U+0000 as end of file code point in URL parserMax Wipfli
This changes URL parser to use the 0xFFFFFFFF constant instead of 0 to indicate end of file. This fixes a bug where inputs containing null bytes would terminate the parser early, because they were interpreted as end of file.
2021-06-05AK: Make debugging URLParser easierMax Wipfli
This patch adds a state_name method to URLParser to convert a state to a string. With this, the debugging statements now display the state names. Furthermore, this fixes a bug where non-ASCII code points were formatted as characters, which fails an assertion in the formatting system.
2021-06-05AK: Do not trim away non-ASCII bytes when parsing URLMax Wipfli
Because non-ASCII code points have negative byte values, trimming away control characters requires checking for negative bytes values. This also adds a test case with a URL containing non-ASCII code points.
2021-06-05AK: Update URLParser.{cpp,h} to use east constMax Wipfli
2021-06-05LibJS: Add the Number.{MAX, MIN}_VALUE constantsIdan Horowitz
2021-06-04Kernel: Implement offset for `lseek` with `SEEK_END`Jelle Raaijmakers
2021-06-04LibCards: Draw card stack background when the entire stack is movingTimothy Flynn
The stack background should be painted when the entire stack is being dragged, rather than just the top card. Fixes #7786. Regressed in 2b762ef94075b8a6e1ae8dd61e535b6b6cf7c064.
2021-06-04Kernel: Process::exec(): Check if path is a regular fileJelle Raaijmakers
https://pubs.opengroup.org/onlinepubs/9699919799/functions/exec.html [EACCES] The new process image file is not a regular file and the implementation does not support execution of files of its type. Let's check whether the passed `path` is indeed a regular file.
2021-06-04Shell: Add TMPDIR environment variableJelle Raaijmakers
https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/ V1_chap08.html TMPDIR This variable shall represent a pathname of a directory made available for programs that need a place to create temporary files. Ports like PHP benefit from having this environment variable set, and there exist a lot of scripts that assume the presence of such an environment variable.
2021-06-05Kernel: Update the TX byte counter when sending network packetsGunnar Beutner
This previously worked but was broken by b436dd1.
2021-06-05LibCpp: Fix off-by-one error in SyntaxHighlighterMax Wipfli
This changes the C++ SyntaxHighlighter to conform to the now-fixed rendering of syntax highlighting spans in GUI::TextEditor. Contrary to other syntax highlighters, for this one the change has been made to the SyntaxHighlighter rather than the Lexer. This is due to the fact that the Parser also uses the same Lexer. I'm soure there is some more elegant way to do this, but this patch at least unbreaks the C++ syntax highlighting.
2021-06-05LibCpp: Do not emit empty whitespace token after include statementMax Wipfli
If an include statement didn't contain whitespace between the word "include" and the '<' or '"', the lexer would previous emit an empty whitespace token. This has been changed now.
2021-06-05LibCpp: Use CharacterTypes.h and constexpr functions in LexerMax Wipfli
2021-06-05LibCpp: Use east const style in Lexer and SyntaxHighlighterMax Wipfli
2021-06-05LibWeb: Change a few source end positions in HTMLTokenizerMax Wipfli
This patch aims to fix wrong highlighting for some cases in HTML's syntax highlighter. The values were somewhat experimentally determined are are subject to change. Regardless, it should be more correct with this patch than without it. :^)
2021-06-05LibWeb: Fix off-by-one error in SyntaxHighlighterMax Wipfli
This changes the HTML SyntaxHighlighter to conform to the now-fixed rendering of syntax highlighting spans in GUI::TextEditor. It also avoids emitting tokens if they have a zero or negative length. This fixes a bug where single-character tokens were not highlighted properly.
2021-06-05LibWeb: Be more forgiving when adding source positions in HTMLTokenizerMax Wipfli
This patch changes HTMLTokenizer::nth_last_position to not fail if the requested position is not available. Rather, it will just return (0-0). While this is not the correct solution, it prevents the tokenizer from crashing just because it cannot find a source position. This should only affect SyntaxHighlighter.
2021-06-05LibWeb: Add debugging statements in SyntaxHighlighterMax Wipfli
This also changes SyntaxHighlighter.{h,cpp} to use east const style.
2021-06-05LibSQL: Fix off-by-one error in SyntaxHighlighterMax Wipfli
This changes the SQL SyntaxHighlighter to conform to the now-fixed rendering of syntax highlighting spans in GUI::TextEditor.
2021-06-05LibSQL: Clean up SyntaxHighlighter codeMax Wipfli
This changes SyntaxHighlighter.{cpp,h} to use east const style. It also removes two unused headers and simplifies a loop.
2021-06-05Shell: Fix off-by-one error in SyntaxHighlighterMax Wipfli
This changes the Shell syntax highlighter to conform to the now-fixed rendering of syntax highlighting spans in GUI::TextEditor. This also adds some debug output to make debugging easier.
2021-06-05LibGUI: Fix off-by-one error in Lexer tokensMax Wipfli
This changes the INI and GML lexers to conform to the now-fixed rendering of syntax highlighting spans in GUI::TextEditor. The other user of GMLToken::m_end, GMLAutocompleteProvider, has been modified to take into account that end position columns have been incremented by one.
2021-06-05LibGUI: Use CharacterTypes.h and constexpr functions in {INI,GML}LexerMax Wipfli
2021-06-05LibGUI: Use east const style in {INI,GML}Lexer.{cpp,h}Max Wipfli
2021-06-05LibJS: Fix off-by-one error in SyntaxHighlighterMax Wipfli
This changes the JS syntax highlighter to conform to the now-fixed rendering of syntax highlighting spans in GUI::TextEditor.
2021-06-05LibGUI: Fix off-by-one error in rendering of highlighted textMax Wipfli
This fixes an off-by-one error in TextEditor's rendering of the syntax highlighting as generated by Syntax::Highlighter and its subclasses. Before, a single character span was e.g. (0-3) to (0-3), but this was considered invalid by GUI::TextRange. Now, a single character span would be e.g. (0-3) to (0-4). This fix requires all Syntax::Highlighter subclasses to be adjusted, as they all relied on the previous implementation. This will then also fix a bug where single-character HTML tags wouldn't be highlighted.
2021-06-04AK: Verify that functions aren't modified while they're being invokedGunnar Beutner
A Function object should not be set to a different functor while the original functor is currently executing.
2021-06-04AK: Allow deferring clear() for the Function classGunnar Beutner
Ideally a Function should not be clear()ed while it's running. Unfortunately a number of callers do just that and identifying all of them would require inspecting all call sites for operator() and clear(). Instead this adds support for deferring clear() until after the function has finished executing.
2021-06-04Hearts: Don't destroy the animation handler while running itGunnar Beutner
2021-06-04HackStudio: Add comment about lexicographical insertion to ClassViewItamar
2021-06-04HackStudio: Use Node's name when inserting to the ClassView treeItamar
Previously, when traversing the ClassView tree to find the parent of a new node, we used the name of the node's declaration to find the path to the parent in the tree. However, some nodes in the tree do not have a matching declaration, which caused a VERIFY failure. To fix this, we now use the node's name when walking the tree. We can do this because the node's name should be identical to the name of its declaration. Closes #7702.
2021-06-04Solitaire+LibCards: Draw card stacks with rounded cornersTimothy Flynn
Now that the cards have rounded corners, draw the stack box behind the cards with rounded corners as well. This way, the corner of the stack box doesn't peek out from behind the cards. The caveat here is that the "play" card stack now needs to hold a reference to the "waste" stack beneath it so it knows when not to draw its background on top of the waste stack. To faciliate that, the array of card stacks is now a NonnullRefPtrVector so the play stack can store a smart pointer to the waste stack (instead of a raw pointer or reference).
2021-06-04LibGfx: Add helper for painting a rounded rect with equal corner radiiTimothy Flynn
2021-06-04hostname: Handle 'sethostname' errorsMaciej Zygmanowski