File: bug23852

package info (click to toggle)
oce 0.17.2-2
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 297,992 kB
  • ctags: 203,291
  • sloc: cpp: 1,176,369; ansic: 67,206; sh: 11,647; tcl: 6,890; cs: 5,221; python: 2,867; java: 1,522; makefile: 338; xml: 292; perl: 37
file content (74 lines) | stat: -rw-r--r-- 1,909 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
puts "============"
puts "OCC23852"
puts "============"
puts ""
#######################################################################
# OSD_Path interprets unc paths incorrectly
#######################################################################

pload DCAF

set BugNumber OCC23852

set OS_platform $tcl_platform(platform)
puts "OS = ${OS_platform}"

if { [string compare ${OS_platform} "windows"] == 0 } {

   # Windows, #1
   set OSD_Path "\\\\Server\\Shared\\Folder\\File.Extension"
   puts "OSD_Path = ${OSD_Path}"

   set Log [OSDPath ${OSD_Path}]
   #
   if { [regexp "Trek +: +\\|\\|Server\\|Shared\\|Folder" ${Log}] != 1 } {
      puts "${BugNumber}, Trek, #1: Error"
   }
   #
   if { [regexp "Name +: +File" ${Log}] != 1 } {
      puts "${BugNumber}, Name, #1: Error"
   }
   #
   if { [regexp "Extension +: +.Extension" ${Log}] != 1 } {
      puts "${BugNumber}, Extension, #1: Error"
   }

   # Windows, #2
   set OSD_Path "//Server/Shared/Folder/File.Extension"
   puts "OSD_Path = ${OSD_Path}"

   set Log [OSDPath ${OSD_Path}]
   #
   if { [regexp "Trek +: +||Server|Shared|Folder" ${Log}] != 1 } {
      puts "${BugNumber}, Trek, #2: Error"
   }
   #
   if { [regexp "Name +: +File" ${Log}] != 1 } {
      puts "${BugNumber}, Name, #2: Error"
   }
   #
   if { [regexp "Extension +: +.Extension" ${Log}] != 1 } {
      puts "${BugNumber}, Extension, #2: Error"
   }

}

if { [string compare ${OS_platform} "unix"] == 0 } {
   # Linux
   set OSD_Path "//Server/Shared/Folder/File.Extension"
   puts "OSD_Path = ${OSD_Path}"

   set Log [OSDPath ${OSD_Path}]
   #
   if { [regexp "Trek +: +||Server|Shared|Folder" ${Log}] != 1 } {
      puts "${BugNumber}, Trek: Error"
   }
   #
   if { [regexp "Name +: +File" ${Log}] != 1 } {
      puts "${BugNumber}, Name: Error"
   }
   #
   if { [regexp "Extension +: +.Extension" ${Log}] != 1 } {
      puts "${BugNumber}, Extension: Error"
   }
}