Skip to content

Commit

Permalink
return NULL if no changes
Browse files Browse the repository at this point in the history
  • Loading branch information
shikokuchuo committed Nov 29, 2024
1 parent f639cfa commit 671389d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions R/socket.R
Original file line number Diff line number Diff line change
Expand Up @@ -197,10 +197,10 @@ reap <- function(con) .Call(rnng_reap, con)
#' @param sock a Socket.
#' @param cv a conditionVariable.
#'
#' @return For monitor: an external pointer. \cr
#' For read_monitor: an integer vector of pipe IDs (positive if added,
#' negative if removed), or else integer zero if there were no changes since
#' the previous read.
#' @return For \code{monitor}: an external pointer. \cr
#' For \code{read_monitor}: an integer vector of pipe IDs (positive if added,
#' negative if removed), or else NULL if there were no changes since the
#' previous read.
#'
#' @examples
#' cv <- cv()
Expand Down
8 changes: 4 additions & 4 deletions man/monitor.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/sync.c
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ SEXP rnng_monitor_read(SEXP x) {
nng_mtx_unlock(mtx);

if (!updates)
out = nano_success;
out = R_NilValue;

return out;

Expand Down

0 comments on commit 671389d

Please sign in to comment.