summaryrefslogtreecommitdiff
path: root/pymssql/0001-Drop-usage-of-DBVERSION_80-symbol-d90c9b.patch
blob: 241970fe7202b4e13e20b9ae263848a6b339862f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
From d90c9b85eea83bdebee0300c2ff6fa3c9d0b1508 Mon Sep 17 00:00:00 2001
From: Ramiro Morales <cramm0@gmail.com>
Date: Wed, 22 Jun 2016 19:58:03 -0300
Subject: [PATCH] Drop usage of `DBVERSION_80` symbol.

It was deprecated and was finally removed in FreeTDS 1.0.

Fixes #432.
---
 src/_mssql.pyx   | 4 +---
 src/sqlfront.pxd | 1 -
 2 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/src/_mssql.pyx b/src/_mssql.pyx
index 463a6e0..6f95032 100644
--- a/_mssql.pyx
+++ b/_mssql.pyx
@@ -1708,12 +1708,10 @@ cdef int _tds_ver_str_to_constant(verstr) except -1:
         return DBVERSION_42
     if verstr == u'7.0':
         return DBVERSION_70
-    if verstr == u'7.1':
+    if verstr in (u'7.1', u'8.0'):
         return DBVERSION_71
     if verstr == u'7.2':
         return DBVERSION_72
-    if verstr == u'8.0':
-        return DBVERSION_80
     raise MSSQLException('unrecognized tds version: %s' % verstr)
 
 #######################
diff --git a/src/sqlfront.pxd b/src/sqlfront.pxd
index d0ef691..91ab005 100644
--- a/sqlfront.pxd
+++ b/sqlfront.pxd
@@ -106,7 +106,6 @@ cdef extern from "sqlfront.h":
     int DBVERSION_70
     int DBVERSION_71
     int DBVERSION_72
-    int DBVERSION_80
 
     ## Type Constants ##
     cdef enum: