Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
82fbb89c
Commit
82fbb89c
authored
Sep 05, 2001
by
Jack Jansen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
A few more gcc warnings bite the dust.
parent
2d78332d
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
28 additions
and
11 deletions
+28
-11
Mac/Modules/qd/_Qdmodule.c
Mac/Modules/qd/_Qdmodule.c
+1
-1
Mac/Modules/qd/qdsupport.py
Mac/Modules/qd/qdsupport.py
+1
-1
Mac/Modules/res/_Resmodule.c
Mac/Modules/res/_Resmodule.c
+6
-3
Mac/Modules/res/resedit.py
Mac/Modules/res/resedit.py
+6
-3
Mac/Modules/waste/wastemodule.c
Mac/Modules/waste/wastemodule.c
+14
-3
No files found.
Mac/Modules/qd/_Qdmodule.c
View file @
82fbb89c
...
...
@@ -122,7 +122,7 @@ PyObject *QdRGB_New(RGBColorPtr itself)
return
Py_BuildValue
(
"lll"
,
(
long
)
itself
->
red
,
(
long
)
itself
->
green
,
(
long
)
itself
->
blue
);
}
QdRGB_Convert
(
PyObject
*
v
,
RGBColorPtr
p_itself
)
int
QdRGB_Convert
(
PyObject
*
v
,
RGBColorPtr
p_itself
)
{
long
red
,
green
,
blue
;
...
...
Mac/Modules/qd/qdsupport.py
View file @
82fbb89c
...
...
@@ -167,7 +167,7 @@ PyObject *QdRGB_New(RGBColorPtr itself)
return Py_BuildValue("lll", (long)itself->red, (long)itself->green, (long)itself->blue);
}
QdRGB_Convert(PyObject *v, RGBColorPtr p_itself)
int
QdRGB_Convert(PyObject *v, RGBColorPtr p_itself)
{
long red, green, blue;
...
...
Mac/Modules/res/_Resmodule.c
View file @
82fbb89c
...
...
@@ -440,7 +440,8 @@ static PyObject *ResObj_AutoDispose(ResourceObject *_self, PyObject *_args)
_self
->
ob_freeit
=
PyMac_AutoDisposeHandle
;
else
_self
->
ob_freeit
=
NULL
;
return
Py_BuildValue
(
"i"
,
old
);
_res
=
Py_BuildValue
(
"i"
,
old
);
return
_res
;
}
...
...
@@ -1378,7 +1379,8 @@ static PyObject *Res_Resource(PyObject *_self, PyObject *_args)
HLock
(
h
);
memcpy
(
*
h
,
buf
,
len
);
HUnlock
(
h
);
return
ResObj_New
(
h
);
_res
=
ResObj_New
(
h
);
return
_res
;
}
...
...
@@ -1403,7 +1405,8 @@ static PyObject *Res_Handle(PyObject *_self, PyObject *_args)
HUnlock
(
h
);
rv
=
(
ResourceObject
*
)
ResObj_New
(
h
);
rv
->
ob_freeit
=
PyMac_AutoDisposeHandle
;
return
(
PyObject
*
)
rv
;
_res
=
(
PyObject
*
)
rv
;
return
_res
;
}
...
...
Mac/Modules/res/resedit.py
View file @
82fbb89c
...
...
@@ -13,7 +13,8 @@ if ( h == NULL ) {
HLock(h);
memcpy(*h, buf, len);
HUnlock(h);
return ResObj_New(h);
_res = ResObj_New(h);
return _res;
"""
f
=
ManualGenerator
(
"Resource"
,
resource_body
)
...
...
@@ -43,7 +44,8 @@ memcpy(*h, buf, len);
HUnlock(h);
rv = (ResourceObject *)ResObj_New(h);
rv->ob_freeit = PyMac_AutoDisposeHandle;
return (PyObject *)rv;
_res = (PyObject *)rv;
return _res;
"""
f
=
ManualGenerator
(
"Handle"
,
handle_body
)
...
...
@@ -92,7 +94,8 @@ if ( onoff )
_self->ob_freeit = PyMac_AutoDisposeHandle;
else
_self->ob_freeit = NULL;
return Py_BuildValue("i", old);
_res = Py_BuildValue("i", old);
return _res;
"""
f
=
ManualGenerator
(
"AutoDispose"
,
AutoDispose_body
)
f
.
docstring
=
lambda
:
"(int)->int. Automatically DisposeHandle the object on Python object cleanup"
...
...
Mac/Modules/waste/wastemodule.c
View file @
82fbb89c
...
...
@@ -5,8 +5,20 @@
#ifdef _WIN32
#include "pywintoolbox.h"
#else
#include "macglue.h"
#include "pymactoolbox.h"
#endif
/* Macro to test whether a weak-loaded CFM function exists */
#define PyMac_PRECHECK(rtn) do { if ( &rtn == NULL ) {\
PyErr_SetString(PyExc_NotImplementedError, \
"Not available in this shared library/OS version"); \
return NULL; \
}} while(0)
#include <WASTE.h>
#include <WEObjectHandlers.h>
...
...
@@ -213,7 +225,7 @@ PyObject *WEOObj_New(WEObjectReference itself)
it
->
ob_itself
=
itself
;
return
(
PyObject
*
)
it
;
}
WEOObj_Convert
(
PyObject
*
v
,
WEObjectReference
*
p_itself
)
int
WEOObj_Convert
(
PyObject
*
v
,
WEObjectReference
*
p_itself
)
{
if
(
!
WEOObj_Check
(
v
))
{
...
...
@@ -381,7 +393,7 @@ PyObject *wasteObj_New(WEReference itself)
WESetInfo
(
weRefCon
,
(
void
*
)
&
it
,
itself
);
return
(
PyObject
*
)
it
;
}
wasteObj_Convert
(
PyObject
*
v
,
WEReference
*
p_itself
)
int
wasteObj_Convert
(
PyObject
*
v
,
WEReference
*
p_itself
)
{
if
(
!
wasteObj_Check
(
v
))
{
...
...
@@ -1061,7 +1073,6 @@ static PyObject *wasteObj_WEInsert(wasteObject *_self, PyObject *_args)
if
(
_err
!=
noErr
)
return
PyMac_Error
(
_err
);
Py_INCREF
(
Py_None
);
_res
=
Py_None
;
pText__error__:
;
return
_res
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment