Commit c6bd2a1
http-push: stop using name_path
The graph traversal code here passes along a name_path to
build up the pathname at which we find each blob. But we
never actually do anything with the resulting names, making
it a waste of code and memory.
This usage came in aa1dbc9 (Update http-push functionality,
2006-03-07), and originally the result was passed to
"add_object" (which stored it, but didn't really use it,
either). But we stopped using that function in 1f1e895 (Add
"named object array" concept, 2006-06-19) in favor of
storing just the objects themselves.
Moreover, the generation of the name in process_tree() is
buggy. It sticks "name" onto the end of the name_path linked
list, and then passes it down again as it recurses (instead
of "entry.path"). So it's a good thing this was unused, as
the resulting path for "a/b/c/d" would end up as "a/a/a/a".
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>1 parent d770187 commit c6bd2a1
1 file changed
+7
-16
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1276 | 1276 | | |
1277 | 1277 | | |
1278 | 1278 | | |
1279 | | - | |
1280 | | - | |
1281 | | - | |
| 1279 | + | |
1282 | 1280 | | |
1283 | 1281 | | |
1284 | 1282 | | |
| |||
1292 | 1290 | | |
1293 | 1291 | | |
1294 | 1292 | | |
1295 | | - | |
1296 | | - | |
1297 | | - | |
| 1293 | + | |
1298 | 1294 | | |
1299 | 1295 | | |
1300 | 1296 | | |
1301 | 1297 | | |
1302 | | - | |
1303 | 1298 | | |
1304 | 1299 | | |
1305 | 1300 | | |
| |||
1309 | 1304 | | |
1310 | 1305 | | |
1311 | 1306 | | |
1312 | | - | |
1313 | 1307 | | |
1314 | | - | |
1315 | | - | |
1316 | | - | |
1317 | 1308 | | |
1318 | 1309 | | |
1319 | 1310 | | |
1320 | 1311 | | |
1321 | 1312 | | |
1322 | 1313 | | |
1323 | | - | |
| 1314 | + | |
1324 | 1315 | | |
1325 | 1316 | | |
1326 | | - | |
| 1317 | + | |
1327 | 1318 | | |
1328 | 1319 | | |
1329 | 1320 | | |
| |||
1342 | 1333 | | |
1343 | 1334 | | |
1344 | 1335 | | |
1345 | | - | |
| 1336 | + | |
1346 | 1337 | | |
1347 | 1338 | | |
1348 | 1339 | | |
| |||
1361 | 1352 | | |
1362 | 1353 | | |
1363 | 1354 | | |
1364 | | - | |
| 1355 | + | |
1365 | 1356 | | |
1366 | 1357 | | |
1367 | 1358 | | |
1368 | | - | |
| 1359 | + | |
1369 | 1360 | | |
1370 | 1361 | | |
1371 | 1362 | | |
| |||
0 commit comments