.\" Man page generated from reStructuredText. . . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .TH "MEMCACHED_LAST_ERROR" "3" "May 01, 2024" "1.1" "libmemcached-awesome" .SH NAME memcached_last_error \- libmemcached Documentation .SH SYNOPSIS .INDENT 0.0 .TP .B #include Compile and link with \-lmemcached .UNINDENT .INDENT 0.0 .TP .B \X'tty: link #_CPPv418memcached_return_t'\fI\%memcached_return_t\fP\X'tty: link' memcached_last_error(const \X'tty: link #_CPPv412memcached_st'\fI\%memcached_st\fP\X'tty: link' *ptr) .INDENT 7.0 .TP .B Parameters \fBptr\fP \-\- pointer to an initialized \X'tty: link #_CPPv412memcached_st'\fI\%memcached_st\fP\X'tty: link' struct .TP .B Returns \X'tty: link #_CPPv418memcached_return_t'\fI\%memcached_return_t\fP\X'tty: link' indicating success of last operation .UNINDENT .UNINDENT .INDENT 0.0 .TP .B const char *memcached_last_error_message(const \X'tty: link #_CPPv412memcached_st'\fI\%memcached_st\fP\X'tty: link' *ptr) .INDENT 7.0 .TP .B Parameters \fBptr\fP \-\- pointer to an initialized \X'tty: link #_CPPv412memcached_st'\fI\%memcached_st\fP\X'tty: link' struct .TP .B Returns message describing the status of last operation .UNINDENT .UNINDENT .INDENT 0.0 .TP .B int memcached_last_error_errno(const \X'tty: link #_CPPv412memcached_st'\fI\%memcached_st\fP\X'tty: link' *ptr) .INDENT 7.0 .TP .B Parameters \fBptr\fP \-\- pointer to an initialized \X'tty: link #_CPPv412memcached_st'\fI\%memcached_st\fP\X'tty: link' struct .TP .B Returns \fB\X'tty: link https://linux.die.net/man/3/errno'\fI\%errno(3)\fP\X'tty: link'\fP (if any) of last operation .UNINDENT .UNINDENT .SH DESCRIPTION .sp Retrieve error codes and messages. .SH RETURN VALUE .sp \fI\%memcached_last_error()\fP returns the last error code. .sp \fI\%memcached_last_error_message()\fP returns the last error message. If this error came from a specific server, its hostname and port will be provided in the error message. Any error message will be returned as \(aqconst char *\(aq which does not need to be de\-allocated. NULL will be returned if no error has occurred. .sp \fI\%memcached_last_error_errno()\fP returns any last local error code obtained from \fB\X'tty: link https://linux.die.net/man/3/errno'\fI\%errno(3)\fP\X'tty: link'\fP\&. .SH SEE ALSO .sp \fB\X'tty: link https://linux.die.net/man/1/memcached'\fI\%memcached(1)\fP\X'tty: link'\fP \fB\X'tty: link https://linux.die.net/man/3/errno'\fI\%errno(3)\fP\X'tty: link'\fP \fB\X'tty: link https://linux.die.net/man/3/libmemcached'\fI\%libmemcached(3)\fP\X'tty: link'\fP \fB\X'tty: link https://linux.die.net/man/3/memcached_strerror'\fI\%memcached_strerror(3)\fP\X'tty: link'\fP .\" Generated by docutils manpage writer. .