/*
 * call-seq:
 *    conn.lo_tell( lo_desc ) -> Fixnum
 *
 * Returns the current position of the large object _lo_desc_.
 */
static VALUE
pgconn_lotell(VALUE self, VALUE in_lo_desc)
{
        int position;
        PGconn *conn = get_pgconn(self);
        int lo_desc = NUM2INT(in_lo_desc);

        if((position = lo_tell(conn, lo_desc)) < 0)
                rb_raise(rb_ePGError,"lo_tell failed");

        return INT2FIX(position);
}