Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: ejabberd 2.1.7, ejabberd 3.0.0-alpha-3
    • Fix Version/s: ejabberd 2.1.8
    • Component/s: Publish-Subscribe
    • Labels:
      None

      Description

      I install ejabberd 2.1.7 with empty database, create a user, login, publish my activity using PEP, and ejabberd shows:

      =ERROR REPORT==== 1-Jun-2011::20:03:31 ===
      E(<0.366.0>:mod_pubsub:3802) : transaction return internal error: 
      {'EXIT',
       {{case_clause,false},
        [{mod_pubsub,'-publish_item/6-fun-0-',5},
         {mod_pubsub,'-transaction/4-fun-0-',3},
         {mnesia_tm,non_transaction,5},
         {mod_pubsub,transaction,2},
         {mod_pubsub,publish_item,6},
         {mod_pubsub,iq_sm,3},
         {gen_iq_handler,process_iq,6},
         {gen_iq_handler,handle_info,2}]}}
      

      I think the bug was introduced here:
      https://git.process-one.net/ejabberd/mainline/commit/adcf2d5c4e45a4c5b9e1e7756c858e286f5d59bb

      This change apparently solves the problem:

      --- a/src/mod_pubsub/mod_pubsub.erl
      +++ b/src/mod_pubsub/mod_pubsub.erl
      @@ -2024,8 +2024,8 @@ publish_item(Host, ServerHost, Node, Publisher, ItemId, Payload) ->
                          DeliverPayloads = get_option(Options, deliver_payloads),
                          PersistItems = get_option(Options, persist_items),
                          MaxItems = case PersistItems of
      -                       0 -> 0;
      -                       1 -> max_items(Host, Options)
      +                       false -> 0;
      +                       true -> max_items(Host, Options)
                          end,
                          PayloadCount = payload_xmlelements(Payload),
                          PayloadSize = size(term_to_binary(Payload))-2, % size(term_to_binary([])) == 2
      

        Issue Links

          Activity

          No work has yet been logged on this issue.

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                2 years, 45 weeks, 2 days ago

                Issue deployment