(command.CommandList
  children: [
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'DESC='> name:DESC)
          op: assign_op.Equal
          rhs: {(DQ <'automatic crash report generation'>)}
          spids: [29]
        )
      ]
      redirects: []
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'NAME='> name:NAME)
          op: assign_op.Equal
          rhs: {<apport>}
          spids: [34]
        )
      ]
      redirects: []
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'AGENT='> name:AGENT)
          op: assign_op.Equal
          rhs: {<'/usr/share/apport/apport'>}
          spids: [37]
        )
      ]
      redirects: []
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'SCRIPTNAME='> name:SCRIPTNAME)
          op: assign_op.Equal
          rhs: {<'/etc/init.d/'> ($ Id.VSub_DollarName NAME)}
          spids: [40]
        )
      ]
      redirects: []
    )
    (command.AndOr
      ops: [Id.Op_DPipe]
      children: [
        (C {<Id.Lit_LBracket '['>} {<-x>} {(DQ ($ Id.VSub_DollarName AGENT))} {<Id.Lit_RBracket ']'>})
        (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>})
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'enabled='> name:enabled)
          op: assign_op.Equal
          rhs: {<1>}
          spids: [68]
        )
      ]
      redirects: []
    )
    (command.AndOr
      ops: [Id.Op_DAmp Id.Op_DPipe]
      children: [
        (C {<Id.Lit_LBracket '['>} {<-e>} {<'/etc/default/'> ($ Id.VSub_DollarName NAME)} 
          {<Id.Lit_RBracket ']'>}
        )
        (C {<.>} {<'/etc/default/'> ($ Id.VSub_DollarName NAME)})
        (C {<true>})
      ]
    )
    (C {<.>} {<'/lib/lsb/init-functions'>})
    (command.ShFunction
      name: do_start
      body: 
        (BraceGroup
          left: <Id.Lit_LBrace '{'>
          children: [
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {<Id.Lit_LBracket '['>} {<-e>} {<'/var/crash'>} {<Id.Lit_RBracket ']'>})
                (C {<mkdir>} {<-p>} {<'/var/crash'>})
              ]
            )
            (C {<chmod>} {<1777>} {<'/var/crash'>})
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (command.AndOr
                              ops: [Id.Op_DPipe]
                              children: [
                                (C {<Id.Lit_LBracket '['>} {<-e>} {<'/var/crash/vmcore'>} 
                                  {<Id.Lit_RBracket ']'>}
                                )
                                (C {<Id.Lit_LBracket '['>} {<-n>} 
                                  {
                                    (DQ 
                                      (command_sub
                                        left_token: <Id.Left_Backtick '`'>
                                        child: 
                                          (command.Pipeline
                                            children: [
                                              (C {<ls>} {<'/var/crash'>})
                                              (C {<egrep>} 
                                                {<Id.Lit_Other '^'> <Id.Lit_LBracket '['> <0-9> 
                                                  <Id.Lit_RBracket ']'> <Id.Lit_LBrace '{'> <12> <Id.Lit_RBrace '}'> <Id.Lit_Dollar '$'>
                                                }
                                              )
                                            ]
                                            negated: F
                                            stderr_indices: []
                                          )
                                        right: <Id.Backtick_Right '`'>
                                      )
                                    )
                                  } {<Id.Lit_RBracket ']'>}
                                )
                              ]
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [(C {<'/usr/share/apport/kernel_crashdump'>}) (C {<true>})]
                    )
                  ]
                  spids: [165 206]
                )
              ]
              else_action: []
              redirects: []
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (C {<Id.Lit_LBracket '['>} {<-e>} {<'/var/lib/pm-utils/status'>} 
                              {<Id.Lit_RBracket ']'>}
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DPipe]
                      children: [(C {<'/usr/share/apport/apportcheckresume'>}) (C {<true>})]
                    )
                    (C {<rm>} {<-f>} {<'/var/lib/pm-utils/status'>})
                    (C {<rm>} {<-f>} {<'/var/lib/pm-utils/resume-hang.log'>})
                  ]
                  spids: [224 235]
                )
              ]
              else_action: []
              redirects: []
            )
            (command.Simple
              words: [{<echo>} {(DQ <'|'> ($ Id.VSub_DollarName AGENT) <' %p %s %c %d %P'>)}]
              redirects: [
                (redir
                  op: <Id.Redir_Great '>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {<'/proc/sys/kernel/core_pattern'>}
                )
              ]
              more_env: []
              do_fork: T
            )
            (command.Simple
              words: [{<echo>} {<2>}]
              redirects: [
                (redir
                  op: <Id.Redir_Great '>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {<'/proc/sys/fs/suid_dumpable'>}
                )
              ]
              more_env: []
              do_fork: T
            )
          ]
          redirects: []
          right: <Id.Lit_RBrace '}'>
        )
    )
    (command.ShFunction
      name: do_stop
      body: 
        (BraceGroup
          left: <Id.Lit_LBrace '{'>
          children: [
            (command.Simple
              words: [{<echo>} {<0>}]
              redirects: [
                (redir
                  op: <Id.Redir_Great '>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {<'/proc/sys/fs/suid_dumpable'>}
                )
              ]
              more_env: []
              do_fork: T
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (C {<Id.Lit_LBracket '['>} {<-e>} {<'/var/lib/pm-utils/status'>} 
                              {<Id.Lit_RBracket ']'>}
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.Simple
                      words: [{<ps>} {<-wwef>}]
                      redirects: [
                        (redir
                          op: <Id.Redir_Great '>'>
                          loc: (redir_loc.Fd fd:1)
                          arg: {<'/var/lib/pm-utils/resume-hang.log'>}
                        )
                      ]
                      more_env: []
                      do_fork: T
                    )
                  ]
                  spids: [342 353]
                )
              ]
              else_action: []
              redirects: []
            )
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (C {<Id.Lit_LBracket '['>} 
                              {
                                (DQ 
                                  (command_sub
                                    left_token: <Id.Left_Backtick '`'>
                                    child: 
                                      (command.Simple
                                        words: [
                                          {<dd>}
                                          {<Id.Lit_VarLike 'if='> <'/proc/sys/kernel/core_pattern'>}
                                          {<Id.Lit_VarLike 'count='> <1>}
                                          {<Id.Lit_VarLike 'bs='> <1>}
                                        ]
                                        redirects: [
                                          (redir
                                            op: <Id.Redir_Great '2>'>
                                            loc: (redir_loc.Fd fd:2)
                                            arg: {<'/dev/null'>}
                                          )
                                        ]
                                        more_env: []
                                        do_fork: T
                                      )
                                    right: <Id.Backtick_Right '`'>
                                  )
                                )
                              } {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {(DQ <'|'>)} {<Id.Lit_RBracket ']'>}
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [(command.ControlFlow token:<Id.ControlFlow_Return return> arg_word:{<1>})]
                  spids: [368 402]
                )
              ]
              else_action: [
                (command.Simple
                  words: [{<echo>} {(DQ <core>)}]
                  redirects: [
                    (redir
                      op: <Id.Redir_Great '>'>
                      loc: (redir_loc.Fd fd:1)
                      arg: {<'/proc/sys/kernel/core_pattern'>}
                    )
                  ]
                  more_env: []
                  do_fork: T
                )
              ]
              redirects: []
            )
          ]
          redirects: []
          right: <Id.Lit_RBrace '}'>
        )
    )
    (command.Case
      to_match: {(DQ ($ Id.VSub_Number 1))}
      arms: [
        (case_arm
          pat_list: [{<start>}]
          action: [
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<grep>} {<-zqs>} {(SQ <'^container='>)} {<'/proc/1/environ'>})
                (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>})
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe Id.Op_DPipe]
              children: [
                (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName enabled))} {<Id.Lit_Equals '='>} 
                  {(DQ <1>)} {<Id.Lit_RBracket ']'>}
                )
                (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName force_start))} 
                  {<Id.Lit_Equals '='>} {(DQ <1>)} {<Id.Lit_RBracket ']'>}
                )
                (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>})
              ]
            )
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName VERBOSE))} 
                  {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>}
                )
                (C {<log_daemon_msg>} {(DQ <'Starting '> ($ Id.VSub_DollarName DESC) <':'>)} 
                  {(DQ ($ Id.VSub_DollarName NAME))}
                )
              ]
            )
            (C {<do_start>})
            (command.Case
              to_match: {(DQ ($ Id.VSub_QMark '?'))}
              arms: [
                (case_arm
                  pat_list: [{<0>} {<1>}]
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName VERBOSE))} 
                          {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>}
                        )
                        (C {<log_end_msg>} {<0>})
                      ]
                    )
                  ]
                  spids: [541 544 565 -1]
                )
                (case_arm
                  pat_list: [{<2>}]
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName VERBOSE))} 
                          {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>}
                        )
                        (C {<log_end_msg>} {<1>})
                      ]
                    )
                  ]
                  spids: [568 569 590 -1]
                )
              ]
              redirects: []
            )
          ]
          spids: [438 439 596 -1]
        )
        (case_arm
          pat_list: [{<stop>}]
          action: [
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<grep>} {<-zqs>} {(SQ <'^container='>)} {<'/proc/1/environ'>})
                (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>})
              ]
            )
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName VERBOSE))} 
                  {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>}
                )
                (C {<log_daemon_msg>} {(DQ <'Stopping '> ($ Id.VSub_DollarName DESC) <':'>)} 
                  {(DQ ($ Id.VSub_DollarName NAME))}
                )
              ]
            )
            (C {<do_stop>})
            (command.Case
              to_match: {(DQ ($ Id.VSub_QMark '?'))}
              arms: [
                (case_arm
                  pat_list: [{<0>} {<1>}]
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName VERBOSE))} 
                          {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>}
                        )
                        (C {<log_end_msg>} {<0>})
                      ]
                    )
                  ]
                  spids: [665 668 689 -1]
                )
                (case_arm
                  pat_list: [{<2>}]
                  action: [
                    (command.AndOr
                      ops: [Id.Op_DAmp]
                      children: [
                        (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName VERBOSE))} 
                          {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {<no>} {<Id.Lit_RBracket ']'>}
                        )
                        (C {<log_end_msg>} {<1>})
                      ]
                    )
                  ]
                  spids: [692 693 714 -1]
                )
              ]
              redirects: []
            )
          ]
          spids: [599 600 720 -1]
        )
        (case_arm
          pat_list: [{<restart>} {<force-reload>}]
          action: [
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [(C {($ Id.VSub_Number 0)} {<stop>}) (C {<true>})]
            )
            (C {($ Id.VSub_Number 0)} {<start>})
          ]
          spids: [723 726 743 -1]
        )
        (case_arm
          pat_list: [{<Id.Lit_Star '*'>}]
          action: [
            (command.Simple
              words: [
                {<echo>}
                {
                  (DQ <'Usage: '> ($ Id.VSub_DollarName SCRIPTNAME) 
                    <' {start|stop|restart|force-reload}'>
                  )
                }
              ]
              redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
              more_env: []
              do_fork: T
            )
            (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<3>})
          ]
          spids: [746 747 767 -1]
        )
      ]
      redirects: []
    )
    (C {<Id.Lit_Colon ':'>})
  ]
)