[Python-modules-commits] r23570 - in packages/python-django/branches/squeeze/debian/patches (2 files)

hertzog at users.alioth.debian.org hertzog at users.alioth.debian.org
Sun Feb 24 16:06:35 UTC 2013


    Date: Sunday, February 24, 2013 @ 16:06:33
  Author: hertzog
Revision: 23570

Update backported patches to fix some issues

Modified:
  packages/python-django/branches/squeeze/debian/patches/21_fix_redirect_poisoning.diff
  packages/python-django/branches/squeeze/debian/patches/25_limit_number_of_forms_in_formset.diff

Modified: packages/python-django/branches/squeeze/debian/patches/21_fix_redirect_poisoning.diff
===================================================================
--- packages/python-django/branches/squeeze/debian/patches/21_fix_redirect_poisoning.diff	2013-02-24 15:14:40 UTC (rev 23569)
+++ packages/python-django/branches/squeeze/debian/patches/21_fix_redirect_poisoning.diff	2013-02-24 16:06:33 UTC (rev 23570)
@@ -36,7 +36,7 @@
              auth_login(request, form.get_user())
  
              if request.session.test_cookie_worked():
-@@ -70,17 +63,27 @@ def logout(request, next_page=None, temp
+@@ -70,17 +63,31 @@ def logout(request, next_page=None, temp
      "Logs out the user and displays 'You are logged out' message."
      from django.contrib.auth import logout
      logout(request)
@@ -61,7 +61,11 @@
 -        return HttpResponseRedirect(next_page or request.path)
 +        return HttpResponseRedirect(next_page)
 +
-+    current_site = get_current_site(request)
++    if Site._meta.installed:
++        current_site = Site.objects.get_current()
++    else:
++        current_site = RequestSite(request)
++
 +    context = {
 +        'site': current_site,
 +        'site_name': current_site.name,

Modified: packages/python-django/branches/squeeze/debian/patches/25_limit_number_of_forms_in_formset.diff
===================================================================
--- packages/python-django/branches/squeeze/debian/patches/25_limit_number_of_forms_in_formset.diff	2013-02-24 15:14:40 UTC (rev 23569)
+++ packages/python-django/branches/squeeze/debian/patches/25_limit_number_of_forms_in_formset.diff	2013-02-24 16:06:33 UTC (rev 23570)
@@ -69,3 +69,14 @@
  
  Using a model formset in a view
  -------------------------------
+--- a/tests/regressiontests/forms/formsets.py
++++ b/tests/regressiontests/forms/formsets.py
+@@ -20,7 +20,7 @@ but we'll look at how to do so later.
+ 
+ >>> formset = ChoiceFormSet(auto_id=False, prefix='choices')
+ >>> print formset
+-<input type="hidden" name="choices-TOTAL_FORMS" value="1" /><input type="hidden" name="choices-INITIAL_FORMS" value="0" /><input type="hidden" name="choices-MAX_NUM_FORMS" />
++<input type="hidden" name="choices-TOTAL_FORMS" value="1" /><input type="hidden" name="choices-INITIAL_FORMS" value="0" /><input type="hidden" name="choices-MAX_NUM_FORMS" value="1000" />
+ <tr><th>Choice:</th><td><input type="text" name="choices-0-choice" /></td></tr>
+ <tr><th>Votes:</th><td><input type="text" name="choices-0-votes" /></td></tr>
+ 




More information about the Python-modules-commits mailing list