rugged 1.7.1 → 1.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 612678eb067cc67b95f2bab39559c502a323746387cb79d1f333148e84bf5746
4
- data.tar.gz: 15a17bdb4bc6c5e60d0ee1605447962d1cd524f0e0330253dec3273774464d6b
3
+ metadata.gz: e52f4ad4181dc205f02222873f94b720bf504850d199a0266b5e2309c2fcc02e
4
+ data.tar.gz: bc6cd28bf7dccb27fbad7131c18db7b0bd6dc79086142b8e6a7f57e531b6f95b
5
5
  SHA512:
6
- metadata.gz: f20f497297ac36e2a63acdba4b15962c360f527ac107fd7f87200ee513d73fcf7e85bfe6da1427b10a7e8ae497edcbe14dcce3492ecace08b557fb87a72abf29
7
- data.tar.gz: 4694b1dbce110bcfaac801bff104b5829d529eeba55d01e9bf939f74841dc11e357a9749e0a72ae02338f36ce2bdd7c1ad2da100ff46bc4b535361e41f67ade6
6
+ metadata.gz: 32f007d7b11acca4cd14b91006bbdb1370dc9731721652187177cb88076dcc9aed1bcde971bbea194a5d11e5ecb3443571441a7ed6fea9b23e36dde285da2143
7
+ data.tar.gz: 5801750e777d898f87299aef557c92710b73cd929aca77aec5fcacb822147f8faa59a223f65cf8f7e71adc17a328b513d83294980f83c77b80fa34e30499e9e5
@@ -4,5 +4,5 @@
4
4
  # For full terms see the included LICENSE file.
5
5
 
6
6
  module Rugged
7
- Version = VERSION = '1.7.1'
7
+ Version = VERSION = '1.7.2'
8
8
  end
@@ -6,7 +6,7 @@
6
6
 
7
7
  cmake_minimum_required(VERSION 3.5.1)
8
8
 
9
- project(libgit2 VERSION "1.7.1" LANGUAGES C)
9
+ project(libgit2 VERSION "1.7.2" LANGUAGES C)
10
10
 
11
11
  # Add find modules to the path
12
12
  set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${PROJECT_SOURCE_DIR}/cmake")
@@ -11,7 +11,7 @@
11
11
  * The version string for libgit2. This string follows semantic
12
12
  * versioning (v2) guidelines.
13
13
  */
14
- #define LIBGIT2_VERSION "1.7.1"
14
+ #define LIBGIT2_VERSION "1.7.2"
15
15
 
16
16
  /** The major version number for this version of libgit2. */
17
17
  #define LIBGIT2_VER_MAJOR 1
@@ -20,7 +20,7 @@
20
20
  #define LIBGIT2_VER_MINOR 7
21
21
 
22
22
  /** The revision ("teeny") version number for this version of libgit2. */
23
- #define LIBGIT2_VER_REVISION 1
23
+ #define LIBGIT2_VER_REVISION 2
24
24
 
25
25
  /** The Windows DLL patch number for this version of libgit2. */
26
26
  #define LIBGIT2_VER_PATCH 0
@@ -1185,10 +1185,13 @@ static int has_dir_name(git_index *index,
1185
1185
  size_t len, pos;
1186
1186
 
1187
1187
  for (;;) {
1188
- if (*--slash == '/')
1189
- break;
1188
+ slash--;
1189
+
1190
1190
  if (slash <= entry->path)
1191
1191
  return 0;
1192
+
1193
+ if (*slash == '/')
1194
+ break;
1192
1195
  }
1193
1196
  len = slash - name;
1194
1197
 
@@ -701,6 +701,7 @@ static int revparse(
701
701
  git_object *base_rev = NULL;
702
702
 
703
703
  bool should_return_reference = true;
704
+ bool parsed = false;
704
705
 
705
706
  GIT_ASSERT_ARG(object_out);
706
707
  GIT_ASSERT_ARG(reference_out);
@@ -710,7 +711,7 @@ static int revparse(
710
711
  *object_out = NULL;
711
712
  *reference_out = NULL;
712
713
 
713
- while (spec[pos]) {
714
+ while (!parsed && spec[pos]) {
714
715
  switch (spec[pos]) {
715
716
  case '^':
716
717
  should_return_reference = false;
@@ -817,6 +818,8 @@ static int revparse(
817
818
  break;
818
819
  } else if (spec[pos+1] == '\0') {
819
820
  spec = "HEAD";
821
+ identifier_len = 4;
822
+ parsed = true;
820
823
  break;
821
824
  }
822
825
  /* fall through */
@@ -232,7 +232,8 @@ static int set_data(
232
232
 
233
233
  GIT_ASSERT_ARG(data);
234
234
 
235
- if ((caps = memchr(line, '\0', len)) != NULL) {
235
+ if ((caps = memchr(line, '\0', len)) != NULL &&
236
+ len > (size_t)((caps - line) + 1)) {
236
237
  caps++;
237
238
 
238
239
  if (strncmp(caps, "object-format=", CONST_STRLEN("object-format=")) == 0)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rugged
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.1
4
+ version: 1.7.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Chacon
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2023-09-04 00:00:00.000000000 Z
12
+ date: 2024-02-07 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake-compiler