mirror of
https://github.com/reddit-archive/reddit.git
synced 2026-04-27 03:00:12 -04:00
Put media_domain warning on stderr to protect MR jobs.
For simple installs of reddit, g.domain == g.media_domain. If this is the case, the app will print a warning at startup. However, this warning was printed to stdout which meant that any jobs (such as the mr_top stuff) using the output of a reddit process would get this warning in their data streams. Bad times.
This commit is contained in:
@@ -424,7 +424,7 @@ class Globals(object):
|
||||
if not self.media_domain:
|
||||
self.media_domain = self.domain
|
||||
if self.media_domain == self.domain:
|
||||
print ("Warning: g.media_domain == g.domain. " +
|
||||
print >> sys.stderr, ("Warning: g.media_domain == g.domain. " +
|
||||
"This may give untrusted content access to user cookies")
|
||||
|
||||
for arg in sys.argv:
|
||||
|
||||
Reference in New Issue
Block a user