Skip to content
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions lib/net/ldap/pdu.rb
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,8 @@ class Error < RuntimeError; end

def initialize(ber_object)
begin
@message_id = ber_object[0].to_i
id = ber_object[0]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's the point of this 2 line change?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No one, sorry, I try to understand the ber object and I forgot that lines

@message_id = id.to_i
# Grab the bottom five bits of the identifier so we know which type of
# PDU this is.
#
Expand All @@ -94,7 +95,7 @@ def initialize(ber_object)
@app_tag = ber_object[1].ber_identifier & 0x1f
@ldap_controls = []
rescue Exception => ex
raise Net::LDAP::PDU::Error, "LDAP PDU Format Error: #{ex.message}"
raise Net::LDAP::PDU::Error, "LDAP PDU Format Error: #{ex.message} Ber Object is #{ber_object}"
end

case @app_tag
Expand Down Expand Up @@ -123,7 +124,7 @@ def initialize(ber_object)
when ExtendedResponse
parse_extended_response(ber_object[1])
else
raise LdapPduError.new("unknown pdu-type: #{@app_tag}")
raise Net::LDAP::PDU::Error, "unknown pdu-type: #{@app_tag}"
end

parse_controls(ber_object[2]) if ber_object[2]
Expand Down
2 changes: 1 addition & 1 deletion lib/net/ldap/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module Net
class LDAP
VERSION = "0.16.2"
VERSION = "0.16.2.3"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why change the version here?

end
end