plus

3

--- a/Sunshine/app/src/main/java/com/aafr/alfonso/sunshine/app/SettingsActivity.java
+++ b/Sunshine/app/src/main/java/com/aafr/alfonso/sunshine/app/SettingsActivity.java
@@ -29,11 +29,12 @@
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
         // Add 'general' preferences, defined in the XML file
-        // TODO: Add preferences from XML
+
+        addPreferencesFromResource(R.xml.pref_general);
 
         // For all preferences, attach an OnPreferenceChangeListener so the UI summary can be
         // updated when the preference changes.
-        // TODO: Add preferences
+        bindPreferenceSummaryToValue(findPreference(getString(R.string.pref_location_key)));
     }
 
     /**
plus

3284

--- a/Library/Formula/avra.rb
+++ b/Library/Formula/avra.rb
@@ -5,6 +5,13 @@ class Avra < Formula
   url 'https://downloads.sourceforge.net/project/avra/1.3.0/avra-1.3.0.tar.bz2'
   sha1 '7ad7d168b02107d4f2d72951155798c2fd87d5a9'
 
+  bottle do
+    cellar :any
+    sha1 "e2421ffa73e2cce740fdf6d03083931511ba729c" => :yosemite
+    sha1 "93af396271220b7b110c8506affea3703c914482" => :mavericks
+    sha1 "9a850a1c6ca9634a2a8e33b1f399d272cf2c78ee" => :mountain_lion
+  end
+
   depends_on "autoconf" => :build
   depends_on "automake" => :build
 
@@ -17,6 +24,7 @@ def install
       system "./configure", "--prefix=#{prefix}"
       system "make install"
     end
+    (share/"avra").install Dir["includes/*"]
   end
 
   test do
plus

5

index 0000000..4be36dd
--- /dev/null
+++ b/Logic/Support/General.cs
@@ -0,0 +1,23 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Net.Security;
+using System.Security.Cryptography.X509Certificates;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace Swarmops.Logic.Support
+{
+    public class SupportFunctions
+    {
+        public static void DisableSslCertificateChecks()
+        {
+            // X.509 is SO SO SO broken. The reason we do this, btw, is that mono doesn't come with root certs. At all.
+
+            // This disables certificate checking completely and accepts ALL certificates.
+
+            System.Net.ServicePointManager.ServerCertificateValidationCallback +=
+                (sender, certificate, chain, sslPolicyErrors) => true;
+        }
+    }
+}
plus

3

--- a/ws.py
+++ b/ws.py
@@ -13,6 +13,7 @@
 import pickle
 from datetime import datetime
 import traceback
+import requests
 
 class UtcDate:
     startup_utc_date = datetime.utcnow()
@@ -458,7 +459,20 @@ def watcher(ev,wrap2):
             ev.message.reply("unblocked")
     if(content_lower.startswith("!!/pull")):
         if(isPrivileged(ev_room, ev_user_id)):
-            os._exit(3)
+            r = requests.get('https://api.github.com/repos/Charcoal-SE/SmokeDetector/git/refs/heads/master')
+            latest_sha = r.json()["object"]["sha"]
+            r = requests.get('https://api.github.com/repos/Charcoal-SE/SmokeDetector/statuses/' + latest_sha)
+            states = []
+            for status in r.json():
+                state = status["state"]
+                states.append(state)
+            if ("succeeded" in states):
+                ev.message.reply("Pulling latest from master -- CI build passed.")
+                os._exit(3)
+            elif ("error" in states or "failure" in states):
+                ev.message.reply("CI build failed! :( Please check your commit.")
+            elif ("pending" in states or not states):
+                ev.message.reply("CI build is still pending, wait until the build has finished and then pull again.")
 
 def isPrivileged(room_id_str, user_id_str):
     return room_id_str in GlobalVars.privileged_users and user_id_str in GlobalVars.privileged_users[room_id_str]
plus

107

--- a/src/main/java/org/spongepowered/api/entity/explosive/FusedExplosive.java
+++ b/src/main/java/org/spongepowered/api/entity/explosive/FusedExplosive.java
@@ -26,15 +26,12 @@
 
 /**
  * Represents an explosive that detonates after its fuse has expired.
+ * <p>A FusedExplosive already implies that it has been ignited and will
+ * explode after the fuse has expired.</p>
  */
 public interface FusedExplosive extends Explosive {
 
     /**
-     * Ignites this explosive to detonate after some fuse duration in ticks.
-     */
-    void ignite();
-
-    /**
      * Ignites this explosive to detonate after the given fuse ticks.
      *
      * @param fuseTicks The ticks to set the fuse
plus

72

--- a/cyclone/httpclient.py
+++ b/cyclone/httpclient.py
@@ -132,7 +132,7 @@ def fetch(self):
             else:
                 break
 
-        response.error = None
+        response.error = response.code >= 400
         response.headers = dict(response.headers.getAllRawHeaders())
         # HTTP 204 and 304 responses have no body
         # http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
plus

3

--- a/src/audio/audio_system.cpp
+++ b/src/audio/audio_system.cpp
@@ -14,8 +14,6 @@
 #include <stdexcept>
 #include <string>
 
-#include "portaudiocpp/PortAudioCpp.hxx"
-
 #include "../errors.hpp"
 #include "../messages.h"
 #include "audio.hpp"
@@ -30,7 +28,7 @@
 
 PaAudioSystem::PaAudioSystem() : device_id(-1)
 {
-	portaudio::System::initialize();
+	AudioSink::InitLibrary();
 
 #ifdef WITH_MP3
 	mpg123_init();
@@ -39,7 +37,7 @@ PaAudioSystem::PaAudioSystem() : device_id(-1)
 
 PaAudioSystem::~PaAudioSystem()
 {
-	portaudio::System::terminate();
+	AudioSink::CleanupLibrary();
 
 #ifdef WITH_MP3
 	mpg123_exit();
@@ -48,24 +46,12 @@ PaAudioSystem::~PaAudioSystem()
 
 std::vector<AudioSystem::Device> PaAudioSystem::GetDevicesInfo()
 {
-	auto &pa = portaudio::System::instance();
-	std::vector<AudioSystem::Device> list;
-
-	for (auto d = pa.devicesBegin(); d != pa.devicesEnd(); ++d) {
-		if (!d->isInputOnlyDevice()) {
-			list.emplace_back(d->index(), d->name());
-		}
-	}
-	return list;
+	return AudioSink::GetDevicesInfo();
 }
 
 bool PaAudioSystem::IsOutputDevice(int id)
 {
-	auto &pa = portaudio::System::instance();
-	if (id < 0 || pa.deviceCount() <= id) return false;
-
-	portaudio::Device &dev = pa.deviceByIndex(id);
-	return !dev.isInputOnlyDevice();
+	return AudioSink::IsOutputDevice(id);
 }
 
 void PaAudioSystem::SetDeviceID(int id)
plus

140

--- a/CefSharp/ResourceHandler.cs
+++ b/CefSharp/ResourceHandler.cs
@@ -119,6 +119,27 @@ public static ResourceHandler FromString(string text, Encoding encoding, bool in
             return new ResourceHandler { Stream = GetStream(text, encoding, includePreamble) };
         }
 
+        /// <summary>
+        /// Gets the resource from a stream.
+        /// </summary>
+        /// <param name="stream">A stream of the resource.</param>
+        /// <returns></returns>
+        public static ResourceHandler FromStream(Stream stream)
+        {
+            return new ResourceHandler() { Stream = stream };
+        }
+
+        /// <summary>
+        /// Gets the resource from a stream.
+        /// </summary>
+        /// <param name="stream">A stream of the resource.</param>
+        /// <param name="mimeType">Type of MIME.</param>
+        /// <returns></returns>
+        public static ResourceHandler FromStream(Stream stream, string mimeType)
+        {
+            return new ResourceHandler(mimeType) { Stream = stream };
+        }
+
         private static MemoryStream GetStream(string text, Encoding encoding, bool includePreamble)
         {
             if (includePreamble)
plus

19

--- a/rx/concurrency/catchscheduler.py
+++ b/rx/concurrency/catchscheduler.py
@@ -19,16 +19,16 @@ def schedule_now(self, state, action):
 
         return self._scheduler.scheduleWithState(state, self._wrap(action))
 
-    def schedule_relative(self, state, due_time, action):
+    def schedule_relative(self, state, duetime, action):
         """Schedules an action to be executed after duetime."""
 
-        return self._scheduler.schedule_relative(due_time, self._wrap(action),
+        return self._scheduler.schedule_relative(duetime, self._wrap(action),
                                                  state=state)
 
-    def schedule_absolute(self, state, due_time, action):
+    def schedule_absolute(self, state, duetime, action):
         """Schedules an action to be executed at duetime."""
 
-        return self._scheduler.schedule_absolute(due_time, self._wrap(action),
+        return self._scheduler.schedule_absolute(duetime, self._wrap(action),
                                                  state=state)
 
     def _clone(self, scheduler):
@@ -60,11 +60,11 @@ def schedule_periodic(self, period, action, state=None):
         d = SingleAssignmentDisposable()
         failed = [False]
 
-        def action(state1):
+        def periodic_action(periodic_state):
             if failed[0]:
                 return None
             try:
-                return action(state1)
+                return action(periodic_state)
             except Exception as ex:
                 failed[0] = True
                 if not self._handler(ex):
@@ -72,5 +72,5 @@ def action(state1):
                 d.dispose()
                 return None
 
-        d.disposable = self._scheduler.schedule_periodic(action, period, state)
+        d.disposable = self._scheduler.schedule_periodic(periodic_action, period, state)
         return d
plus

3

--- a/config/routes.rb
+++ b/config/routes.rb
@@ -1,4 +1,11 @@
 Rails.application.routes.draw do
+
+  root to: 'home#index'
+
+
+
+
+  
   # The priority is based upon order of creation: first created -> highest priority.
   # See how all your routes lay out with "rake routes".
 
plus

7

--- a/router_result.c
+++ b/router_result.c
@@ -188,7 +188,7 @@ bool router_result_to_plan (struct plan *plan, router_t *router, router_request_
                 uint32_t vj_index;
 
                 jp = router->tdata->journey_patterns + router->states_back_journey_pattern[i_ride];
-                vj_index = jp->vj_ids_offset + router->states_back_journey_pattern[i_ride];
+                vj_index = jp->vj_ids_offset + router->states_back_vehicle_journey[i_ride];
                 vj = router->tdata->vjs + vj_index;
 
                 if (router->tdata->vj_stoptimes[vj_index] &&
plus

5

--- a/socrates/migrateSoCraTesDB.js
+++ b/socrates/migrateSoCraTesDB.js
@@ -5,7 +5,7 @@ var _ = require('lodash');
 var async = require('async');
 var beans = require('simple-configure').get('beans');
 var participantService = beans.get('participantService');
-var groupsAndMembersService = beans.get('groupsAndMembersService');
+var memberstore = beans.get('memberstore');
 
 var really = process.argv[2];
 var doSave = process.argv[3] === 'doSave';
@@ -16,17 +16,13 @@ if (!really || really !== 'really') {
 }
 
 var count = 1;
-groupsAndMembersService.getAllUsersWithTheirGroups(function (err, members) {
+memberstore.socratesOnlyMembers(function (err, members) {
   async.each(members,
     function (member, callback) {
-      // set to true if member is in SoCraTes group
-      var isSocratesVisitor = _.pluck(member.subscribedGroups, 'id').indexOf('socrates2014') > -1;
-      if (isSocratesVisitor) {
-        console.log('Socrates-Visitor + ' + count + ': ' + member.displayName());
-        count = count + 1;
-        if (doSave) {
-          return participantService.createParticipantIfNecessaryFor(member.id(), callback);
-        }
+      console.log('Socrates-Only ' + count + ': ' + member.displayName());
+      count = count + 1;
+      if (doSave) {
+        return participantService.createParticipantIfNecessaryFor(member.id(), callback);
       }
       callback(null, null);
     },
plus

38

--- a/include/solarus/entities/ParallaxScrollingTilePattern.h
+++ b/include/solarus/entities/ParallaxScrollingTilePattern.h
@@ -52,7 +52,7 @@ class ParallaxScrollingTilePattern: public SimpleTilePattern {
     virtual bool is_animated() const override;
     virtual bool is_drawn_at_its_position() const override;
 
-    static constexpr int ratio = 2; /** Distance made by the viewport to move the tile pattern of 1 pixel. */
+    static constexpr int ratio = 2;  /**< Distance made by the viewport to move the tile pattern of 1 pixel. */
 
 };
 
plus

17

--- a/libraries/blockchain/chain_interface.cpp
+++ b/libraries/blockchain/chain_interface.cpp
@@ -57,14 +57,12 @@ namespace bts { namespace blockchain {
        for( const char& c : symbol )
        {
            sub_symbol_size++;
-           ulog("char is: ${c}, count is: ${s}", ("c", std::string(1, c))("s", sub_symbol_size));
            if( c == '.' )
            {
               if( sub_symbol_size < BTS_BLOCKCHAIN_MIN_SYMBOL_SIZE
                  || sub_symbol_size > BTS_BLOCKCHAIN_MAX_SYMBOL_SIZE )
                  return false;
               sub_symbol_size = 0;
-              ulog("it's a dot, resetting subsize to 0");
 
               if( ++dots > 1 )
                  return false;
@@ -73,9 +71,12 @@ namespace bts { namespace blockchain {
            {
                if( !std::isalnum( c, std::locale::classic() ) || !std::isupper( c, std::locale::classic() ) )
                    return false;
-              ulog("it's not a dot and passes basic test");
            }
        }
+       if( sub_symbol_size < BTS_BLOCKCHAIN_MIN_SYMBOL_SIZE
+          || sub_symbol_size > BTS_BLOCKCHAIN_MAX_SYMBOL_SIZE )
+          return false;
+
        if( symbol.back() == '.' ) return false;
        if( symbol.front() == '.' ) return false;
 
plus

3

--- a/src/com/harry/Rotor.java
+++ b/src/com/harry/Rotor.java
@@ -3,19 +3,21 @@
 /**
  * Created by Harry on 26/12/14.
  */
-public class Rotor {
+public class Rotor extends EncryptionPart{
 	//The type of rotor to use.
 	Type type;
 	//The position of the rotor: a number between 0 and 25.
 	int position;
+	//The next part of the encryption.
+	EncryptionPart nextPart;
 
 	/**
 	 * A constructor that defaults the position of the rotor to 0.
 	 * @param type
 	 */
-	public Rotor(Type type)
+	public Rotor(Type type,EncryptionPart nextPart)
 	{
-		this(type,0);
+		this(type,nextPart,0);
 	}
 
 	/**
@@ -23,9 +25,10 @@ public Rotor(Type type)
 	 * @param type , the type of rotor to use from the given list.
 	 * @param position , the position to set the rotor to.
 	 */
-	public Rotor(Type type, int position)
+	public Rotor(Type type, EncryptionPart nextPart, int position)
 	{
 		this.type = type;
+		this.nextPart = nextPart;
 	}
 
 	/**
@@ -43,6 +46,15 @@ public char getPair(char input)
 	}
 
 	/**
+	 * Clicks the rotor one place, so that a character is paired to another input character.
+	 */
+	@Override
+	public void incrementPosition()
+	{
+		position = position++ % 26;
+	}
+
+	/**
 	 * Contains the rotor settings so that the 
plus

7

--- a/src/android/android_display.c
+++ b/src/android/android_display.c
@@ -21,6 +21,7 @@
 #include "allegro5/internal/aintern_events.h"
 #include "allegro5/internal/aintern_opengl.h"
 #include "allegro5/internal/aintern_shader.h"
+#include "allegro5/internal/aintern_pixels.h"
 
 #include "EGL/egl.h"
 
@@ -828,10 +829,8 @@ static void android_acknowledge_drawing_halt(ALLEGRO_DISPLAY *dpy)
 static void android_broadcast_resume(ALLEGRO_DISPLAY_ANDROID *d)
 {
    ALLEGRO_DEBUG("Broadcasting resume");
-   al_lock_mutex(d->mutex);
    d->resumed = true;
    al_broadcast_cond(d->cond);
-   al_unlock_mutex(d->mutex);
    ALLEGRO_DEBUG("done broadcasting resume");
 }
 
@@ -873,7 +872,7 @@ static void android_acknowledge_drawing_resume(ALLEGRO_DISPLAY *dpy)
          !(bitmap_flags & ALLEGRO_NO_PRESERVE_TEXTURE))
       {
          int format = _al_pixel_format_is_compressed(format) ? ALLEGRO_PIXEL_FORMAT_ABGR_8888_LE : format;
-         _al_ogl_upload_bitmap_memory(bmp, bmp->memory_format, bmp->memory);
+         _al_ogl_upload_bitmap_memory(bmp, format, bmp->memory);
          bmp->dirty = false;
       }
    }
plus

3

--- a/Shape.java
+++ b/Shape.java
@@ -48,6 +48,11 @@ public boolean isInStack () {
 		return (state.equals("insideStack"));
 	}
 	
+	public void setPosition (int x , int y) {
+		this.x = x;
+		this.y = y;
+	}
+	
 	public boolean intersects(Shape shape) {
 		Area shapeArea = shape.getArea();
 		Area myArea = getArea();
plus

196

--- a/modules/Control_mac.js
+++ b/modules/Control_mac.js
@@ -19,7 +19,7 @@ module.exports = (function() {
   function mouseDown(self, cmd, events) {
     this.fireEvent('mousedown');
     self.super('mouseDown',events);
-    if(options.mouseDownBlocks) {
+    if(this.private.options.mouseDownBlocks) {
       this.fireEvent('mouseup');
       this.fireEvent('click');
     }
@@ -69,6 +69,18 @@ module.exports = (function() {
   function Control(options) {
     options = options || {};
     options.delegates = options.delegates || [];
+
+    Object.defineProperty(this, 'private', {
+      configurable:false,
+      enumerable:false,
+      value:{
+        events:{}, parent:null, trackingArea:null, needsMouseTracking:0,
+        user:{width:null, height:null, left:null, right:null, top:null, bottom:null, center:null, middle:null },
+        constraints:{ width:null, height:null, left:null, right:null, top:null, bottom:null, center:null, middle:null },
+        states:{}, options:options
+      }
+    });
+
     if(!options.nonStandardEvents) {
       options.delegates = options.delegates.concat([
         /**
@@ -128,17 +140,6 @@ module.exports = (function() {
       ]);
     }
 
-    Object.defineProperty(this, 'private', {
-      configurable:false,
-      enumerable:false,
-      value:{
-        events:{}, parent:null, trackingArea:null, needsMouseTracking:0,
-        user:{width:null, height:null, left:null, right:null, top:null, bottom:null, center:null, middle:null },
-        constraints:{ width:null, height:null, left:null, right:null, top:null, bottom:null, center:null, middle:null },
-        states:{}
-      }
-    });
-
     var nativeViewExtended = this.nativeViewClass.extend(this.nativeViewClass.getName()+Math.round(Math.random()*10000000));
     options.delegates.forEach(function(item) {
       nativeViewExtended.addMethod(item[0],item[1],item[2]);
plus

5

--- a/app/src/main/java/com/nightscout/android/settings/SettingsActivity.java
+++ b/app/src/main/java/com/nightscout/android/settings/SettingsActivity.java
@@ -1,9 +1,5 @@
 package com.nightscout.android.settings;
 
-import com.google.common.base.Optional;
-import com.google.zxing.integration.android.IntentIntegrator;
-import com.google.zxing.integration.android.IntentResult;
-
 import android.app.AlertDialog;
 import android.content.Context;
 import android.content.Intent;
@@ -16,6 +12,9 @@
 import android.support.v4.app.NavUtils;
 import android.view.MenuItem;
 
+import com.google.common.base.Optional;
+import com.google.zxing.integration.android.IntentIntegrator;
+import com.google.zxing.integration.android.IntentResult;
 import com.nightscout.android.R;
 import com.nightscout.android.barcode.AndroidBarcode;
 import com.nightscout.android.preferences.AndroidPreferences;
@@ -71,9 +70,7 @@ protected static void showValidationError(final Context context, final String me
     @Override
     public void onActivityResult(int requestCode, int resultCode, Intent data) {
         IntentResult scanResult = IntentIntegrator.parseActivityResult(requestCode, resultCode, data);
-        NightscoutPreferences prefs = new AndroidPreferences(
-            this,
-            mainPreferenceFragment.getPreferenceManager().getSharedPreferences());
+        NightscoutPreferences prefs = new AndroidPreferences(this);
         if (scanResult != null && scanResult.getContents() != null) {
             NSBarcodeConfig barcode = new NSBarcodeConfig(scanResult.getContents());
             if (barcode.hasMongoConfig()) {
@@ -109,7 +106,7 @@ public void onCreate(Bundle savedInstanceState) {
 
         private void setupVersionNumbers() {
             try {
-                PackageInfo pInfo = null;
+                PackageInfo pInfo;
                 pInfo = getActivity().getPackageManager().getPackageInfo(
                         getActivity().getPackageName(), 0);
                 findPreference("about_version_number").setSummary(pInfo.versionName);
plus

65

--- a/sound/pci/hda/hda_controller.c
+++ b/sound/pci/hda/hda_controller.c
@@ -1922,10 +1922,18 @@ int azx_mixer_create(struct azx *chip)
 EXPORT_SYMBOL_GPL(azx_mixer_create);
 
 
+static bool is_input_stream(struct azx *chip, unsigned char index)
+{
+	return (index >= chip->capture_index_offset &&
+		index < chip->capture_index_offset + chip->capture_streams);
+}
+
 /* initialize SD streams */
 int azx_init_stream(struct azx *chip)
 {
 	int i;
+	int in_stream_tag = 0;
+	int out_stream_tag = 0;
 
 	/* initialize each stream (aka device)
 	 * assign the starting bdl address to each stream (device)
@@ -1938,9 +1946,21 @@ int azx_init_stream(struct azx *chip)
 		azx_dev->sd_addr = chip->remap_addr + (0x20 * i + 0x80);
 		/* int mask: SDI0=0x01, SDI1=0x02, ... SDO3=0x80 */
 		azx_dev->sd_int_sta_mask = 1 << i;
-		/* stream tag: must be non-zero and unique */
 		azx_dev->index = i;
-		azx_dev->stream_tag = i + 1;
+
+		/* stream tag must be unique throughout
+		 * the stream direction group,
+		 * valid values 1...15
+		 * use separate stream tag if the flag
+		 * AZX_DCAPS_SEPARATE_STREAM_TAG is used
+		 */
+		if (chip->driver_caps & AZX_DCAPS_SEPARATE_STREAM_TAG)
+			azx_dev->stream_tag =
+				is_input_stream(chip, i) ?
+				++in_stream_tag :
+				++out_stream_tag;
+		else
+			azx_dev->stream_tag = i + 1;
 	}
 
 	return 0;