Skip to content

Commit

Permalink
increase some limits
Browse files Browse the repository at this point in the history
  • Loading branch information
Ondrej Jirman committed Apr 12, 2010
1 parent 513c442 commit ef58aec
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/cmd-install.c
Expand Up @@ -646,7 +646,7 @@ gint cmd_install(const gchar* pkgfile, const struct cmd_options* opts, struct er
}
else if (!strcmp(sane_path, "install/doinst.sh"))
{
if (tgz->f_size > 1024*512) /* 512K is enough for all. :) */
if (tgz->f_size > 1024*1024*4) /* 4M is enough for all. :) now, really! */
{
e_set(E_ERROR, "Installation script is too big. (%ld kB)", tgz->f_size / 1024);
goto err3;
Expand Down
2 changes: 1 addition & 1 deletion src/cmd-upgrade.c
Expand Up @@ -787,7 +787,7 @@ gint cmd_upgrade(const gchar* pkgfile, const struct cmd_options* opts, struct er
}
else if (!strcmp(sane_path, "install/doinst.sh"))
{
if (tgz->f_size > 1024*512) /* 512K is enough for all. :) */
if (tgz->f_size > 1024*1024*4) /* 4M is enough for all. :) now, really! */
{
e_set(E_ERROR, "Installation script is too big. (%ld kB)", tgz->f_size / 1024);
goto err3;
Expand Down
2 changes: 1 addition & 1 deletion src/pkgdb.c
Expand Up @@ -816,7 +816,7 @@ struct db_pkg* db_get_pkg(gchar* name, db_get_type type)

fseek(fs, 0, SEEK_END);
guint script_size = ftell(fs);
if (script_size > 512*1024)
if (script_size > 4*1024*1024)
{
e_set(E_ERROR, "Script file is too big %s. (%u kB)", p->name, script_size / 1024);
goto err_1;
Expand Down

0 comments on commit ef58aec

Please sign in to comment.