From 11e3521013a732b3891b7916636ff87cdf233e57 Mon Sep 17 00:00:00 2001 From: Jeremy Paige Date: Mon, 20 May 2024 20:41:10 -0700 Subject: [PATCH] fix indirection bug Co-authored-by: Ken Seehart --- examples/extension-hatch/examplePy/temperature.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/extension-hatch/examplePy/temperature.c b/examples/extension-hatch/examplePy/temperature.c index f1de1ebb..86bb0bce 100644 --- a/examples/extension-hatch/examplePy/temperature.c +++ b/examples/extension-hatch/examplePy/temperature.c @@ -7,7 +7,7 @@ temperature_celsius_to_fahrenheit(PyObject *self, PyObject *args) long celsius; PyObject *ret; - if (!PyArg_ParseTuple(args, "l", celsius)) + if (!PyArg_ParseTuple(args, "l", &celsius)) return NULL; celsius = (celsius * 9/5) + 32; @@ -23,7 +23,7 @@ temperature_fahrenheit_to_celsius(PyObject *self, PyObject *args) long fahrenheit; PyObject *ret; - if (!PyArg_ParseTuple(args, "l", fahrenheit)) + if (!PyArg_ParseTuple(args, "l", &fahrenheit)) return NULL; fahrenheit = (fahrenheit - 32) * 9/5;