File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -109,8 +109,6 @@ static struct config_reader the_reader;
109
109
static inline void config_reader_push_source (struct config_reader * reader ,
110
110
struct config_source * top )
111
111
{
112
- if (reader -> config_kvi )
113
- BUG ("source should not be set while iterating a config set" );
114
112
top -> prev = reader -> source ;
115
113
reader -> source = top ;
116
114
}
@@ -128,16 +126,12 @@ static inline struct config_source *config_reader_pop_source(struct config_reade
128
126
static inline void config_reader_set_kvi (struct config_reader * reader ,
129
127
struct key_value_info * kvi )
130
128
{
131
- if (kvi && (reader -> source || reader -> parsing_scope ))
132
- BUG ("kvi should not be set while parsing a config source" );
133
129
reader -> config_kvi = kvi ;
134
130
}
135
131
136
132
static inline void config_reader_set_scope (struct config_reader * reader ,
137
133
enum config_scope scope )
138
134
{
139
- if (scope && reader -> config_kvi )
140
- BUG ("scope should only be set when iterating through a config source" );
141
135
reader -> parsing_scope = scope ;
142
136
}
143
137
Original file line number Diff line number Diff line change @@ -257,8 +257,8 @@ test_expect_success 'partial clone with transfer.fsckobjects=1 works with submod
257
257
test_commit -C submodule mycommit &&
258
258
259
259
test_create_repo src_with_sub &&
260
- test_config -C src_with_sub uploadpack.allowfilter 1 &&
261
- test_config -C src_with_sub uploadpack.allowanysha1inwant 1 &&
260
+ git -C src_with_sub config uploadpack.allowfilter 1 &&
261
+ git -C src_with_sub config uploadpack.allowanysha1inwant 1 &&
262
262
263
263
test_config_global protocol.file.allow always &&
264
264
@@ -270,6 +270,12 @@ test_expect_success 'partial clone with transfer.fsckobjects=1 works with submod
270
270
test_when_finished rm -rf dst
271
271
'
272
272
273
+ test_expect_success ' lazily fetched .gitmodules works' '
274
+ git clone --filter="blob:none" --no-checkout "file://$(pwd)/src_with_sub" dst &&
275
+ git -C dst fetch &&
276
+ test_when_finished rm -rf dst
277
+ '
278
+
273
279
test_expect_success ' partial clone with transfer.fsckobjects=1 uses index-pack --fsck-objects' '
274
280
git init src &&
275
281
test_commit -C src x &&
You can’t perform that action at this time.
0 commit comments