fread_with_reporting: make progress indicator less noisy

Instead of a message every ~16 seconds, back off exponentially.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
RHTS support: regularize order of functions and comments

This is a preparatory patch. No logic changes.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-rhtsupport: factor out tarball creation

This change doesn't change the logic, it only moves code
into a helper function.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-rhtsupport: make -t[CASE_ID] work without FILEs. Closes #140

This change allows reporter-rhtsupport to be used to upload
a problem dir to an existing case.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-rhtsupport: skip hints check if uploaded data is really large

Hints check uploads the entire problem directory tarball.
If the tarball is hundreds of megabytes, that is not a good idea.

Perhaps "hints" thing on the server one day will be changed so that
it accepts a truncated set of data.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-upload: factor out HTTP PUT upload

This patch adds HTTP PUT upload support to post()
helper function.

This simplifies send_file() in reporter-upload.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-upload: move file upload function to lib/

This patch moves send_file() out of reporter-upload
into lib/curl.c and renames it to upload_file().
It returns new URL or NULL on error.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-rhtsupport: fix double-free error

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-rhtsupport: upload file to BigFileURL if it is large

This patch adds BigFileURL and BigSizeMB parameters.

If uploaded DIR is bigger than BigSizeMB, then it is not attached
to the case, but uploaded to BigFileURL, then a comment is added
to the case with the URL of uploaded file.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
reporter-rhtsupport: improve logging

While testing previous patch, I got error messages
which were not very helpful.
Lets add URL to them.

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
remove new line from ask/ask_password responses

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
Change default conf to show three options: new case/existing case/tarball

Per the discussion with GSS people, this change makes "abrt-cli report DIR"
to show this choice of reporters:

How would you like to report the problem?
 1) New Red Hat Support case
 2) Existing Red Hat Support case
 3) Save to tar archive

Choice (2) is similar to (1) but in addition it prompts: "Case number:"

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
specfile: hook up new default conf files

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>
wizard: fix "unterminated string" bug in ask() handling rhbz#948286

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Jiri Moskovcak <jmoskovc@redhat.com>