summaryrefslogtreecommitdiff
path: root/Kernel/Graphics/Console
diff options
context:
space:
mode:
authorLiav A <liavalb@gmail.com>2021-05-17 00:02:47 +0300
committerLinus Groh <mail@linusgroh.de>2021-05-17 00:30:40 +0100
commit02b73cb93d559202d91f8306cb578a65e263466a (patch)
tree52e69f776eb88883f86e38f70ee3458846679907 /Kernel/Graphics/Console
parentca9101e5f0c804eee9cfb44ce770a98a249f75c6 (diff)
downloadserenity-02b73cb93d559202d91f8306cb578a65e263466a.zip
Kernel/Graphics: Be more consistent about arguments passing
This fixes a bug that was reported on this discord server by @ElectrodeYT - due to the confusion of passing arguments in different orders, we messed up and triggered a page fault due to faulty sizes.
Diffstat (limited to 'Kernel/Graphics/Console')
-rw-r--r--Kernel/Graphics/Console/FramebufferConsole.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/Kernel/Graphics/Console/FramebufferConsole.h b/Kernel/Graphics/Console/FramebufferConsole.h
index 336d117367..48574768b7 100644
--- a/Kernel/Graphics/Console/FramebufferConsole.h
+++ b/Kernel/Graphics/Console/FramebufferConsole.h
@@ -14,13 +14,13 @@
namespace Kernel::Graphics {
class FramebufferConsole final : public Console {
public:
- static NonnullRefPtr<FramebufferConsole> initialize(PhysicalAddress, size_t width, size_t height, size_t bpp);
+ static NonnullRefPtr<FramebufferConsole> initialize(PhysicalAddress, size_t width, size_t height, size_t pitch);
virtual size_t bytes_per_base_glyph() const override;
virtual size_t chars_per_line() const override;
- virtual size_t max_column() const { return m_width / 8; }
- virtual size_t max_row() const { return m_height / 8; }
+ virtual size_t max_column() const override { return m_width / 8; }
+ virtual size_t max_row() const override { return m_height / 8; }
virtual bool is_hardware_paged_capable() const override { return false; }
virtual bool has_hardware_cursor() const override { return false; }
@@ -41,7 +41,7 @@ public:
protected:
void clear_glyph(size_t x, size_t y) const;
- FramebufferConsole(PhysicalAddress, size_t width, size_t height, size_t bpp);
+ FramebufferConsole(PhysicalAddress, size_t width, size_t height, size_t pitch);
OwnPtr<Region> m_framebuffer_region;
PhysicalAddress m_framebuffer_address;
size_t m_pitch;