]> git.lyx.org Git - lyx.git/commitdiff
Fixup 999fb37e: always run updateMacros when in batch mode
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Thu, 25 Jul 2024 16:30:38 +0000 (18:30 +0200)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Thu, 25 Jul 2024 16:37:50 +0000 (18:37 +0200)
The optimization is useful in GUI mode only, and it turns out that it
creates weird crashes otherwise.

Thanks to Juergen Spitzmuller for the idea.

src/Buffer.cpp

index 59733d852ed13c02af75eb4b1b885ded995ed299..a13c8e5f9f9443a06ce3f757527a15f5ac53745a 100644 (file)
@@ -3922,7 +3922,7 @@ void Buffer::updateMacros() const
                return;
 
        // early exit if the buffer has not changed since last time
-       if (d->update_macros_id_ == d->id_)
+       if (d->gui_ && d->update_macros_id_ == d->id_)
                return;
        d->update_macros_id_ = d->id_;