Skip to content

Commit

Permalink
Develop (#282)
Browse files Browse the repository at this point in the history
* 217: fix unused code.

* 217: unused code and warning

* disabled man pages for rmb
  • Loading branch information
jrse authored Feb 11, 2022
1 parent 0eabac2 commit a0d29ec
Show file tree
Hide file tree
Showing 9 changed files with 13 additions and 28 deletions.
2 changes: 0 additions & 2 deletions rpm/dovecot-ceph-plugin.spec
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,5 @@ find %{buildroot}%{_libdir}/dovecot/ -type f -name \*.a -delete
%files -n rmb-tools
%defattr(-,root,root)
%attr(0755, root, root) %{_bindir}/rmb
%doc %{_mandir}/man1/rmb.1*

%changelog

Empty file modified src/Makefile.am
100644 → 100755
Empty file.
6 changes: 0 additions & 6 deletions src/librmb/rados-storage-impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,12 +138,6 @@ int RadosStorageImpl::stat_mail(const std::string &oid, uint64_t *psize, time_t
return get_io_ctx().stat(oid, psize, pmtime);
}

int RadosStorageImpl::create_anker() {
if (!cluster->is_connected() || !io_ctx_created) {
return -1;
}
return get_io_ctx().write_full("anker","anker");
}
void RadosStorageImpl::set_namespace(const std::string &_nspace) {
get_io_ctx().set_namespace(_nspace);
this->nspace = _nspace;
Expand Down
2 changes: 0 additions & 2 deletions src/librmb/rados-storage-impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,6 @@ class RadosStorageImpl : public RadosStorage {
librmb::RadosMail *alloc_rados_mail() override;

void free_rados_mail(librmb::RadosMail *mail) override;
int create_anker();


private:
int create_connection(const std::string &poolname);
Expand Down
1 change: 0 additions & 1 deletion src/librmb/rados-storage.h
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,6 @@ class RadosStorage {
* */
virtual void free_rados_mail(librmb::RadosMail *mail) = 0;

virtual int create_anker() = 0;
};

} // namespace librmb
Expand Down
6 changes: 3 additions & 3 deletions src/librmb/tools/rmb/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ rmb_SOURCES = \

rmb_LDADD = $(shlibs)

man1_MANS = rmb.man
#man1_MANS = rmb.man

EXTRA_DIST = \
$(man1_MANS)
#EXTRA_DIST = \
# $(man1_MANS)

4 changes: 0 additions & 4 deletions src/storage-rbox/rbox-storage.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -654,10 +654,6 @@ int rbox_mailbox_open(struct mailbox *box) {
}

if (box->creating) {

/* wait for mailbox creation to initialize the index */
int anker_create = rbox->storage->s->create_anker();
i_info("create anker %d", anker_create);
FUNC_END();
return 0;
}
Expand Down
2 changes: 1 addition & 1 deletion src/storage-rbox/rbox-sync-rebuild.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ int rbox_sync_rebuild_entry(struct index_rebuild_context *ctx, librados::NObject
if(guid != mailbox_guid) {
// mail object does not belong to this mailbox,
// skip it and hope that other mailboxes exist and we can assign it.
i_warning("mail_guid : %s is not part of mailbox_guid %s mails mailbox_guid is: %s ",
i_debug("mail_guid : %s is not part of mailbox_guid %s mails mailbox_guid is: %s ",
mail_object.get_oid()->c_str(),
guid.c_str(),
mails_guid.c_str()
Expand Down
18 changes: 9 additions & 9 deletions src/tests/it_test_storage_rbox_2
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ func_parse_lt_options ()
case "$lt_opt" in
--lt-debug) lt_option_debug=1 ;;
--lt-dump-script)
lt_dump_D=`$ECHO "X$lt_script_arg0" | /bin/sed -e 's/^X//' -e 's%/[^/]*$%%'`
lt_dump_D=`$ECHO "X$lt_script_arg0" | /usr/bin/sed -e 's/^X//' -e 's%/[^/]*$%%'`
test "X$lt_dump_D" = "X$lt_script_arg0" && lt_dump_D=.
lt_dump_F=`$ECHO "X$lt_script_arg0" | /bin/sed -e 's/^X//' -e 's%^.*/%%'`
lt_dump_F=`$ECHO "X$lt_script_arg0" | /usr/bin/sed -e 's/^X//' -e 's%^.*/%%'`
cat "$lt_dump_D/$lt_dump_F"
exit 0
;;
Expand Down Expand Up @@ -143,13 +143,13 @@ func_exec_program ()
func_parse_lt_options "$0" ${1+"$@"}

# Find the directory that this script lives in.
thisdir=`$ECHO "$file" | /bin/sed 's%/[^/]*$%%'`
thisdir=`$ECHO "$file" | /usr/bin/sed 's%/[^/]*$%%'`
test "x$thisdir" = "x$file" && thisdir=.

# Follow symbolic links until we get to the real thisdir.
file=`ls -ld "$file" | /bin/sed -n 's/.*-> //p'`
file=`ls -ld "$file" | /usr/bin/sed -n 's/.*-> //p'`
while test -n "$file"; do
destdir=`$ECHO "$file" | /bin/sed 's%/[^/]*$%%'`
destdir=`$ECHO "$file" | /usr/bin/sed 's%/[^/]*$%%'`

# If there was a directory component, then change thisdir.
if test "x$destdir" != "x$file"; then
Expand All @@ -159,8 +159,8 @@ func_exec_program ()
esac
fi

file=`$ECHO "$file" | /bin/sed 's%^.*/%%'`
file=`ls -ld "$thisdir/$file" | /bin/sed -n 's/.*-> //p'`
file=`$ECHO "$file" | /usr/bin/sed 's%^.*/%%'`
file=`ls -ld "$thisdir/$file" | /usr/bin/sed -n 's/.*-> //p'`
done

# Usually 'no', except on cygwin/mingw when embedded into
Expand All @@ -173,7 +173,7 @@ func_exec_program ()
fi
# remove .libs from thisdir
case "$thisdir" in
*[\\/].libs ) thisdir=`$ECHO "$thisdir" | /bin/sed 's%[\\/][^\\/]*$%%'` ;;
*[\\/].libs ) thisdir=`$ECHO "$thisdir" | /usr/bin/sed 's%[\\/][^\\/]*$%%'` ;;
.libs ) thisdir=. ;;
esac
fi
Expand All @@ -192,7 +192,7 @@ func_exec_program ()

# Some systems cannot cope with colon-terminated LD_LIBRARY_PATH
# The second colon is a workaround for a bug in BeOS R4 sed
LD_LIBRARY_PATH=`$ECHO "$LD_LIBRARY_PATH" | /bin/sed 's/::*$//'`
LD_LIBRARY_PATH=`$ECHO "$LD_LIBRARY_PATH" | /usr/bin/sed 's/::*$//'`

export LD_LIBRARY_PATH

Expand Down

0 comments on commit a0d29ec

Please sign in to comment.