Bug 6373 - [review] avoid user checks for win32
Summary: [review] avoid user checks for win32
Status: RESOLVED FIXED
Alias: None
Product: Spamassassin
Classification: Unclassified
Component: spamc/spamd (show other bugs)
Version: 3.3.0
Hardware: Other Windows XP
: P2 major
Target Milestone: 3.3.1
Assignee: SpamAssassin Developer Mailing List
URL:
Whiteboard:
Keywords:
: 6442 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-03-11 09:34 UTC by Daniel Lemke
Modified: 2018-09-01 00:29 UTC (History)
2 users (show)



Attachment Type Modified Status Actions Submitter/CLA Status
spamd changes to avoid user checks application/octet-stream None Daniel Lemke [HasCLA]

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Lemke 2010-03-11 09:34:55 UTC
Created attachment 4708 [details]
spamd changes to avoid user checks

Sorry for spamming you guys with all these patches in the last few weeks but I'm nearly finished now and looking forward to publish an updated howto SA win32 for the wiki with only minor code changes necessary.

The only thing left is some signal handling which hasn't been tested extensively.


But back to topic:
I had to bypass some lines that check if spamd is running as root user since "$> == 0" is always true for windows.

Also the getpwnam function isn't implemented and had to be changed to a fixed value.

See the patch attached for more details.

Daniel
Comment 1 Mark Martinec 2010-03-11 11:24:49 UTC
+1
Comment 2 Kevin A. McGrail 2010-03-11 13:37:52 UTC
+1 KAM

Is this a trivial patch or do we need a CLA, etc?
Comment 3 Justin Mason 2010-03-11 14:21:39 UTC
+1 looks ok to me.

I don't think we need a CLA -- the changes are pretty tiny.  don't worry about spamming us Daniel; this way we get to complain if we don't like the look of the patches ;)
Comment 4 Mark Martinec 2010-03-11 14:29:29 UTC
> Is this a trivial patch or do we need a CLA, etc?

I'd say so, it is certainly very straightforward.


trunk:

Bug 6373: avoid user checks for win32;
plus: import a sub am_running_on_windows() where it is
more heavily used, reducing the clutter in calls
Sending        lib/Mail/SpamAssassin/BayesStore/DBM.pm
Sending        lib/Mail/SpamAssassin/Dns.pm
Sending        lib/Mail/SpamAssassin/Util.pm
Sending        lib/Mail/SpamAssassin.pm
Sending        spamd/spamd.raw
Transmitting file data .....
Committed revision 921869.
Comment 5 Mark Martinec 2010-03-11 14:44:01 UTC
3.3:

Bug 6373: avoid user checks for win32;
plus: import a sub am_running_on_windows() where it is
more heavily used, reducing the clutter in calls
Sending        lib/Mail/SpamAssassin/BayesStore/DBM.pm
Sending        lib/Mail/SpamAssassin/Dns.pm
Sending        lib/Mail/SpamAssassin/Util.pm
Sending        lib/Mail/SpamAssassin.pm
Sending        spamd/spamd.raw
Transmitting file data .....
Committed revision 921874.
Comment 6 Bill Cole 2018-09-01 00:29:19 UTC
*** Bug 6442 has been marked as a duplicate of this bug. ***