plus

3

index 0000000..0c4102e
--- /dev/null
+++ b/install.sh
@@ -0,0 +1,39 @@
+#!/bin/bash
+cd "$(dirname "$0")"
+
+# Including logger
+. lib/logger.bash
+
+# Displaying all the install locations
+Logger__alert "Originator can be installed to any of these locations:"
+counter=1
+IFS=':' read -ra ADDR <<< "$PATH"
+for i in "${ADDR[@]}"; do
+    Logger__log "[$counter]: $i"
+    locations[$counter]=$i
+    (( counter++ ))
+done
+
+# Getting the install location
+Logger__prompt "Enter the number for location to install and press [ENTER]: "
+read install_number
+install_location=${locations[$install_number]}
+
+# Exiting if invalid input
+if [[ $install_location = "" ]]; then
+    Logger__error "Invalid input, exiting"
+    exit
+fi
+
+# Getting current + new directories
+current_location_full=$(pwd)
+current_location=${PWD##*/}
+new_location="/etc/$current_location"
+
+# Moving originator /etc
+sudo mv $current_location_full $new_location
+
+# Creating symlink
+cd "$install_location"
+ln -s "$new_location/originator" .
+
plus

3

--- a/mm/page_alloc.c
+++ b/mm/page_alloc.c
@@ -2115,6 +2115,14 @@ __alloc_pages_may_oom(gfp_t gfp_mask, unsigned int order,
 	}
 
 	/*
+	 * PM-freezer should be notified that there might be an OOM killer on
+	 * its way to kill and wake somebody up. This is too early and we might
+	 * end up not killing anything but false positives are acceptable.
+	 * See freeze_processes.
+	 */
+	note_oom_kill();
+
+	/*
 	 * Go through the zonelist yet one more time, keep very high watermark
 	 * here, this is only to catch a parallel oom killing, we must fail if
 	 * we're still under heavy pressure.
plus

6

--- a/src/controllers/ApiGuardController.php
+++ b/src/controllers/ApiGuardController.php
@@ -46,11 +46,17 @@ public function __construct()
 
             $this->response = new Response($this->manager);
 
-            // This is the $apiMethods declared in the controller
-            $apiMethods = $this->getBeforeFilters()[0]['options']['apiMethods'];
+            // api-guard might not be the only before filter on the controller
+            // loop through any before filters and pull out $apiMethods in the controller
+            $beforeFilters = $this->getBeforeFilters();
+            foreach ($beforeFilters as $filter) {
+                if (!empty($filter['options']['apiMethods'])) {
+                    $apiMethods = $filter['options']['apiMethods'];
+                }
+            }
 
             // This is the actual request object used
-            $request =  Route::getCurrentRequest();
+            $request = Route::getCurrentRequest();
 
             // Let's get the method
             Str::parseCallback(Route::currentRouteAction(), null);
@@ -130,7 +136,7 @@ public function __construct()
                                 // Count the number of requests for this method using this api key
                                 $apiLogCount = ApiLog::where('api_key_id', '=', $this->apiKey->id)
                                     ->where('route', '=', Route::currentRouteAction())
-                                    ->where('method', '=',  $request->getMethod())
+                                    ->where('method', '=', $request->getMethod())
                                     ->where('created_at', '>=', date('Y-m-d H:i:s', $keyIncrementTime))
                                     ->where('created_at', '<=', date('Y-m-d H:i:s'))
                                     ->count();
@@ -163,7 +169,7 @@ public function __construct()
                             } else {
                                 // Count the number of requests for this method
                                 $apiLogCount = ApiLog::where('route', '=', Route::currentRouteAction())
-                                    ->where('method', '=',  $request->getMethod())
+                                    ->where('method', '=', $request->getMethod())
                                     ->where('created_at', '>=', date('Y-m-d H:i:s', $methodIncrementTime))
                                     ->where('created_at', '<=', date('Y-m-d H:i:s'))
                                     ->count();
@@ -184,9 +190,9 @@ public function __construct()
                 $apiLog = new ApiLog;
                 $apiLog->api_key_id = $this->apiKey->id;
                 $apiLog->route = Route::currentRouteAction();
-                $apiLog->method =  $request->getMethod();
+                $apiLog->method = $request->getMethod();
                 $apiLog->params = http_build_query(Input::all());
-                $apiLog->ip_address =  $request->getClientIp();
+                $apiLog->ip_address = $request->getClientIp();
                 $apiLog->save();
             }
         }, ['apiMethods' => $this->apiMethods]);
plus

6

--- a/Tools/UIEditor/Classes/Commands/PasteCommand.h
+++ b/Tools/UIEditor/Classes/Commands/PasteCommand.h
@@ -45,7 +45,7 @@ namespace DAVA
 		virtual void Execute();
 		virtual void Rollback();
 		virtual bool IsUndoRedoSupported() {return true;};
-        virtual HierarchyTreeNode::HIERARCHYTREENODEID GetUndoRedoStackId();
+        virtual HierarchyTreeNode::HIERARCHYTREENODEID GetUndoRedoStackId() const;
 		
 	private:
         int PasteControls(HierarchyTreeNode::HIERARCHYTREENODESLIST*, HierarchyTreeNode *parent);
plus

6

--- a/src/controllers/ApiGuardController.php
+++ b/src/controllers/ApiGuardController.php
@@ -46,11 +46,17 @@ public function __construct()
 
             $this->response = new Response($this->manager);
 
-            // This is the $apiMethods declared in the controller
-            $apiMethods = $this->getBeforeFilters()[0]['options']['apiMethods'];
+            // api-guard might not be the only before filter on the controller
+            // loop through any before filters and pull out $apiMethods in the controller
+            $beforeFilters = $this->getBeforeFilters();
+            foreach ($beforeFilters as $filter) {
+                if (!empty($filter['options']['apiMethods'])) {
+                    $apiMethods = $filter['options']['apiMethods'];
+                }
+            }
 
             // This is the actual request object used
-            $request =  Route::getCurrentRequest();
+            $request = Route::getCurrentRequest();
 
             // Let's get the method
             Str::parseCallback(Route::currentRouteAction(), null);
@@ -130,7 +136,7 @@ public function __construct()
                                 // Count the number of requests for this method using this api key
                                 $apiLogCount = ApiLog::where('api_key_id', '=', $this->apiKey->id)
                                     ->where('route', '=', Route::currentRouteAction())
-                                    ->where('method', '=',  $request->getMethod())
+                                    ->where('method', '=', $request->getMethod())
                                     ->where('created_at', '>=', date('Y-m-d H:i:s', $keyIncrementTime))
                                     ->where('created_at', '<=', date('Y-m-d H:i:s'))
                                     ->count();
@@ -163,7 +169,7 @@ public function __construct()
                             } else {
                                 // Count the number of requests for this method
                                 $apiLogCount = ApiLog::where('route', '=', Route::currentRouteAction())
-                                    ->where('method', '=',  $request->getMethod())
+                                    ->where('method', '=', $request->getMethod())
                                     ->where('created_at', '>=', date('Y-m-d H:i:s', $methodIncrementTime))
                                     ->where('created_at', '<=', date('Y-m-d H:i:s'))
                                     ->count();
@@ -184,9 +190,9 @@ public function __construct()
                 $apiLog = new ApiLog;
                 $apiLog->api_key_id = $this->apiKey->id;
                 $apiLog->route = Route::currentRouteAction();
-                $apiLog->method =  $request->getMethod();
+                $apiLog->method = $request->getMethod();
                 $apiLog->params = http_build_query(Input::all());
-                $apiLog->ip_address =  $request->getClientIp();
+                $apiLog->ip_address = $request->getClientIp();
                 $apiLog->save();
             }
         }, ['apiMethods' => $this->apiMethods]);
plus

6

--- a/lib/GsKit/base/CInput.h
+++ b/lib/GsKit/base/CInput.h
@@ -197,7 +197,7 @@ class CInput : public GsSingleton<CInput>
 	bool isAnalog(const int player);
 	void enableAnalog(const int player, const bool value);
 
-	bool SuperPogo(const int player) { return mSuperPogo[player]; }
+    bool SuperPogo(const int player) { return mSuperPogo[player]; }
 	void setSuperPogo(const int player, const bool value) { mSuperPogo[player] = value; }
 
 	bool ImpossiblePogo(const int player) { return mImpPogo[player]; }
@@ -206,6 +206,12 @@ class CInput : public GsSingleton<CInput>
 	bool AutoGun(const int player) { return mFullyAutomatic[player]; }
 	void setAutoGun(const int player, const bool value) { mFullyAutomatic[player] = value; }
 
+    /**
+     * @brief render will render stuff the input want's to get on the screen.
+     *        These are usually overlay where you can touch or click, like virtual gamepads.
+     */
+    void render();
+
 
 	/**
 	 * \brief	This checks what event has been assigned to the chosen command and builds a string calling it
plus

105

--- a/Source/Core/Core/HW/WiimoteEmu/WiimoteEmu.cpp
+++ b/Source/Core/Core/HW/WiimoteEmu/WiimoteEmu.cpp
@@ -171,7 +171,7 @@ void EmulateSwing(AccelData* const accel
 		(&accel->x)[axis_map[i]] += swing[i] * g_dir[i] * SWING_INTENSITY;
 }
 
-const u16 button_bitmasks[] =
+static const u16 button_bitmasks[] =
 {
 	Wiimote::BUTTON_A,
 	Wiimote::BUTTON_B,
@@ -182,16 +182,16 @@ const u16 button_bitmasks[] =
 	Wiimote::BUTTON_HOME
 };
 
-const u16 dpad_bitmasks[] =
+static const u16 dpad_bitmasks[] =
 {
 	Wiimote::PAD_UP, Wiimote::PAD_DOWN, Wiimote::PAD_LEFT, Wiimote::PAD_RIGHT
 };
-const u16 dpad_sideways_bitmasks[] =
+static const u16 dpad_sideways_bitmasks[] =
 {
 	Wiimote::PAD_RIGHT, Wiimote::PAD_LEFT, Wiimote::PAD_UP, Wiimote::PAD_DOWN
 };
 
-const char* const named_buttons[] =
+static const char* const named_buttons[] =
 {
 	"A", "B", "1", "2", "-", "+", "Home",
 };
plus

5

--- a/vcl/win/source/gdi/salgdi.cxx
+++ b/vcl/win/source/gdi/salgdi.cxx
@@ -36,6 +36,10 @@
 #include "gdiimpl.hxx"
 #include "openglgdiimpl.hxx"
 
+#include <vcl/opengl/OpenGLHelper.hxx>
+
+#include <officecfg/Office/Common.hxx>
+
 #define DITHER_PAL_DELTA                51
 #define DITHER_PAL_STEPS                6
 #define DITHER_PAL_COUNT                (DITHER_PAL_STEPS*DITHER_PAL_STEPS*DITHER_PAL_STEPS)
@@ -479,6 +483,12 @@ void WinSalGraphics::InitGraphics()
     ::SetTextAlign( getHDC(), TA_BASELINE | TA_LEFT | TA_NOUPDATECP );
     ::SetBkMode( getHDC(), WIN32_TRANSPARENT );
     ::SetROP2( getHDC(), R2_COPYPEN );
+
+    OpenGLSalGraphicsImpl* pImpl = dynamic_cast<OpenGLSalGraphicsImpl*>(mpImpl.get());
+    if (pImpl)
+    {
+        pImpl->GetOpenGLContext().init(mhLocalDC, mhWnd);
+    }
 }
 
 void WinSalGraphics::DeInitGraphics()
@@ -578,6 +588,13 @@ WinSalGraphics::WinSalGraphics(WinSalGraphics::Type eType, bool bScreen, HWND hW
     mbFontKernInit(false),
     mnPenWidth(GSL_PEN_WIDTH)
 {
+    static bool bOpenGLPossible = OpenGLHelper::supportsVCLOpenGL();
+    bool bUseOpenGL = bOpenGLPossible && !mbPrinter ? officecfg::Office::Common::VCL::UseOpenGL::get() : false;
+    if (bUseOpenGL)
+        mpImpl.reset(new OpenGLSalGraphicsImpl());
+    else
+        mpImpl.reset(new WinSalGraphicsImpl(*this));
+
     for( int i = 0; i < MAX_FALLBACK; ++i )
     {
         mhFonts[ i ] = 0;
@@ -585,12 +602,6 @@ WinSalGraphics::WinSalGraphics(WinSalGraphics::Type eType, bool bScreen, HWND hW
         mpWinFontEntry[ i ] = NULL;
         mfFontScale[ i ] = 1.0;
     }
-
-    static const char* pEnv = getenv("USE_OPENGL");
-    if (pEnv)
-    {
-        mpImpl.reset(new OpenGLSalGraphicsImpl());
-    }
 }
 
 WinSalGraphics::~WinSalGraphics()
plus

478

--- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp
+++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp
@@ -640,7 +640,6 @@ struct boss_jormungarAI : public BossAI
         me->SetDisplayId(ModelMobile);
         me->RemoveAurasDueToSpell(SPELL_SUBMERGE_0);
         me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE);
-        me->GetMotionMaster()->Clear();
 
         // if the worm was mobile before submerging, make him stationary now
         if (WasMobile)
@@ -721,9 +720,7 @@ class boss_dreadscale : public CreatureScript
 
         struct boss_dreadscaleAI : public boss_jormungarAI
         {
-            boss_dreadscaleAI(Creature* creature) : boss_jormungarAI(creature)
-            {
-            }
+            boss_dreadscaleAI(Creature* creature) : boss_jormungarAI(creature) { }
 
             void Reset() override
             {
plus

104

--- a/Source/Core/VideoBackends/OGL/Render.cpp
+++ b/Source/Core/VideoBackends/OGL/Render.cpp
@@ -1845,17 +1845,15 @@ bool Renderer::SaveScreenshot(const std::string &filename, const TargetRectangle
 {
 	u32 W = back_rc.GetWidth();
 	u32 H = back_rc.GetHeight();
-	u8 *data = new u8[W * 4 * H];
+	std::unique_ptr<u8[]> data(new u8[W * 4 * H]);
 	glPixelStorei(GL_PACK_ALIGNMENT, 1);
 
-	glReadPixels(back_rc.left, back_rc.bottom, W, H, GL_RGBA, GL_UNSIGNED_BYTE, data);
+	glReadPixels(back_rc.left, back_rc.bottom, W, H, GL_RGBA, GL_UNSIGNED_BYTE, data.get());
 
 	// Turn image upside down
-	FlipImageData(data, W, H, 4);
-	bool success = TextureToPng(data, W*4, filename, W, H, false);
-	delete[] data;
+	FlipImageData(data.get(), W, H, 4);
 
-	return success;
+	return TextureToPng(data.get(), W * 4, filename, W, H, false);
 
 }
 
plus

22

--- a/CMB2.php
+++ b/CMB2.php
@@ -117,6 +117,7 @@ public function show_form( $object_id = 0, $object_type = '' ) {
 		$this->nonce_field();
 
 		echo "\n<!-- Begin CMB Fields -->\n";
+
 		/**
 		 * Hook before form table begins
 		 *
@@ -129,6 +130,24 @@ public function show_form( $object_id = 0, $object_type = '' ) {
 		 */
 		do_action( 'cmb2_before_form', $this->cmb_id, $object_id, $object_type, $this );
 
+		/**
+		 * Hook before form table begins
+		 *
+		 * The first dynamic portion of the hook name, $object_type, is the type of object
+		 * you are working with. Usually `post` (this applies to all post-types).
+		 * Could also be `comment`, `user` or `options-page`.
+		 *
+		 * The second dynamic portion of the hook name, $this->cmb_id, is the meta_box id.
+		 *
+		 * @param array  $cmb_id      The current box ID
+		 * @param int    $object_id   The ID of the current object
+		 * @param array  $cmb         This CMB2 object
+		 * @param string $object_type The type of object you are working with.
+		 *	                           Usually `post` (this applies to all post-types).
+		 *	                           Could also be `comment`, `user` or `options-page`.
+		 */
+		do_action( "cmb2_before_{$object_type}_form_{$this->cmb_id}", $object_id, $this, $object_type );
+
 		echo '<div class="cmb2-wrap form-table"><div id="cmb2-metabox-'. sanitize_html_class( $this->cmb_id ) .'" class="cmb2-metabox cmb-field-list">';
 
 		foreach ( $this->prop( 'fields' ) as $field_args ) {
@@ -180,6 +199,24 @@ public function show_form( $object_id = 0, $object_type = '' ) {
 		 * @param array  $cmb         This CMB2 object
 		 */
 		do_action( 'cmb2_after_form', $this->cmb_id, $object_id, $object_type, $this );
+
+		/**
+		 * Hook after form form has been rendered
+		 *
+		 * The dynamic portion of the hook name, $this->cmb_id, is the meta_box id.
+		 *
+		 * The first dynamic portion of the hook name, $object_type, is the type of object
+		 * you are working with. Usually `post` (this applies to all post-types).
+		 * Could also be `comment`, `user` or `options-page`.
+		 *
+		 * @param int    $object_id   The ID of the current object
+		 * @param array  $cmb         This CMB2 object
+		 * @param string $object_type The type of object you are working with.
+		 *	                           Usually `post` (this applies to all post-types).
+		 *	                           Could also be `comment`, `user` or `options-page`.
+		 */
+		do_action( "cmb2_after_{$object_type}_form_{$this->cmb_id}", $object_id, $this );
+
 		echo "\n<!-- End CMB Fields -->\n";
 
 	}
plus

478

--- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp
+++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp
@@ -640,7 +640,6 @@ struct boss_jormungarAI : public BossAI
         me->SetDisplayId(ModelMobile);
         me->RemoveAurasDueToSpell(SPELL_SUBMERGE_0);
         me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE);
-        me->GetMotionMaster()->Clear();
 
         // if the worm was mobile before submerging, make him stationary now
         if (WasMobile)
@@ -721,9 +720,7 @@ class boss_dreadscale : public CreatureScript
 
         struct boss_dreadscaleAI : public boss_jormungarAI
         {
-            boss_dreadscaleAI(Creature* creature) : boss_jormungarAI(creature)
-            {
-            }
+            boss_dreadscaleAI(Creature* creature) : boss_jormungarAI(creature) { }
 
             void Reset() override
             {
plus

4

--- a/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.h
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfUnit.h
@@ -430,7 +430,7 @@ class DwarfUnit {
   }
 
   // getIndexTyDie - Get an anonymous type for index type.
-  DIE *getIndexTyDie() { return IndexTyDie; }
+  DIE *getIndexTyDie();
 
   // setIndexTyDie - Set D as anonymous type for index which can be reused
   // later.
plus

4

--- a/lib/CodeGen/AsmPrinter/DwarfUnit.h
+++ b/lib/CodeGen/AsmPrinter/DwarfUnit.h
@@ -430,7 +430,7 @@ class DwarfUnit {
   }
 
   // getIndexTyDie - Get an anonymous type for index type.
-  DIE *getIndexTyDie() { return IndexTyDie; }
+  DIE *getIndexTyDie();
 
   // setIndexTyDie - Set D as anonymous type for index which can be reused
   // later.
plus

3

--- a/contracthashtool.c
+++ b/contracthashtool.c
@@ -25,6 +25,13 @@ void usage() {
 	printf("If you do not care about privacy, anything may be used, otherwise some random value should be used\n");
 	printf("Note that if the nonce is lost, your ability to redeem funds sent to the resulting address is also lost\n");
 	printf("USAGE: Generate privkey: -c -p <base58 private key> (-d <Contract P2SH/regular address>)|(-a <ASCII Contract text>) -n <nonce>\n");
+	printf("\n");
+	printf("Example: contracthashtool -g -r 5121038695b28f1649c711aedb1fec8df54874334cfb7ddf31ba3132a94d00bdc9715251ae -d mqWkEAFeQdrQvyaWNRn5vijPJeiQAjtxL2\n");
+	printf(" Where 5121038695b28f1649c711aedb1fec8df54874334cfb7ddf31ba3132a94d00bdc9715251ae is a hex-encoded Bitcoin script containing public keys in an obvious format (this one is 1-of-1 raw CHECKMULTISIG)\n");
+	printf(" and mqWkEAFeQdrQvyaWNRn5vijPJeiQAjtxL2 is an address which is used to permute the public keys in the above script.\n");
+	printf(" The holder of the private key in 512103... will then need the nonce, and mqWkEAFeQdrQvyaWNRn5vijPJeiQAjtxL2 to claim the funds.\n");
+	printf(" The holder would then do something like contracthashtool -c -p cMcpaCT6pHkyS4347i4rSmecaQtLiu1eH28NWmBiePn8bi6N4kzh -d mgg7ws62sYGqveQQbTUDF7MoVG7nCo5uLB -n 3a11be476485a6273fad4a0e09117d42\n");
+	printf(" They would then have the private key neccessary to claim the funds sent to the address -g... had generated\n");
 }
 
 int get_pubkeys_from_redeemscript(unsigned char *redeem_script, unsigned int redeem_script_len, unsigned char* pubkeys[]) {
plus

117

--- a/src/calibre/web/feeds/news.py
+++ b/src/calibre/web/feeds/news.py
@@ -157,7 +157,7 @@ class BasicNewsRecipe(Recipe):
     #:
     auto_cleanup_keep = None
 
-    #: Specify any extra :term:`CSS` that should be added to downloaded :term:`HTML` files
+    #: Specify any extra :term:`CSS` that should be added to downloaded :term:`HTML` files.
     #: It will be inserted into `<style>` tags, just before the closing
     #: `</head>` tag thereby overriding all :term:`CSS` except that which is
     #: declared using the style attribute on individual :term:`HTML` tags.
@@ -325,12 +325,14 @@ class BasicNewsRecipe(Recipe):
 
     #: Ignore duplicates of articles that are present in more than one section.
     #: A duplicate article is an article that has the same title and/or URL.
-    #: To ignore articles with the same title, set this to:
-    #: ignore_duplicate_articles = {'title'}
-    #: To use URLs instead, set it to:
-    #: ignore_duplicate_articles = {'url'}
-    #: To match on title or URL, set it to:
-    #: ignore_duplicate_articles = {'title', 'url'}
+    #: To ignore articles with the same title, set this to::
+    #:   ignore_duplicate_articles = {'title'}
+    #:
+    #: To use URLs instead, set it to::
+    #:   ignore_duplicate_articles = {'url'}
+    #:
+    #: To match on title or URL, set it to::
+    #:   ignore_duplicate_articles = {'title', 'url'}
     ignore_duplicate_articles = None
 
     #: If you set this True, then calibre will use javascript to login to the
plus

58

--- a/example/build.js
+++ b/example/build.js
@@ -8,11 +8,11 @@ var path       = require('path')
   , bundlePath = path.join(jsRoot, 'bundle.js')
   ;
 
-browserify()
+browserify({ debug: true })
   .add(es6ify.runtime)
   .transform(es6ify)
   .require(require.resolve('./src/main.js'), { entry: true })
-  .bundle({ debug: true })
+  .bundle()
   .on('error', function (err) { console.error(err); })
   .pipe(fs.createWriteStream(bundlePath));
 
plus

14

--- a/index.js
+++ b/index.js
@@ -26,13 +26,22 @@ module.exports = cssnext
 /**
  * Process a CSS `string`
  *
- * @param {String} string
- * @param {Object} options
- * @return {String}
+ * @param {String} string (optional)
+ * @param {Object} options (optional)
+ * @return {String} if string is given, or {Object} (postcss instance)
  */
 function cssnext(string, options) {
-  // ensure options is an object
-  options = options || {}
+  if (arguments.length === 0) {
+    options = {}
+  }
+  if (arguments.length === 1 && typeof string === "object") {
+    options = string
+    string = undefined
+  }
+  else {
+    options = options || {}
+  }
+
   var features = options.features || {}
 
   // default sourcemap
@@ -58,15 +67,20 @@ function cssnext(string, options) {
     postcss.use(require("csswring").postcss)
   }
 
-  var result = postcss.process(string, options)
+  if (string) {
+    var result = postcss.process(string, options)
 
-  // default behavior, cssnext returns a css string
-  if (options.map === null || options.map === defaultMap) {
-    return result.css
-  }
+    // default behavior, cssnext returns a css string
+    if (options.map === null || options.map === defaultMap) {
+      return result.css
+    }
 
-  // if a specific map has been asked, we are returning css + map
-  return result
+    // if a specific map has been asked, we are returning css + map
+    return result
+  }
+  else {
+    return postcss
+  }
 }
 
 /**
plus

3

--- a/tests/NewsParser_Test.py
+++ b/tests/NewsParser_Test.py
@@ -2,8 +2,8 @@
 # -*- coding: utf-8 -*-
 # @Author: balicanta
 # @Date:   2014-10-25 09:57:26
-# @Last Modified by:   balicanta
-# @Last Modified time: 2014-11-01 21:19:53
+# @Last Modified by:   DinoLai
+# @Last Modified time: 2014-11-02 13:02:12
 
 from NewsParser import NewsParser
 from requests.utils import get_encodings_from_content
@@ -14,7 +14,10 @@
     {"url": "http://world.yam.com/post.php?id=2732",
         "title": "", "author":"", "content": ""},
     {"url": "http://news.ltn.com.tw/news/business/breakingnews/1142153",
-        "title": "101", "author":"", "content": ""}
+        "title": "101", "author":"", "content": ""},
+    {"url": "http://www.coolloud.org.tw/node/80590",
+        "title": "", "author":"", "content": "29"
+    }
 ]
 
 
plus

29

--- a/include/zot.php
+++ b/include/zot.php
@@ -1448,11 +1448,13 @@ function process_delivery($sender,$arr,$deliveries,$relay,$public = false,$reque
 				// Don't do this if it's a relay post as we're the ones who are supposed to have the copy and we don't want the request to loop.
 				// Also don't do this if this comment came from a conversation request packet. It's possible that comments are allowed but posting
 				// isn't and that could cause a conversation fetch loop. We can detect these packets since they are delivered via a 'notify' packet type 
-				// that has a message_id element in the initial zot packet (just like the corresponding 'request' packet type which makes the request). 
+				// that has a message_id element in the initial zot packet (just like the corresponding 'request' packet type which makes the request).
+				// We'll also check the send_stream permission, because if it isn't allowed the top level post is unlikely to be imported and
+				// this is just an exercise in futility.   
 
-				if((! $relay) && (! $request))
+				if((! $relay) && (! $request) && (! $public) && perm_is_allowed($channel['channel_id'],$sender['hash'],'send_stream')) {
 					proc_run('php', 'include/notifier.php', 'request', $channel['channel_id'], $sender['hash'], $arr['parent_mid']);
-
+				}
 				continue;
 			}
 			if($relay) {