Anonymous | Login | Signup for a new account | 2019-12-06 06:14 GMT | ![]() |
Main | My View | View Issues | Change Log | Roadmap |
View Issue Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||||||||
ID | Project | Category | View Status | Date Submitted | Last Update | ||||||||
0001948 | SiT! | incidents | public | 2014-06-15 16:00 | 2014-06-15 16:00 | ||||||||
Reporter | repostor | ||||||||||||
Assigned To | |||||||||||||
Priority | normal | Severity | minor | Reproducibility | always | ||||||||
Status | new | Resolution | open | ||||||||||
Platform | Linux | OS | CentOS | OS Version | 6.4 | ||||||||
Product Version | 3.67 LTS | ||||||||||||
Target Version | Fixed in Version | ||||||||||||
Summary | 0001948: incident_attachment, does not store the attachment correctly | ||||||||||||
Description | in version 3.65, it worked fine. But after I applied 3.67, I can no longer upload attachment. In order to get this working again; I have to manually copy the older version of the file. So I have a workaround for it... Here are the changes between 3.65 and 3.67. [root@tomcat sit]# diff incident_attachments.php ../sit-3.63/incident_attachments.php 5c5 < // Copyright (C) 2010-2012 The Support Incident Tracker Project --- > // Copyright (C) 2010-2011 The Support Incident Tracker Project 53c53 < $sql .= "VALUES ('public', '" . clean_dbstring(clean_fspath($_FILES['attachment']['name'])) . ", '{$_FILES['attachment']['size']}', '{$sit[2]}', 'user', NOW())"; --- > $sql .= "VALUES ('public', '{$_FILES['attachment']['name']}', '{$_FILES['attachment']['size']}', '{$sit[2]}', 'user', NOW())"; 75c75 < "-" . clean_fspath($_FILES['attachment']['name']); --- > "-".$_FILES['attachment']['name']; 83c83 < trigger_error('Failed creating incident attachment directory.', E_USER_WARNING); --- > trigger_error('Failed creating incident attachment directory: '.$incident_attachment_fspath, E_USER_WARNING); 87,88c87,88 < $mv = @move_uploaded_file($_FILES['attachment']['tmp_name'], $newfilename); < if (!$mv) trigger_error('!Error: Problem moving attachment from temp directory', E_USER_WARNING); --- > $mv = move_uploaded_file($_FILES['attachment']['tmp_name'], $newfilename); > if (!$mv) trigger_error('!Error: Problem moving attachment from temp directory to: '.$newfilename, E_USER_WARNING); [root@tomcat sit]# mv incident_attachments.php incident_attachments.php.367 [root@tomcat sit]# cp -p ../sit-3.63/incident_attachments.php . Regards Tomas | ||||||||||||
Steps To Reproduce | not sure how your environment differs from my, but I did this: 1. create an incident 2. I selected "files" on the incident 3. I selected "browse" button 4. I selected a file -> OK 5. I selected "attach file" The file gets attached; but no name of the file. Only size; date, etc. | ||||||||||||
Tags | No tags attached. | ||||||||||||
Attached Files | |||||||||||||
![]() |
|||
Date Modified | Username | Field | Change |
2014-06-15 16:00 | repostor | New Issue |
Copyright © 2000 - 2019 MantisBT Team |