commit 6daece6ef12357cf8d2d09b61f9a9de52abba378
Author: elexis <elexis1@users.noreply.github.com>
Date:   Sat Jan 28 22:15:37 2017 +0100

    Catch registration errors when users try to register accounts too quickly.

diff --git a/gloox/src/registration.cpp b/gloox/src/registration.cpp
index b6188d7..a0f2c4f 100644
--- a/gloox/src/registration.cpp
+++ b/gloox/src/registration.cpp
@@ -1,5 +1,5 @@
 /*
-  Copyright (c) 2005-2016 by Jakob Schröter <js@camaya.net>
+  Copyright (c) 2005-2017 by Jakob Schröter <js@camaya.net>
   This file is part of the gloox library. http://camaya.net/gloox
 
   This software is distributed under a license. The full license
@@ -379,6 +379,9 @@ namespace gloox
         case StanzaErrorNotAllowed:
           m_registrationHandler->handleRegistrationResult( iq.from(), RegistrationNotAllowed );
           break;
+        case StanzaErrorResourceConstraint:
+          m_registrationHandler->handleRegistrationResult( iq.from(), RegistrationConstrained );
+          break;
         default:
           m_registrationHandler->handleRegistrationResult( iq.from(), RegistrationUnknownError );
           break;
diff --git a/gloox/src/registrationhandler.h b/gloox/src/registrationhandler.h
index ada3a0a..db8d227 100644
--- a/gloox/src/registrationhandler.h
+++ b/gloox/src/registrationhandler.h
@@ -1,5 +1,5 @@
 /*
-  Copyright (c) 2005-2016 by Jakob Schröter <js@camaya.net>
+  Copyright (c) 2005-2017 by Jakob Schröter <js@camaya.net>
   This file is part of the gloox library. http://camaya.net/gloox
 
   This software is distributed under a license. The full license
@@ -61,6 +61,9 @@ namespace gloox
                                         * the server. */
     RegistrationNotAllowed,            /**< Password change: The server or service does not allow
                                         * password changes. */
+    RegistrationConstrained,           /**< Resource constraint: The server or recipient lacks the
+                                        * system resources necessary to service the request,for
+                                        * example if users are not allowed to register accounts so quickly. */
     RegistrationUnknownError           /**< An unknown error condition occured. */
   };