Skip to content

Commit

Permalink
Apply bug fix from master
Browse files Browse the repository at this point in the history
  • Loading branch information
wwmayer committed Dec 31, 2012
1 parent 15274f1 commit b77b59f
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/App/DocumentPyImp.cpp
Expand Up @@ -182,7 +182,7 @@ PyObject* DocumentPy::removeObject(PyObject *args)

PyObject* DocumentPy::copyObject(PyObject *args)
{
PyObject *obj, *rec=0, *keep=0;
PyObject *obj, *rec=Py_False, *keep=Py_False;
if (!PyArg_ParseTuple(args, "O!|O!O!",&(DocumentObjectPy::Type),&obj,&PyBool_Type,&rec,&PyBool_Type,&keep))
return NULL; // NULL triggers exception

Expand All @@ -201,7 +201,7 @@ PyObject* DocumentPy::copyObject(PyObject *args)

PyObject* DocumentPy::moveObject(PyObject *args)
{
PyObject *obj, *rec=0;
PyObject *obj, *rec=Py_False;
if (!PyArg_ParseTuple(args, "O!|O!",&(DocumentObjectPy::Type),&obj,&PyBool_Type,&rec))
return NULL; // NULL triggers exception

Expand Down
2 changes: 1 addition & 1 deletion src/Gui/View3DPy.cpp
Expand Up @@ -464,7 +464,7 @@ Py::Object View3DInventorPy::viewRotateRight(const Py::Tuple& args)
Py::Object View3DInventorPy::setCameraOrientation(const Py::Tuple& args)
{
PyObject* o;
PyObject* m=0;
PyObject* m=Py_False;
if (!PyArg_ParseTuple(args.ptr(), "O!|O!", &PyTuple_Type, &o, &PyBool_Type, &m))
throw Py::Exception();

Expand Down
2 changes: 1 addition & 1 deletion src/Main/FreeCADGuiPy.cpp
Expand Up @@ -82,7 +82,7 @@ FilterProc(int nCode, WPARAM wParam, LPARAM lParam) {
static PyObject *
FreeCADGui_showMainWindow(PyObject * /*self*/, PyObject *args)
{
PyObject* inThread = 0;
PyObject* inThread = Py_False;
if (!PyArg_ParseTuple(args, "|O!", &PyBool_Type, &inThread))
return NULL;

Expand Down
2 changes: 1 addition & 1 deletion src/Mod/Mesh/App/MeshPyImp.cpp
Expand Up @@ -238,7 +238,7 @@ PyObject* MeshPy::offsetSpecial(PyObject *args)
PyObject* MeshPy::crossSections(PyObject *args)
{
PyObject *obj;
PyObject *poly=0;
PyObject *poly=Py_False;
float min_eps = 1.0e-2f;
if (!PyArg_ParseTuple(args, "O!|fO!", &PyList_Type, &obj, &min_eps, &PyBool_Type, &poly))
return 0;
Expand Down
4 changes: 2 additions & 2 deletions src/Mod/Part/App/AppPartPy.cpp
Expand Up @@ -1147,8 +1147,8 @@ static PyObject * makeLoft(PyObject *self, PyObject *args)
return new BSplineSurfacePy(new GeomBSplineSurface(aRes));
#else
PyObject *pcObj;
PyObject *psolid=0;
PyObject *pruled=0;
PyObject *psolid=Py_False;
PyObject *pruled=Py_False;
if (!PyArg_ParseTuple(args, "O!|O!O!", &(PyList_Type), &pcObj,
&(PyBool_Type), &psolid,
&(PyBool_Type), &pruled))
Expand Down
2 changes: 1 addition & 1 deletion src/Mod/Part/App/BRepOffsetAPI_MakePipeShellPyImp.cpp
Expand Up @@ -127,7 +127,7 @@ PyObject* BRepOffsetAPI_MakePipeShellPy::setAuxiliarySpine(PyObject *args)

PyObject* BRepOffsetAPI_MakePipeShellPy::add(PyObject *args)
{
PyObject *prof, *curv=0, *keep=0;
PyObject *prof, *curv=Py_False, *keep=Py_False;
if (!PyArg_ParseTuple(args, "O!|O!O!",&Part::TopoShapePy::Type,&prof
,&PyBool_Type,&curv
,&PyBool_Type,&keep))
Expand Down
2 changes: 1 addition & 1 deletion src/Mod/Part/App/RectangularTrimmedSurfacePyImp.cpp
Expand Up @@ -66,7 +66,7 @@ int RectangularTrimmedSurfacePy::PyInit(PyObject* args, PyObject* /*kwd*/)

PyErr_Clear();
double param1,param2;
PyObject *utrim=0, *sense=Py_True;
PyObject *utrim=Py_False, *sense=Py_True;
if (PyArg_ParseTuple(args, "O!ddO!|O!",&(Part::GeometrySurfacePy::Type),&surf,
&param1,&param2,&PyBool_Type,&utrim,&PyBool_Type,&sense)) {
Standard_Boolean UTrim = PyObject_IsTrue(utrim);
Expand Down

0 comments on commit b77b59f

Please sign in to comment.