Open Bug 1872370 Opened 9 months ago Updated 9 days ago

Failed to upload files with same file name in different folder

Categories

(Fenix :: Downloads, defect, P3)

All
Android
defect

Tracking

(Not tracked)

People

(Reporter: jackyzy823, Unassigned)

References

Details

(Whiteboard: [fxdroid] [group4])

Attachments

(1 file)

Attached file demo.html

Steps to reproduce

  1. Prepare two text files which have same name but in different folder. ( eg . Create folder1/samename.txt and folder2/samename.txt in Download folder and fill with different text content)
  2. Visit the demo html page
  3. Click "Browse" near "Select FIle1 to upload" , and select folder1/samename.txt
  4. Click "Browse" near "Select FIle2 to upload" , and select folder2/samename.txt
  5. Click "Load Selected File" near "Select FIle1 to upload"
  6. Click "Load Selected File" near "Select FIle2 to upload"

Expected behavior

file content of two files are displayed.

Actual behavior

Only the second uploaded one's content could display. the first one is showing error.

Any additional information?

This is because uploaded files are all copied to the same cache folder first , so when copying the second file , the first file has been overwritten (because of the same filename).

Summary: Fail to upload same file name in different folder → Failed to upload files with same file name in different folder
Component: General → Downloads

The severity field is not set for this bug.
:mavduevskiy, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(mavduevskiy)
Severity: -- → S3
Priority: -- → P3
Whiteboard: [fxdroid] [group4]

An easy workaround is that create random folders under temp folder to store file disgustingly.

The better way : don't store temp file.

Flags: needinfo?(mavduevskiy)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: