summaryrefslogtreecommitdiff
path: root/print/hplip/files/patch-pcard_pcardext_pcardext.c
blob: 4c531f92d1f2e4147944940cecbad0fd28fb300f (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
--- pcard/pcardext/pcardext.c.orig	Tue May 23 15:43:36 2006
+++ pcard/pcardext/pcardext.c	Tue May 23 15:44:43 2006
@@ -80,6 +80,7 @@
 
 PyObject * pcardext_mount( PyObject * self, PyObject * args ) 
 {
+    int i;
     if( !PyArg_ParseTuple( args, "OO", &readsectorFunc, &writesectorFunc ) )
     {
         return Py_BuildValue( "i", 1 );
@@ -93,7 +94,7 @@
     Py_INCREF( readsectorFunc );
     Py_INCREF( writesectorFunc );
 
-    int i = FatInit();
+    i = FatInit();
     /*char buf[1024];
     sprintf( buf, "print 'FatInit()=%d\n'", i );
     PyRun_SimpleString( buf );*/
@@ -111,8 +112,8 @@
 PyObject * pcardext_ls( PyObject * self, PyObject * args ) 
 {
     PyObject * file_list;
-    file_list = PyList_New(0);
     FILE_ATTRIBUTES fa;
+    file_list = PyList_New(0);
 
     FatDirBegin( &fa );