https://bz.apache.org/SpamAssassin/show_bug.cgi?id=6456
--- Comment #21 from Mark Martinec <[email protected]> --- > `am_running_on_windows` works but it doesn't pass the tests. Like you said, > it's a circular dependency issue: > > M::S::Logger::Stderr uses M::S::Util uses M::S::Logger uses > M::S::Logger::Stderr > > We have two options: > > 1. Put am_running_on_windows into it's own module (M::S::Util::Win32 ?). > 2. Duplicate the code in M::S::Logger::Stderr > > IMHO, the first option is preferrable. If you agree, I will open an issue > and submit a patch. I think creating a new module just for that purpose is an overkill, especially since it is not necessarily just about Windows, but about a choice of a line terminator. A more general Windows-specific module would be warranted if more platform-specific code would need to be moved there. My preference would be to just duplicate the line from Util.pm use constant RUNNING_ON_WINDOWS => ($^O =~ /^(?:mswin|dos|os2)/oi); into M::S::Logger::Stderr and use the constant - keep it simple - possibly adding a comment explaining the choice. -- You are receiving this mail because: You are the assignee for the bug.
