<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Emmanuel Omulo</title>
    <description>The latest articles on DEV Community by Emmanuel Omulo (@ordinary_techie).</description>
    <link>https://dev.to/ordinary_techie</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4204798%2F99d8badb-61dd-4c8a-86ad-bc04a5a1abc8.jpg</url>
      <title>DEV Community: Emmanuel Omulo</title>
      <link>https://dev.to/ordinary_techie</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ordinary_techie"/>
    <language>en</language>
    <item>
      <title>How I found my first use after free bug. Please let me know what you think.</title>
      <dc:creator>Emmanuel Omulo</dc:creator>
      <pubDate>Sat, 24 Oct 2026 14:28:22 +0000</pubDate>
      <link>https://dev.to/ordinary_techie/how-i-found-my-first-use-after-free-bug-please-let-me-know-what-you-think-a5k</link>
      <guid>https://dev.to/ordinary_techie/how-i-found-my-first-use-after-free-bug-please-let-me-know-what-you-think-a5k</guid>
      <description>&lt;div class="ltag__link--embedded"&gt;
  &lt;div class="crayons-story "&gt;
  &lt;a href="https://dev.to/ordinary_techie/anatomy-of-a-shell-crash-3jm3" class="crayons-story__hidden-navigation-link"&gt;Anatomy of a Shell Crash&lt;/a&gt;


  &lt;div class="crayons-story__body crayons-story__body-full_post"&gt;
    &lt;div class="crayons-story__top"&gt;
      &lt;div class="crayons-story__meta"&gt;
        &lt;div class="crayons-story__author-pic"&gt;

          &lt;a href="/ordinary_techie" class="crayons-avatar  crayons-avatar--l  "&gt;
            &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4204798%2F99d8badb-61dd-4c8a-86ad-bc04a5a1abc8.jpg" alt="ordinary_techie profile" class="crayons-avatar__image"&gt;
          &lt;/a&gt;
        &lt;/div&gt;
        &lt;div&gt;
          &lt;div&gt;
            &lt;a href="/ordinary_techie" class="crayons-story__secondary fw-medium m:hidden"&gt;
              Emmanuel Omulo
            &lt;/a&gt;
            &lt;div class="profile-preview-card relative mb-4 s:mb-0 fw-medium hidden m:inline-block"&gt;
              
                Emmanuel Omulo
                
                
              
              &lt;div id="story-author-preview-content-4910956" class="profile-preview-card__content crayons-dropdown branded-7 p-4 pt-0"&gt;
                &lt;div class="gap-4 grid"&gt;
                  &lt;div class="-mt-4"&gt;
                    &lt;a href="/ordinary_techie" class="flex"&gt;
                      &lt;span class="crayons-avatar crayons-avatar--xl mr-2 shrink-0"&gt;
                        &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4204798%2F99d8badb-61dd-4c8a-86ad-bc04a5a1abc8.jpg" class="crayons-avatar__image" alt=""&gt;
                      &lt;/span&gt;
                      &lt;span class="crayons-link crayons-subtitle-2 mt-5"&gt;Emmanuel Omulo&lt;/span&gt;
                    &lt;/a&gt;
                  &lt;/div&gt;
                  &lt;div class="print-hidden"&gt;
                    
                      Follow
                    
                  &lt;/div&gt;
                  &lt;div class="author-preview-metadata-container"&gt;&lt;/div&gt;
                &lt;/div&gt;
              &lt;/div&gt;
            &lt;/div&gt;

          &lt;/div&gt;
          &lt;a href="https://dev.to/ordinary_techie/anatomy-of-a-shell-crash-3jm3" class="crayons-story__tertiary fs-xs"&gt;&lt;time&gt;Oct 24&lt;/time&gt;&lt;span class="time-ago-indicator-initial-placeholder"&gt;&lt;/span&gt;&lt;/a&gt;
        &lt;/div&gt;
      &lt;/div&gt;

    &lt;/div&gt;

    &lt;div class="crayons-story__indention"&gt;
      &lt;h2 class="crayons-story__title crayons-story__title-full_post"&gt;
        &lt;a href="https://dev.to/ordinary_techie/anatomy-of-a-shell-crash-3jm3" id="article-link-4910956"&gt;
          Anatomy of a Shell Crash
        &lt;/a&gt;
      &lt;/h2&gt;
        &lt;div class="crayons-story__tags"&gt;
            &lt;a class="crayons-tag  crayons-tag--monochrome " href="/t/security"&gt;&lt;span class="crayons-tag__prefix"&gt;#&lt;/span&gt;security&lt;/a&gt;
            &lt;a class="crayons-tag  crayons-tag--monochrome " href="/t/ubuntu"&gt;&lt;span class="crayons-tag__prefix"&gt;#&lt;/span&gt;ubuntu&lt;/a&gt;
            &lt;a class="crayons-tag  crayons-tag--monochrome " href="/t/bash"&gt;&lt;span class="crayons-tag__prefix"&gt;#&lt;/span&gt;bash&lt;/a&gt;
            &lt;a class="crayons-tag  crayons-tag--monochrome " href="/t/linux"&gt;&lt;span class="crayons-tag__prefix"&gt;#&lt;/span&gt;linux&lt;/a&gt;
        &lt;/div&gt;
      &lt;div class="crayons-story__bottom"&gt;
        &lt;div class="crayons-story__details"&gt;
            &lt;a href="https://dev.to/ordinary_techie/anatomy-of-a-shell-crash-3jm3#comments" class="crayons-btn crayons-btn--s crayons-btn--ghost crayons-btn--icon-left flex items-center"&gt;
              

              1&lt;span class="hidden s:inline"&gt;&amp;nbsp;comment&lt;/span&gt;
            &lt;/a&gt;
        &lt;/div&gt;
        &lt;div class="crayons-story__save"&gt;
          &lt;small class="crayons-story__tertiary fs-xs mr-2"&gt;
            4 min read
          &lt;/small&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;/div&gt;


</description>
      <category>cybersecurity</category>
      <category>infosec</category>
      <category>security</category>
    </item>
    <item>
      <title>Anatomy of a Shell Crash</title>
      <dc:creator>Emmanuel Omulo</dc:creator>
      <pubDate>Sat, 24 Oct 2026 14:25:34 +0000</pubDate>
      <link>https://dev.to/ordinary_techie/anatomy-of-a-shell-crash-3jm3</link>
      <guid>https://dev.to/ordinary_techie/anatomy-of-a-shell-crash-3jm3</guid>
      <description>&lt;p&gt;For a few months, I got used to my laptop randomly crashing and dropping me back to the login screen two or three times a day. This was common, and I had incorporated it into my work schedule. The day that finally broke the camel’s back was when my system crashed in the middle of a coding session, while I was working on a time-sensitive feature for a hackathon that I had joined (and won; my teammates and I came in first place). The desktop session abruptly ending meant that all the open apps were terminated, thus interrupting my workflow.&lt;/p&gt;

&lt;p&gt;I decided to finally fix it by troubleshooting what the root cause was. This took me down a rabbit hole, but I was able to pinpoint the culprit: the GNOME Shell extension, &lt;a href="https://extensions.gnome.org/extension/5446/quick-settings-tweaker/" rel="noopener noreferrer"&gt;Quick Settings Tweaks by qwreey&lt;/a&gt;. This is an extension that helps users add Media Controls, Notifications, and Volume Mixer to the quick settings. I had this extension installed on Ubuntu 24.04.4, running GNOME 46 with Wayland.&lt;/p&gt;

&lt;p&gt;My investigation began by getting the system logs and working backwards to see what is happening exactly before the session terminates abruptly and the system returns to the GDM login screen as if the user had logged out. To get the logs generated by the &lt;code&gt;systemd-journald&lt;/code&gt; service, I used the &lt;code&gt;journalctl&lt;/code&gt; command and dumped the result to a text file appropriately named “crashreport.txt”&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;journalctl &lt;span class="nt"&gt;-b&lt;/span&gt; 0 &lt;span class="nt"&gt;--no-pager&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; crashreport.txt

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Since the computer never rebooted, the logs I needed were in the current boot, hence &lt;code&gt;journalctl -b 0&lt;/code&gt;. If we needed the previous boot, we would use &lt;code&gt;journalctl -b -1&lt;/code&gt;. The &lt;code&gt;--no-pager&lt;/code&gt; is to instruct journalctl to output as a single stream and not use an interactive tool like &lt;code&gt;less&lt;/code&gt;, which would force me to scroll manually.&lt;/p&gt;

&lt;p&gt;The first thing after opening the log file was to navigate to the time the crash happened and check the activity right before systemd started shutting down services. What stood out was that the kernel logged a segmentation fault in the gnome shell process:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kernel: gnome-shell[5937]: segfault at 0 ip 00007468b779ad6d sp 00007fff1821cff0 error 4 in libgjs.so.0.0.0[31d6d,7468b7789000+a6000] likely on CPU 6 (core 3, socket 0)

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In simpler terms, the system kernel recorded a user-mode read violation error &lt;strong&gt;&lt;em&gt;(error 4)&lt;/em&gt;&lt;/strong&gt; caused by GNOME Shell running under process ID 5937 due to a segmentation fault &lt;strong&gt;&lt;em&gt;(segfault at 0)&lt;/em&gt;&lt;/strong&gt;. At “0” means GNOME Shell tried to read/write to a null memory address, which is the classic signature of dereferencing a NULL pointer. The faulting instructions are in the file &lt;code&gt;libgjs&lt;/code&gt;, the shared engine that executes both the Shell’s own JavaScript and every installed extension.&lt;/p&gt;

&lt;p&gt;Everything else that followed in the journal was a consequence of that one process dying.&lt;/p&gt;

&lt;p&gt;Although descriptive, this was still not enough to pinpoint which shell extension was responsible for the crash. Due to my naivety, I was quick to blame the first shell extension app closest to the crash, which was clipboard-history with 253 instances of lines like:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;gnome-shell[5937]: Object St.Button (0x5956b5afe0e0), has been already disposed — impossible to access it. This might be caused by the object having been destroyed from C code using something such as destroy(), dispose(), or remove() vfuncs.

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To be fair, other extensions were erroring out with a similar message. There were hundreds from different installed extensions. My next step was to scroll through them all and find the one that started it. This meant searching through the whole boot and not just the crash window. Counting extension names in the stack frames gave me this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3d0j4rou9vhynejkzxde.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2F3d0j4rou9vhynejkzxde.png" alt="Summary of total errors" width="800" height="199"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Each incident logged the same pair of lines: an “already disposed” error on an St.Button, then a GObject complaint that the instance “has no handler” for a signal ID, meaning something tried to disconnect a signal from a widget that no longer existed.&lt;/p&gt;

&lt;p&gt;All four occurrences carried an identical stack trace (home path anonymised for obvious reasons):&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Flw2mtt4ihpvd4sfjityr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Flw2mtt4ihpvd4sfjityr.png" alt="Stack trace errors" width="798" height="168"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Read bottom to top: the Shell’s extension system calls the extension, which calls a cleanup helper, which touches a widget that is already gone. The &lt;code&gt;extensionSystem.js&lt;/code&gt; frames suggest this was the extension’s enable/disable lifecycle code, not user interaction.&lt;/p&gt;

&lt;p&gt;After deep analysis, I narrowed it down to the extension Quick Settings Tweaks as the genesis of the crashes. My working explanation is that several extensions place widgets in the same top-bar and Quick Settings area. If one extension destroys a shared container or widget twice, or disconnects signals from objects that are already gone, other extensions holding references into that area start touching freed objects. Three times the damage stayed small. The fourth time it spread, and a NULL dereference inside GJS ended the process.&lt;/p&gt;

&lt;p&gt;Why the shell crash felt like a logout is because in Wayland, there is no separate window manager and display server to fail independently. GNOME Shell is the compositor, so its death takes every client connection with it. GDM notices that the session’s compositor is gone, closes the session, and starts a new greeter. To the user, the sequence is indistinguishable from logging out, except that unsaved work is lost.&lt;/p&gt;

&lt;p&gt;To remediate the situation, I uninstalled the extension. The crash never happened again, which confirmed it as the cause. I have since upgraded from Ubuntu 24.04 (GNOME 46) to Ubuntu 26.04 (GNOME 50), and the desktop has stayed stable. The removal test shows who caused the crash, not how. I never examined a core dump, so that part stays a hypothesis.The removal test shows who caused the crash, not how. I never examined a core dump, so that part stays a hypothesis.&lt;/p&gt;

&lt;p&gt;I tried to report the issue to the extension author, but it seems the project has been abandoned and is no longer maintained. For everyone who still needs the features, you can try &lt;a href="https://github.com/jstockdale/quick-settings-tweaks/releases/tag/v2.2-offx1.1" rel="noopener noreferrer"&gt;Quick Settings Tweaks v2.2-offx1.1&lt;/a&gt;. It is a fork of the original project but is maintained and supports the latest GNOME Shell versions.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://docs.google.com/document/d/1CbxNqrbKXYMDWgXuvnANeb_QHAR6FATECUTYWyJJtpM/edit?usp=sharing" rel="noopener noreferrer"&gt;Link to the full Technical Report&lt;/a&gt;&lt;/p&gt;

</description>
      <category>security</category>
      <category>ubuntu</category>
      <category>bash</category>
      <category>linux</category>
    </item>
  </channel>
</rss>
