Merely assigning `undef' to a scalar does not free the
underlying buffer memory of a scalar.
---
 lib/PublicInbox/SearchIdxShard.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/PublicInbox/SearchIdxShard.pm 
b/lib/PublicInbox/SearchIdxShard.pm
index 20077e08..75521b43 100644
--- a/lib/PublicInbox/SearchIdxShard.pm
+++ b/lib/PublicInbox/SearchIdxShard.pm
@@ -97,7 +97,7 @@ sub index_raw {
                        "\n", $$msgref or die "failed to write shard $!\n";
        } else {
                if ($eml) {
-                       $$msgref = undef;
+                       undef $$msgref;
                } else { # --xapian-only + --sequential-shard:
                        $eml = PublicInbox::Eml->new($msgref);
                }
--
unsubscribe: one-click, see List-Unsubscribe header
archive: https://public-inbox.org/meta/

Reply via email to