Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
aports
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Zach DeCook
aports
Commits
75802cb0
Commit
75802cb0
authored
15 years ago
by
Timo Teräs
Browse files
Options
Downloads
Patches
Plain Diff
db: increase hash sizes a bit
parent
1339b143
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/database.c
+5
-5
5 additions, 5 deletions
src/database.c
with
5 additions
and
5 deletions
src/database.c
+
5
−
5
View file @
75802cb0
...
...
@@ -741,8 +741,8 @@ int apk_db_open(struct apk_database *db, const char *root, unsigned int flags)
memset
(
db
,
0
,
sizeof
(
*
db
));
apk_hash_init
(
&
db
->
available
.
names
,
&
pkg_name_hash_ops
,
1000
);
apk_hash_init
(
&
db
->
available
.
packages
,
&
pkg_info_hash_ops
,
4000
);
apk_hash_init
(
&
db
->
installed
.
dirs
,
&
dir_hash_ops
,
1
000
);
apk_hash_init
(
&
db
->
installed
.
files
,
&
file_hash_ops
,
4
000
);
apk_hash_init
(
&
db
->
installed
.
dirs
,
&
dir_hash_ops
,
2
000
);
apk_hash_init
(
&
db
->
installed
.
files
,
&
file_hash_ops
,
10
000
);
list_init
(
&
db
->
installed
.
packages
);
db
->
cache_dir
=
apk_static_cache_dir
;
...
...
@@ -1298,12 +1298,10 @@ static int apk_db_install_archive_entry(void *_ctx,
ctx
->
script_pending
=
TRUE
;
return
apk_db_run_pending_script
(
ctx
);
}
r
=
apk_db_run_pending_script
(
ctx
);
if
(
r
!=
0
)
return
r
;
/* Show progress */
if
(
ctx
->
cb
)
{
size_t
size
=
ctx
->
installed_size
;
...
...
@@ -1323,7 +1321,9 @@ static int apk_db_install_archive_entry(void *_ctx,
/* Make sure the file is part of the cached directory tree */
if
(
diri
==
NULL
||
apk_blob_compare
(
APK_BLOB_PTR_LEN
(
diri
->
dir
->
name
,
diri
->
dir
->
namelen
),
bdir
)
!=
0
)
{
apk_blob_compare
(
APK_BLOB_PTR_LEN
(
diri
->
dir
->
name
,
diri
->
dir
->
namelen
),
bdir
)
!=
0
)
{
struct
hlist_node
*
n
;
hlist_for_each_entry
(
diri
,
n
,
&
pkg
->
owned_dirs
,
pkg_dirs_list
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment